public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rabin Vincent <rabin@rab.in>
To: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Sam Ravnborg <sam@ravnborg.org>, lkml <linux-kernel@vger.kernel.org>
Subject: [PATCH v2] kbuild: add sys_* entries for syscalls in tags
Date: Sun, 25 Jan 2009 18:39:12 +0530	[thread overview]
Message-ID: <20090125130912.GA21034@debian> (raw)
In-Reply-To: <20090125111856.GA3268@x200.localdomain>

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>
---
This version of the patch makes the modifications for emacs too.

 scripts/tags.sh |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/scripts/tags.sh b/scripts/tags.sh
index fdbe78b..fe7c99d 100755
--- a/scripts/tags.sh
+++ b/scripts/tags.sh
@@ -99,7 +99,8 @@ exuberant()
 	-I ____cacheline_internodealigned_in_smp                \
 	-I EXPORT_SYMBOL,EXPORT_SYMBOL_GPL                      \
 	--extra=+f --c-kinds=+px                                \
-	--regex-asm='/^ENTRY\(([^)]*)\).*/\1/'
+	--regex-asm='/^ENTRY\(([^)]*)\).*/\1/'                  \
+	--regex-c='/^SYSCALL_DEFINE[[:digit:]]?\(([^,)]*).*/sys_\1/'
 
 	all_kconfigs | xargs $1 -a                              \
 	--langdef=kconfig --language-force=kconfig              \
@@ -117,7 +118,9 @@ exuberant()
 
 emacs()
 {
-	all_sources | xargs $1 -a
+	all_sources | xargs $1 -a                               \
+	--regex='/^ENTRY(\([^)]*\)).*/\1/'                      \
+	--regex='/^SYSCALL_DEFINE[0-9]?(\([^,)]*\).*/sys_\1/'
 
 	all_kconfigs | xargs $1 -a                              \
 	--regex='/^[ \t]*\(\(menu\)*config\)[ \t]+\([a-zA-Z0-9_]+\)/\3/'
-- 
1.5.6.5


  reply	other threads:[~2009-01-25 13:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-25 10:05 [PATCH] kbuild: add sys_* entries for syscalls in tags Rabin Vincent
2009-01-25 11:18 ` Alexey Dobriyan
2009-01-25 13:09   ` Rabin Vincent [this message]
2009-02-15  9:27     ` [PATCH v2] " Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090125130912.GA21034@debian \
    --to=rabin@rab.in \
    --cc=adobriyan@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sam@ravnborg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox