Re: [PATCH] removal of "static foo = 0" from drivers/ide (test11)

From: Russell King (rmk@arm.linux.org.uk)
Date: Wed Nov 22 2000 - 06:40:20 EST


J . A . Magallon writes:
> On Tue, 21 Nov 2000 22:25:01 Bartlomiej Zolnierkiewicz wrote:
> > -static int basePort = 0; /* base port address */
> > -static int regPort = 0; /* port for register number */
> > -static int dataPort = 0; /* port for register data */
> > +static int basePort; /* base port address */
> > +static int regPort; /* port for register number */
> > +static int dataPort; /* port for register data */
>
> That is not too much confidence on the ANSI-ness of the compiler ???

Its got nothing to do with the ANSI-ness of the compiler, but more to do
with the C startup code - does the C startup code initialise BSS to zero
or does it not?

In this particular example, we have full control over it; in the kernel
has our own start up code which does initialise the BSS to zero.

In the dim and distant past (about 7-8 years ago), it was true that we
didn't init the BSS and everything had to be initialised, but this is
long gone.
   _____
  |_____| ------------------------------------------------- ---+---+-
  | | Russell King rmk@arm.linux.org.uk --- ---
  | | | | http://www.arm.linux.org.uk/personal/aboutme.html / / |
  | +-+-+ --- -+-
  / | THE developer of ARM Linux |+| /|\
 / | | | --- |
    +-+-+ ------------------------------------------------- /\\\ |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Nov 23 2000 - 21:00:23 EST