Re: [PATCH] 2.5.21 kill warnings 4/19

From: Andrew Morton (akpm@zip.com.au)
Date: Mon Jun 10 2002 - 15:00:25 EST


Thunder from the hill wrote:
>
> Hi,
>
> On Mon, 10 Jun 2002, Andrew Morton wrote:
> > __func__ does *not* work on egcs-1.1.2 and so cannot be used in Linux.
> >
> > `struct blah = { .open = driver_open };' *does* work in egcs-1.1.2
> > and is OK to use.
>
> Gee. I guess we need a special host gcc to support our needs - on
> sparc(|64). We might have a patch that easily renames it in the sources of
> egcs...

?

> Anyway, what is the problem about new gcc on old sparc? It works at least
> on my sparc64, I can't complain.

I don't know - we need to find a davem to answer that question.

egcs-1.1.2 has a problem with the percpu infrastructure - it
fails to put the right things in the right sections. The
workaround for that is to ensure that the percpu data structures
are always initialised at the definition site:

        /* Some compilers disobey section attribute on statics when not
           initialized -- RR */
        static struct tasklet_head tasklet_vec __per_cpu_data = { NULL };
        static struct tasklet_head tasklet_hi_vec __per_cpu_data = { NULL };

Note the (otherwise unneeded) `= { NULL }'. The result of getting
this wrong is a nasty and subtly-dead kernel.

It's not a very happy state of affairs. I'll be using
2.91.66 on x86 from now on, so any problems (in the stuff
which I build and test) will be picked up.

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



This archive was generated by hypermail 2b29 : Sat Jun 15 2002 - 22:00:19 EST