rcu: Make struct rcu_head searchable
PATCH 1/1 rcu: Make struct rcu_head searchable
After wasting too much time trying to see where struct rcu_head was declared, I finally found it in include/linux/types.h as a define for callback_head!
To prevent other developers from wasting their precious time in searching for this structure, add a comment to help them find it!
include/linux/types.h +3 -0
@@ -210,6 +210,9 @@ struct callback_head {struct callback_head *next; void (*func)(struct callback_head *head); }; +/* +* Make "struct rcu_head {" seachable with this comment. +*/ #define rcu_head callback_head#endif /* __ASSEMBLY__ */
Quoted 10 lines · Steven Rostedt
After wasting too much time trying to see where struct
rcu_headwas declared, I finally found it ininclude/linux/types.has a define forcallback_head!To prevent other developers from wasting their precious time in searching for this structure, add a comment to help them find it!
Cc Al Viro <[email protected]>Cc "Paul E. McKenney" <[email protected]>Signed-off-by Steven "frustrated" Rostedt <[email protected]>
The cscope tool is your friend in this case, but nevertheless:
Quoted 15 lines
include/linux/types.h +3
-0@@ -210,6 +210,9 @@ struct callback_head {struct callback_head *next; void (*func)(struct callback_head *head); }; +/* +* Make "struct rcu_head {" seachable with this comment. +*/ #define rcu_head callback_head#endif /* __ASSEMBLY__ */
Quoted 5 lines · On Wed, 13 Nov 2013 09:12:05 -0800 "Paul E. McKenney"…
Quoted 4 lines · Steven Rostedt
After wasting too much time trying to see where struct
rcu_headwas declared, I finally found it ininclude/linux/types.has a define forcallback_head!
Quoted 8 lines
Quoted 6 lines
To prevent other developers from wasting their precious time in searching for this structure, add a comment to help them find it!
Cc Al Viro <[email protected]>Cc "Paul E. McKenney" <[email protected]>Signed-off-by Steven "frustrated" Rostedt <[email protected]>The cscope tool is your friend in this case, but nevertheless:
I use emacs, and the latest version of etags (or emacs) brings you to each use case before it gets you to the define (which is really annoying). Back in 2006 it use to work properly. I need to figure out what changed :-/
Quoted 13 lines
Reviewed-by Paul E. McKenney <[email protected]>include/linux/types.h struct callback_head { · line 214
Quoted 10 lines
include/linux/types.h +2
-0@@ -210,6 +210,9 @@ struct callback_head {struct callback_head *next;void (*func)(struct callback_head *head); }; +/* +* Make "struct rcu_head {" seachable with this comment.
I've been told s/seachable/searchable/
Frustration fails me ;-)
-- Steve
Quoted 5 lines
Quoted 5 lines
include/linux/types.h +1
-0+*/ #define rcu_head callback_head#endif /* __ASSEMBLY__ */
Quoted 15 lines · On Wed, 13 Nov 2013 13:10:44 -0500 Steven Rostedt <[email protected]> wrote:
Quoted 12 lines · On Wed, 13 Nov 2013 09:12:05 -0800 "Paul E. McKenney"…
Quoted 10 lines · Steven Rostedt
After wasting too much time trying to see where struct
rcu_headwas declared, I finally found it ininclude/linux/types.has a define forcallback_head!To prevent other developers from wasting their precious time in searching for this structure, add a comment to help them find it!
Cc Al Viro <[email protected]>Cc "Paul E. McKenney" <[email protected]>Signed-off-by Steven "frustrated" Rostedt <[email protected]>
Quoted 6 lines
Quoted 1 line
The cscope tool is your friend in this case, but nevertheless:
I use emacs, and the latest version of etags (or emacs) brings you to each use case before it gets you to the define (which is really annoying). Back in 2006 it use to work properly. I need to figure out what changed :-/
That irritates me too. Fortunately I just invented
(grep "#define" tags && grep -v "#define" tags) > tags.new
Quoted 3 lines · On Wed, 13 Nov 2013 10:57:05 -0800 Andrew Morton <[email protected]>…
That irritates me too. Fortunately I just invented
(grep "#define" tags && grep -v "#define" tags) > tags.new
Unfortunately, TAGS doesn't work that way. Hmm, I could whip up a perl script to do it for me though.
-- Steve