2.5.60 - drivers/char/esp.c vs include/linux/serialP.h

2.5.60 - drivers/char/esp.c vs include/linux/serialP.h

Post by Valdis.Kletni.. » Sat, 15 Feb 2003 23:20:07



compiling drivers/char/esp.c with -Wundef triggers a warning:

In file included from drivers/char/esp.c:51:
include/linux/serialP.h:27:6: warning: "LINUX_VERSION_CODE" is not defined

The code that trips it up:

#if (LINUX_VERSION_CODE < 0x020300)
/* Unfortunate, but Linux 2.2 needs async_icount defined here and
 * it got moved in 2.3 */
#include <linux/serial.h>
#endif

It's unclear if this should be fixed by adding a #include <linux/version.h>
to esp.c, or if this code should summarily be lopped out of serialP.h.

  application_pgp-signature_part
< 1K Download
 
 
 

2.5.60 - drivers/char/esp.c vs include/linux/serialP.h

Post by Russell Kin » Sat, 15 Feb 2003 23:20:16



> compiling drivers/char/esp.c with -Wundef triggers a warning:

> In file included from drivers/char/esp.c:51:
> include/linux/serialP.h:27:6: warning: "LINUX_VERSION_CODE" is not defined

> The code that trips it up:

> #if (LINUX_VERSION_CODE < 0x020300)
> /* Unfortunate, but Linux 2.2 needs async_icount defined here and
>  * it got moved in 2.3 */
> #include <linux/serial.h>
> #endif

> It's unclear if this should be fixed by adding a #include <linux/version.h>
> to esp.c, or if this code should summarily be lopped out of serialP.h.

My personal feeling woudl be to lop it out, and fix up anywhere
and everywhere which complains appropraitely.

--

             http://www.arm.linux.org.uk/personal/aboutme.html

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

 
 
 

2.5.60 - drivers/char/esp.c vs include/linux/serialP.h

Post by Valdis.Kletni.. » Sat, 15 Feb 2003 23:30:13


On Fri, 14 Feb 2003 20:54:49 GMT, Russell King said:


> > compiling drivers/char/esp.c with -Wundef triggers a warning:

> > In file included from drivers/char/esp.c:51:
> > include/linux/serialP.h:27:6: warning: "LINUX_VERSION_CODE" is not defined
> My personal feeling woudl be to lop it out, and fix up anywhere
> and everywhere which complains appropraitely.

I jumped the gun, actually - the build was still running, and there's at
least 6 other things that trigger the same serialP.h warning - where there's
a #if (VAR < NNNN) check that Does The Wrong Thing because of the default
gcc behavior for undefineds.  Hopefully this one's harmless - but there's
still 608 other warnings to work through.

  application_pgp-signature_part
< 1K Download