Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-13 Thread Christoph Hellwig

On Fri, Apr 13, 2001 at 12:39:39PM +0200, Jamie Lokier wrote:
> Christoph Hellwig wrote:
> > So the /* old gcc */ part should probably be enabled based on a define for the
> > old compiler.  The right ifdef seems to be:
> > 
> >   #if __GNUC__ == 2 && __GNUC_MINOR__ < 95
> 
> The current GCC supports the old syntax and will do so for a while yet,
> so perhaps this is not required?

If that's true (I have no gcc3.0 to verify it) that's the better soloution
in my eyes.

Christoph

-- 
Of course it doesn't work. We've performed a software upgrade.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-13 Thread Jamie Lokier

Christoph Hellwig wrote:
> So the /* old gcc */ part should probably be enabled based on a define for the
> old compiler.  The right ifdef seems to be:
> 
>   #if __GNUC__ == 2 && __GNUC_MINOR__ < 95

The current GCC supports the old syntax and will do so for a while yet,
so perhaps this is not required?

-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-13 Thread Jamie Lokier

Christoph Hellwig wrote:
 So the /* old gcc */ part should probably be enabled based on a define for the
 old compiler.  The right ifdef seems to be:
 
   #if __GNUC__ == 2  __GNUC_MINOR__  95

The current GCC supports the old syntax and will do so for a while yet,
so perhaps this is not required?

-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-13 Thread Christoph Hellwig

On Fri, Apr 13, 2001 at 12:39:39PM +0200, Jamie Lokier wrote:
 Christoph Hellwig wrote:
  So the /* old gcc */ part should probably be enabled based on a define for the
  old compiler.  The right ifdef seems to be:
  
#if __GNUC__ == 2  __GNUC_MINOR__  95
 
 The current GCC supports the old syntax and will do so for a while yet,
 so perhaps this is not required?

If that's true (I have no gcc3.0 to verify it) that's the better soloution
in my eyes.

Christoph

-- 
Of course it doesn't work. We've performed a software upgrade.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-12 Thread Wayne . Brown



Christoph Hellwig <[EMAIL PROTECTED]> wrote:

>So the /* old gcc */ part should probably be enabled based on a define for the

>old compiler.  The right ifdef seems to be:

>
>  #if __GNUC__ == 2 && __GNUC_MINOR__ < 95
>
>Could you test it this way?

Yes, that works for me.  Is this the sort of thing you had in mind?

Wayne


--- include/asm-i386/rwsem.h.old   Thu Apr 12 14:50:08 2001
+++ include/asm-i386/rwsem.h  Thu Apr 12 14:54:14 2001
@@ -20,18 +20,24 @@
 #include 
 #include 

+#if __GNUC__ == 2 && __GNUC_MINOR__ < 95
+
+/* old gcc */
 #if RWSEM_DEBUG
-#define rwsemdebug(FMT,...) do { if (sem->debug) printk(FMT,__VA_ARGS__); }
while(0)
+#define rwsemdebug(FMT, ARGS...) do { if (sem->debug) printk(FMT,##ARGS); }
while(0)
 #else
-#define rwsemdebug(FMT,...)
+#define rwsemdebug(FMT, ARGS...)
 #endif

-/* old gcc */
+#else
+
 #if RWSEM_DEBUG
-//#define rwsemdebug(FMT, ARGS...) do { if (sem->debug) printk(FMT,##ARGS); }
while(0)
+#define rwsemdebug(FMT,...) do { if (sem->debug) printk(FMT,__VA_ARGS__); }
while(0)
 #else
-//#define rwsemdebug(FMT, ARGS...)
+#define rwsemdebug(FMT,...)
 #endif
+
+#endif /* __GNUC__ == 2 && __GNUC_MINOR__ < 95 */

 #ifdef CONFIG_X86_XADD
 #include  /* use XADD based semaphores if possible */


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-12 Thread Christoph Hellwig

In article <[EMAIL PROTECTED]> you wrote:
>
> When compiling 2.4.3-ac5 (and also 2.4.4-pre2) I get this:
>
> /usr/src/linux-2.4.3-ac5/include/asm/rwsem.h:26: badly punctuated parameter list
>  in `#define'
>
> This appears to be due to some code in rwsem.h that is written for a different
> version of gcc. (I'm still using gcc-2.91.66 as specified in
> Documentation/Changes.)  It works for me if I replace it with the code in the
> section labeled /* old gcc */.  Here's a patch to do that:

So the /* old gcc */ part should probably be enabled based on a define for the
old compiler.  The right ifdef seems to be:

  #if __GNUC__ == 2 && __GNUC_MINOR__ < 95

Could you test it this way?

Christoph

-- 
Of course it doesn't work. We've performed a software upgrade.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4-pre2)

2001-04-12 Thread Wayne . Brown



When compiling 2.4.3-ac5 (and also 2.4.4-pre2) I get this:

/usr/src/linux-2.4.3-ac5/include/asm/rwsem.h:26: badly punctuated parameter list
 in `#define'

This appears to be due to some code in rwsem.h that is written for a different
version of gcc. (I'm still using gcc-2.91.66 as specified in
Documentation/Changes.)  It works for me if I replace it with the code in the
section labeled /* old gcc */.  Here's a patch to do that:

--- include/asm-i386/rwsem.h.old   Thu Apr 12 13:47:00 2001
+++ include/asm-i386/rwsem.h  Thu Apr 12 13:48:04 2001
@@ -21,16 +21,16 @@
 #include 

 #if RWSEM_DEBUG
