Re: Compiler warnings / linux-2.6

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jun 06, 2005 at 05:57:06PM +0200, Ralf Rösch wrote:

> Since a few days I get a lot of compiler warnings:
> 
> include2/asm/dsp.h: In function `__init_dsp':
> include2/asm/dsp.h:34: warning: statement with no effect
> 
> What could I do to prevent these?

Reporting them.  A fairly obvious and harmless problem.  I'm surprised my
compiler (gcc 3.4) doesn't throw these warnings.

  Ralf

Index: include/asm-mips/mipsregs.h
===================================================================
RCS file: /home/cvs/linux/include/asm-mips/mipsregs.h,v
retrieving revision 1.73
diff -u -r1.73 mipsregs.h
--- include/asm-mips/mipsregs.h	31 May 2005 11:49:19 -0000	1.73
+++ include/asm-mips/mipsregs.h	7 Jun 2005 11:39:10 -0000
@@ -1010,8 +1010,6 @@
 
 #define wrdsp(val, mask)						\
 do {									\
-	unsigned int __res;						\
-									\
 	__asm__ __volatile__(						\
 	"	.set	push					\n"	\
 	"	.set	noat					\n"	\
@@ -1021,7 +1019,6 @@
 	"	.set	pop					\n"	\
         :								\
 	: "r" (val), "i" (mask));					\
-        __res;								\
 } while (0)
 
 #if 0	/* Need DSP ASE capable assembler ... */


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux