Commit 5123b327c107db9e560fd62d50c27a3816e5a078
Committed by
Sam Ravnborg
1 parent
953fae66d1
Exists in
master
and in
7 other branches
kbuild: add sys_* entries for syscalls in tags
Currently, it is no longer possible to use the tags file to jump to system call function definitions with sys_foo, because the definitions are obscured by use of the SYSCALL_DEFINE* macros. This patch adds the appropriate option to ctags to make it see through the macro. Also, it adds the ENTRY() work already done for Exuberant to Emacs too. Signed-off-by: Rabin Vincent <rabin@rab.in> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Showing 1 changed file with 5 additions and 2 deletions Side-by-side Diff
scripts/tags.sh
... | ... | @@ -102,7 +102,8 @@ |
102 | 102 | -I ____cacheline_internodealigned_in_smp \ |
103 | 103 | -I EXPORT_SYMBOL,EXPORT_SYMBOL_GPL \ |
104 | 104 | --extra=+f --c-kinds=+px \ |
105 | - --regex-asm='/^ENTRY\(([^)]*)\).*/\1/' | |
105 | + --regex-asm='/^ENTRY\(([^)]*)\).*/\1/' \ | |
106 | + --regex-c='/^SYSCALL_DEFINE[[:digit:]]?\(([^,)]*).*/sys_\1/' | |
106 | 107 | |
107 | 108 | all_kconfigs | xargs $1 -a \ |
108 | 109 | --langdef=kconfig --language-force=kconfig \ |
... | ... | @@ -120,7 +121,9 @@ |
120 | 121 | |
121 | 122 | emacs() |
122 | 123 | { |
123 | - all_sources | xargs $1 -a | |
124 | + all_sources | xargs $1 -a \ | |
125 | + --regex='/^ENTRY(\([^)]*\)).*/\1/' \ | |
126 | + --regex='/^SYSCALL_DEFINE[0-9]?(\([^,)]*\).*/sys_\1/' | |
124 | 127 | |
125 | 128 | all_kconfigs | xargs $1 -a \ |
126 | 129 | --regex='/^[ \t]*\(\(menu\)*config\)[ \t]+\([a-zA-Z0-9_]+\)/\3/' |