Re: [PATCH] __init in mm/slab.c
From: Andries Brouwer
Date: Sun Nov 14 2004 - 06:18:42 EST
On Sun, Nov 14, 2004 at 09:18:00AM +0100, Manfred Spraul wrote:
> g_cpucache_up is NONE during bootstrap and FULL after boot. Thus the
> initarray is never accessed after boot.
> Andries, why did you propose this change? Does the current code trigger
> an automatic test?
Yes. I was a bit more explicit in the timer patch:
"The i386 timers use a struct timer_opts that has a field init
pointing at a __init function. The rest of the struct is not __init.
Nothing is wrong, but if we want to avoid having references to init stuff
in non-init sections, some reshuffling is needed."
So yesterday's series of __init patches is not because there were
bugs, but because it is desirable to have the situation where
static inspection of the object code shows absence of references
to .init stuff. Much better than having to reason that there is
a reference but that it will not be used.
Where the memory win is important the code should be rewritten a bit.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/