All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: akpm@linux-foundation.org, linux-kernel@vger.kernel.org
Subject: [patch] make hdrscheck.sh force __asm__ in exported headers
Date: Sun, 17 Jun 2007 18:54:24 -0400	[thread overview]
Message-ID: <200706171854.24763.vapier@gentoo.org> (raw)

This updates scripts/hdrschecks.sh by grepping for asm() constructs and
rejecting them in favor of __asm__() in exported headers.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
diff --git a/scripts/hdrcheck.sh b/scripts/hdrcheck.sh
index 3159858..33d17cc 100755
--- a/scripts/hdrcheck.sh
+++ b/scripts/hdrcheck.sh
@@ -6,5 +6,16 @@ for FILE in `grep '^[ \t]*#[ \t]*include[ \t]*<' $2 | cut -f2 -d\< | cut -f1 -d\
 	exit 1
     fi
 done
+
+# make sure we export __asm__(), not asm()
+lines=$(grep -n -E \
+	-e '\<asm[[:space:]]*(_{1,2}?volatile_{1,2}?[[:space:]]*)?\(' \
+	$2)
+if [ -n "$lines" ] ; then
+	echo "$2 should convert asm() usage to __asm__() in exported headers"
+	echo "$lines"
+	exit 1
+fi
+
 # FIXME: List dependencies into $3
 touch $3

             reply	other threads:[~2007-06-17 22:54 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-17 22:54 Mike Frysinger [this message]
2007-06-18  5:11 ` [patch] make hdrscheck.sh force __asm__ in exported headers Andrew Morton
2007-06-18  5:17   ` Mike Frysinger
2007-06-18  5:34     ` Andrew Morton
2007-06-18  5:53       ` Mike Frysinger
2007-06-18  5:54       ` Mike Frysinger
2007-06-18  6:28       ` Mike Frysinger
2007-06-18  7:54 ` Sam Ravnborg
2007-06-18  8:07   ` Mike Frysinger

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=200706171854.24763.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.