
From: Martin Waitz <tali@admingilde.org>

Allow preprocessor directives between kernel-doc and function

Signed-off-by: Martin Waitz <tali@admingilde.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/scripts/kernel-doc |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -puN scripts/kernel-doc~docbook-allow-preprocessor-directives-between-kernel-doc-and-function scripts/kernel-doc
--- 25/scripts/kernel-doc~docbook-allow-preprocessor-directives-between-kernel-doc-and-function	Thu Mar  3 16:55:20 2005
+++ 25-akpm/scripts/kernel-doc	Thu Mar  3 16:55:20 2005
@@ -1578,13 +1578,13 @@ sub process_state3_function($$) { 
     my $x = shift;
     my $file = shift;
 
-    if ($x =~ m#\s*/\*\s+MACDOC\s*#io) {
+    if ($x =~ m#\s*/\*\s+MACDOC\s*#io || ($x =~ /^#/ && $x !~ /^#define/)) {
 	# do nothing
     }
     elsif ($x =~ /([^\{]*)/) {
         $prototype .= $1;
     }
-    if (($x =~ /\{/) || ($x =~ /\#/) || ($x =~ /;/)) {
+    if (($x =~ /\{/) || ($x =~ /\#define/) || ($x =~ /;/)) {
         $prototype =~ s@/\*.*?\*/@@gos;	# strip comments.
 	$prototype =~ s@[\r\n]+@ @gos; # strip newlines/cr's.
 	$prototype =~ s@^\s+@@gos; # strip leading spaces
_
