cifs: #include cifsglob.h before trace.h to allow structs in tracepoints
Subsystems (3)
PATCH 1/1 cifs: #include cifsglob.h before trace.h to allow structs in tracepoints
Make cifs #include cifsglob.h in advance of #including trace.h so that the structures defined in cifsglob.h can be accessed directly by the cifs tracepoints rather than the callers having to manually pass in the bits and pieces.
This should allow the tracepoints to be made more efficient to use as well as easier to read in the code.
--- fs/smb/client/cifsproto.h | 1 + fs/smb/client/trace.c | 1 + 2 files changed, 2 insertions(+)
fs/smb/client/cifsproto.h +1 -0
@@ -9,6 +9,7 @@#define _CIFSPROTO_H#include <linux/nls.h> #include <linux/ctype.h> +#include "cifsglob.h" #include "trace.h" #ifdef CONFIG_CIFS_DFS_UPCALL #include "dfs_cache.h"
fs/smb/client/trace.c +1 -0
@@ -4,5 +4,6 @@* * Author(s): Steve French <[email protected]> */ +#include "cifsglob.h" #define CREATE_TRACE_POINTS #include "trace.h"
Do you have patches in process that will depend on this?
Quoted 45 lines · David Howells
Make cifs #include
cifsglob.hin advance of #includingtrace.hso that the structures defined incifsglob.hcan be accessed directly by the cifs tracepoints rather than the callers having to manually pass in the bits and pieces.This should allow the tracepoints to be made more efficient to use as well as easier to read in the code.
Signed-off-by David Howells <[email protected]>cc Steve French <[email protected]>cc Paulo Alcantara <[email protected]>--- fs/smb/client/cifsproto.h | 1 + fs/smb/client/trace.c | 1 + 2 files changed, 2 insertions(+)fs/smb/client/cifsproto.h +1
-0@@ -9,6 +9,7 @@#define _CIFSPROTO_H#include <linux/nls.h> #include <linux/ctype.h> +#include "cifsglob.h" #include "trace.h" #ifdef CONFIG_CIFS_DFS_UPCALL #include "dfs_cache.h" fs/smb/client/trace.c +1
-0@@ -4,5 +4,6 @@* * Author(s): Steve French <[email protected]> */ +#include "cifsglob.h" #define CREATE_TRACE_POINTS #include "trace.h"
Signature · 3 lines
Thanks, Steve