Commit 1b2643f0d09381ad504123809ff587bf6ab0ec7d
Committed by
Linus Torvalds
1 parent
af3b56289b
Exists in
master
and in
20 other branches
scripts/tags.sh: add ctags magic for declarations of popular kernel type
- Add magic for declarations of variables of popular kernel type like spinlock_t, list_head, wait_queue_head_t and other. - Add a set of specially handled declaration extentions like __attribute, __aligned and other. - Simplify pci_bus_* magic Signed-off-by: Kirill V Tkhai <tkhai@yandex.ru> Cc: Michal Marek <mmarek@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 1 changed file with 20 additions and 4 deletions Side-by-side Diff
scripts/tags.sh
... | ... | @@ -149,12 +149,17 @@ |
149 | 149 | exuberant() |
150 | 150 | { |
151 | 151 | all_target_sources | xargs $1 -a \ |
152 | - -I __initdata,__exitdata,__acquires,__releases \ | |
153 | - -I __read_mostly,____cacheline_aligned \ | |
152 | + -I __initdata,__exitdata,__initconst,__devinitdata \ | |
153 | + -I __devinitconst,__cpuinitdata,__initdata_memblock \ | |
154 | + -I __refdata,__attribute \ | |
155 | + -I __acquires,__releases,__deprecated \ | |
156 | + -I __read_mostly,__aligned,____cacheline_aligned \ | |
154 | 157 | -I ____cacheline_aligned_in_smp \ |
155 | 158 | -I ____cacheline_internodealigned_in_smp \ |
159 | + -I __used,__packed,__packed2__,__must_check,__must_hold \ | |
156 | 160 | -I EXPORT_SYMBOL,EXPORT_SYMBOL_GPL \ |
157 | 161 | -I DEFINE_TRACE,EXPORT_TRACEPOINT_SYMBOL,EXPORT_TRACEPOINT_SYMBOL_GPL \ |
162 | + -I static,const \ | |
158 | 163 | --extra=+f --c-kinds=+px \ |
159 | 164 | --regex-asm='/^(ENTRY|_GLOBAL)\(([^)]*)\).*/\2/' \ |
160 | 165 | --regex-c='/^SYSCALL_DEFINE[[:digit:]]?\(([^,)]*).*/sys_\1/' \ |
... | ... | @@ -182,8 +187,19 @@ |
182 | 187 | --regex-c++='/TESTCLEARFLAG_FALSE\(([^,)]*).*/TestClearPage\1/' \ |
183 | 188 | --regex-c++='/__TESTCLEARFLAG_FALSE\(([^,)]*).*/__TestClearPage\1/' \ |
184 | 189 | --regex-c++='/_PE\(([^,)]*).*/PEVENT_ERRNO__\1/' \ |
185 | - --regex-c='/PCI_OP_READ\(([a-z]*[a-z]).*[1-4]\)/pci_bus_read_config_\1/' \ | |
186 | - --regex-c='/PCI_OP_WRITE\(([a-z]*[a-z]).*[1-4]\)/pci_bus_write_config_\1/' | |
190 | + --regex-c='/PCI_OP_READ\((\w*).*[1-4]\)/pci_bus_read_config_\1/' \ | |
191 | + --regex-c='/PCI_OP_WRITE\((\w*).*[1-4]\)/pci_bus_write_config_\1/' \ | |
192 | + --regex-c='/DEFINE_(MUTEX|SEMAPHORE|SPINLOCK)\((\w*)/\2/v/' \ | |
193 | + --regex-c='/DEFINE_(RAW_SPINLOCK|RWLOCK|SEQLOCK)\((\w*)/\2/v/' \ | |
194 | + --regex-c='/DECLARE_(RWSEM|COMPLETION)\((\w*)/\2/v/' \ | |
195 | + --regex-c='/DECLARE_BITMAP\((\w*)/\1/v/' \ | |
196 | + --regex-c='/(^|\s)(|L|H)LIST_HEAD\((\w*)/\3/v/' \ | |
197 | + --regex-c='/(^|\s)RADIX_TREE\((\w*)/\2/v/' \ | |
198 | + --regex-c='/DEFINE_PER_CPU\(([^,]*,\s*)(\w*).*\)/\2/v/' \ | |
199 | + --regex-c='/DEFINE_PER_CPU_SHARED_ALIGNED\(([^,]*,\s*)(\w*).*\)/\2/v/' \ | |
200 | + --regex-c='/DECLARE_WAIT_QUEUE_HEAD\((\w*)/\1/v/' \ | |
201 | + --regex-c='/DECLARE_(TASKLET|WORK|DELAYED_WORK)\((\w*)/\2/v/' \ | |
202 | + --regex-c='/DEFINE_PCI_DEVICE_TABLE\((\w*)/\1/v/' | |
187 | 203 | |
188 | 204 | all_kconfigs | xargs $1 -a \ |
189 | 205 | --langdef=kconfig --language-force=kconfig \ |