Re: [GIT PATCHES] kbuild updates
From: Linus Torvalds
Date: Tue Jan 10 2006 - 11:27:15 EST
On Mon, 9 Jan 2006, Sam Ravnborg wrote:
>
> Please pull from:
> ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/kbuild.git
Ok, pulled.
However, fixing up a trivial conflict in i386/Makefile, I noticed this:
cflags-$(CONFIG_REGPARM) += $(shell if [ $(call cc-version) -ge 0300 ] ; then \
echo "-mregparm=3"; fi ;)
and it strikes me that this is WRONG.
It's wrong for some subtle reasons: it means that CONFIG_REGPARM is set
whether or not it is actually _used_, which means that anybody who depends
on CONFIG_REGPARM in the sources is just screwed.
Now, for this particular usage, the only breakage is in the i386
<asm/module.h>, which will report "REGPARM" in MODULE_REGPARM regardless
of whether the kernel was compiled with -mregparm=3 or not. So it's mainly
cosmetic.
But it strikes me that we'd be a _lot_ better off if the Kconfig phase
would check the compiler version, instead of us checking it dynamically a
hundred times in the Makefiles. It would be more efficient, and we could
make things like this more _correct_.
Comments?
Linus
-
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/