-#define rwsemdebug(FMT,...) do { if (sem->debug) printk(FMT,__VA_ARGS__); }
while(0)
+//#define rwsemdebug(FMT,...) do { if (sem->debug) printk(FMT,__VA_ARGS__); }
while(0)
 #else
-#define rwsemdebug(FMT,...)
+//#define rwsemdebug(FMT,...)
 #endif

 /* old gcc */
 #if RWSEM_DEBUG
-//#define rwsemdebug(FMT, ARGS...) do { if (sem->debug) printk(FMT,##ARGS); }
while(0)
+#define rwsemdebug(FMT, ARGS...) do { if (sem->debug) printk(FMT,##ARGS); }
while(0)
 #else
-//#define rwsemdebug(FMT, ARGS...)
+#define rwsemdebug(FMT, ARGS...)
 #endif

 #ifdef CONFIG_X86_XADD


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4-pre2)

2001-04-12 Thread Wayne . Brown



When compiling 2.4.3-ac5 (and also 2.4.4-pre2) I get this:

/usr/src/linux-2.4.3-ac5/include/asm/rwsem.h:26: badly punctuated parameter list
 in `#define'

This appears to be due to some code in rwsem.h that is written for a different
version of gcc. (I'm still using gcc-2.91.66 as specified in
Documentation/Changes.)  It works for me if I replace it with the code in the
section labeled /* old gcc */.  Here's a patch to do that:

--- include/asm-i386/rwsem.h.old   Thu Apr 12 13:47:00 2001
+++ include/asm-i386/rwsem.h  Thu Apr 12 13:48:04 2001
@@ -21,16 +21,16 @@
 #include linux/wait.h

 #if RWSEM_DEBUG
-#define rwsemdebug(FMT,...) do { if (sem-debug) printk(FMT,__VA_ARGS__); }
while(0)
+//#define rwsemdebug(FMT,...) do { if (sem-debug) printk(FMT,__VA_ARGS__); }
while(0)
 #else
-#define rwsemdebug(FMT,...)
+//#define rwsemdebug(FMT,...)
 #endif

 /* old gcc */
 #if RWSEM_DEBUG
-//#define rwsemdebug(FMT, ARGS...) do { if (sem-debug) printk(FMT,##ARGS); }
while(0)
+#define rwsemdebug(FMT, ARGS...) do { if (sem-debug) printk(FMT,##ARGS); }
while(0)
 #else
-//#define rwsemdebug(FMT, ARGS...)
+#define rwsemdebug(FMT, ARGS...)
 #endif

 #ifdef CONFIG_X86_XADD


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-12 Thread Christoph Hellwig

In article [EMAIL PROTECTED] you wrote:

 When compiling 2.4.3-ac5 (and also 2.4.4-pre2) I get this:

 /usr/src/linux-2.4.3-ac5/include/asm/rwsem.h:26: badly punctuated parameter list
  in `#define'

 This appears to be due to some code in rwsem.h that is written for a different
 version of gcc. (I'm still using gcc-2.91.66 as specified in
 Documentation/Changes.)  It works for me if I replace it with the code in the
 section labeled /* old gcc */.  Here's a patch to do that:

So the /* old gcc */ part should probably be enabled based on a define for the
old compiler.  The right ifdef seems to be:

  #if __GNUC__ == 2  __GNUC_MINOR__  95

Could you test it this way?

Christoph

-- 
Of course it doesn't work. We've performed a software upgrade.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



Re: badly punctuated parameter list in `#define' (2.4.3-ac5 and 2.4.4 -pre2)

2001-04-12 Thread Wayne . Brown



Christoph Hellwig [EMAIL PROTECTED] wrote:

So the /* old gcc */ part should probably be enabled based on a define for the

old compiler.  The right ifdef seems to be:


  #if __GNUC__ == 2  __GNUC_MINOR__  95

Could you test it this way?

Yes, that works for me.  Is this the sort of thing you had in mind?

Wayne


--- include/asm-i386/rwsem.h.old   Thu Apr 12 14:50:08 2001
+++ include/asm-i386/rwsem.h  Thu Apr 12 14:54:14 2001
@@ -20,18 +20,24 @@
 #include linux/spinlock.h
 #include linux/wait.h

+#if __GNUC__ == 2  __GNUC_MINOR__  95
+
+/* old gcc */
 #if RWSEM_DEBUG
-#define rwsemdebug(FMT,...) do { if (sem-debug) printk(FMT,__VA_ARGS__); }
while(0)
+#define rwsemdebug(FMT, ARGS...) do { if (sem-debug) printk(FMT,##ARGS); }
while(0)
 #else
-#define rwsemdebug(FMT,...)
+#define rwsemdebug(FMT, ARGS...)
 #endif

-/* old gcc */
+#else
+
 #if RWSEM_DEBUG
-//#define rwsemdebug(FMT, ARGS...) do { if (sem-debug) printk(FMT,##ARGS); }
while(0)
+#define rwsemdebug(FMT,...) do { if (sem-debug) printk(FMT,__VA_ARGS__); }
while(0)
 #else
-//#define rwsemdebug(FMT, ARGS...)
+#define rwsemdebug(FMT,...)
 #endif
+
+#endif /* __GNUC__ == 2  __GNUC_MINOR__  95 */

 #ifdef CONFIG_X86_XADD
 #include asm/rwsem-xadd.h /* use XADD based semaphores if possible */


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/