[2.6.24 patch] x86: allow 64bit setting in Kconfig - Kernel

This is a discussion on [2.6.24 patch] x86: allow 64bit setting in Kconfig - Kernel ; Recently someone told me he had a bug on x86 and to reproduce it I should "'make allyesconfig' and disable CONFIG_HOTPLUG=y". But I didn't see it. "make allyesconfig" is ambiguous on x86 and he had a 64bit computer. There go ...

+ Reply to Thread
Results 1 to 11 of 11

Thread: [2.6.24 patch] x86: allow 64bit setting in Kconfig

  1. [2.6.24 patch] x86: allow 64bit setting in Kconfig

    Recently someone told me he had a bug on x86 and to reproduce
    it I should "'make allyesconfig' and disable CONFIG_HOTPLUG=y".

    But I didn't see it.

    "make allyesconfig" is ambiguous on x86 and he had a 64bit computer.

    There go another two hours compile time.

    It makes sense to have the Kconfig default and the defconfig based on
    whether you are on a 32bit or a 64bit machine, but it's complete
    nonsense to not offer the Kconfig variable unless you had explicitely
    given ARCH=x86 (in which case you could as well immediately set the ARCH
    to i386 or x86_64).

    Signed-off-by: Adrian Bunk

    ---
    fcf848366a166812fa32b2a22f2631fcd4982cb4
    diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
    index 80b7ba4..0e6e74d 100644
    --- a/arch/x86/Kconfig
    +++ b/arch/x86/Kconfig
    @@ -3,7 +3,7 @@ mainmenu "Linux Kernel Configuration for x86"

    # Select 32 or 64 bit
    config 64BIT
    - bool "64-bit kernel" if ARCH = "x86"
    + bool "64-bit kernel"
    default ARCH = "x86_64"
    help
    Say yes to build a 64-bit kernel - formerly known as x86_64

    --
    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/

  2. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    * Adrian Bunk wrote:

    > # Select 32 or 64 bit
    > config 64BIT
    > - bool "64-bit kernel" if ARCH = "x86"
    > + bool "64-bit kernel"
    > default ARCH = "x86_64"
    > help
    > Say yes to build a 64-bit kernel - formerly known as x86_64


    thx, i've added this to x86.git.

    Ingo
    --
    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/

  3. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    On Fri, 2008-01-18 at 11:44 +0100, Ingo Molnar wrote:
    > * Adrian Bunk wrote:
    >
    > > # Select 32 or 64 bit
    > > config 64BIT
    > > - bool "64-bit kernel" if ARCH = "x86"
    > > + bool "64-bit kernel"
    > > default ARCH = "x86_64"
    > > help
    > > Say yes to build a 64-bit kernel - formerly known as x86_64

    >
    > thx, i've added this to x86.git.


    Style question, would the following be preferred?

    config 64BIT
    def_bool ARCH = "x86_64"
    prompt "64-bit kernel"
    help...


    Cheers,

    Harvey

    --
    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/

  4. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig

    On Fri, Jan 18, 2008 at 02:50:48AM -0800, Harvey Harrison wrote:
    >
    > On Fri, 2008-01-18 at 11:44 +0100, Ingo Molnar wrote:
    > > * Adrian Bunk wrote:
    > >
    > > > # Select 32 or 64 bit
    > > > config 64BIT
    > > > - bool "64-bit kernel" if ARCH = "x86"
    > > > + bool "64-bit kernel"
    > > > default ARCH = "x86_64"
    > > > help
    > > > Say yes to build a 64-bit kernel - formerly known as x86_64

    > >
    > > thx, i've added this to x86.git.

    >
    > Style question, would the following be preferred?
    >
    > config 64BIT
    > def_bool ARCH = "x86_64"
    > prompt "64-bit kernel"
    > help...


    No.
    It is most common to let the prompt follow the type and not
    as a separate property.

    Sam
    --
    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/

  5. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    * Harvey Harrison wrote:

    >
    > On Fri, 2008-01-18 at 11:44 +0100, Ingo Molnar wrote:
    > > * Adrian Bunk wrote:
    > >
    > > > # Select 32 or 64 bit
    > > > config 64BIT
    > > > - bool "64-bit kernel" if ARCH = "x86"
    > > > + bool "64-bit kernel"
    > > > default ARCH = "x86_64"
    > > > help
    > > > Say yes to build a 64-bit kernel - formerly known as x86_64

    > >
    > > thx, i've added this to x86.git.

    >
    > Style question, would the following be preferred?
    >
    > config 64BIT
    > def_bool ARCH = "x86_64"
    > prompt "64-bit kernel"
    > help...


    sure, we could do that too.

    Ingo
    --
    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/

  6. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    * Sam Ravnborg wrote:

    > > Style question, would the following be preferred?
    > >
    > > config 64BIT
    > > def_bool ARCH = "x86_64"
    > > prompt "64-bit kernel"
    > > help...

    >
    > No.
    > It is most common to let the prompt follow the type and not
    > as a separate property.


    hm, ok. I guess there's not much cleanliness difference between:

    bool "64-bit kernel"
    default ARCH = "x86_64"

    and:

    def_bool ARCH = "x86_64"
    prompt "64-bit kernel"

    Ingo
    --
    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/

  7. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig

    On Fri, Jan 18, 2008 at 01:02:48PM +0100, Ingo Molnar wrote:
    >
    > * Sam Ravnborg wrote:
    >
    > > > Style question, would the following be preferred?
    > > >
    > > > config 64BIT
    > > > def_bool ARCH = "x86_64"
    > > > prompt "64-bit kernel"
    > > > help...

    > >
    > > No.
    > > It is most common to let the prompt follow the type and not
    > > as a separate property.

    >
    > hm, ok. I guess there's not much cleanliness difference between:
    >
    > bool "64-bit kernel"
    > default ARCH = "x86_64"
    >
    > and:
    >
    > def_bool ARCH = "x86_64"
    > prompt "64-bit kernel"


    At least for me it's clear what the former does while I had to try the
    latter for understanding what it does exactly...

    > Ingo


    cu
    Adrian

    --

    "Is there not promise of rain?" Ling Tan asked suddenly out
    of the darkness. There had been need of rain for many days.
    "Only a promise," Lao Er said.
    Pearl S. Buck - Dragon Seed

    --
    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/

  8. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    * Ingo Molnar wrote:

    >
    > * Adrian Bunk wrote:
    >
    > > # Select 32 or 64 bit
    > > config 64BIT
    > > - bool "64-bit kernel" if ARCH = "x86"
    > > + bool "64-bit kernel"
    > > default ARCH = "x86_64"
    > > help
    > > Say yes to build a 64-bit kernel - formerly known as x86_64

    >
    > thx, i've added this to x86.git.


    this broke "make ARCH=i386 randconfig" from working when there's a
    64-bit .config present. (it will not properly generate a 32-bit config,
    but still a 64-bit config)

    Ingo
    --
    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/

  9. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig

    On Fri, Jan 18, 2008 at 06:00:37PM +0100, Ingo Molnar wrote:
    >
    > * Ingo Molnar wrote:
    >
    > >
    > > * Adrian Bunk wrote:
    > >
    > > > # Select 32 or 64 bit
    > > > config 64BIT
    > > > - bool "64-bit kernel" if ARCH = "x86"
    > > > + bool "64-bit kernel"
    > > > default ARCH = "x86_64"
    > > > help
    > > > Say yes to build a 64-bit kernel - formerly known as x86_64

    > >
    > > thx, i've added this to x86.git.

    >
    > this broke "make ARCH=i386 randconfig" from working when there's a
    > 64-bit .config present. (it will not properly generate a 32-bit config,
    > but still a 64-bit config)


    Does it always generate a 64bit .config or randomly a 32bit or 64bit
    ..config?

    As far as I see it's the latter.

    If the unified x86 architecture should be presented as one
    architecture in kconfig that's expected - and it might even reduce the
    amount of 32bit compile errors that recently occured in the git-x86
    tree...

    > Ingo


    cu
    Adrian

    --

    "Is there not promise of rain?" Ling Tan asked suddenly out
    of the darkness. There had been need of rain for many days.
    "Only a promise," Lao Er said.
    Pearl S. Buck - Dragon Seed

    --
    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/

  10. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig


    * Adrian Bunk wrote:

    > > > thx, i've added this to x86.git.

    > >
    > > this broke "make ARCH=i386 randconfig" from working when there's a
    > > 64-bit .config present. (it will not properly generate a 32-bit
    > > config, but still a 64-bit config)

    >
    > Does it always generate a 64bit .config or randomly a 32bit or 64bit
    > .config?
    >
    > As far as I see it's the latter.


    it inherits the existing .config's arch setting - and that's what people
    expect. I use a tree either in 64-bit mode or in 32-bit mode, fully
    driven via the .config alone. The Kbuild magic picks up the right arch
    variant and it all just works fine.

    Ingo
    --
    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/

  11. Re: [2.6.24 patch] x86: allow 64bit setting in Kconfig

    On Fri, Jan 18, 2008 at 10:06:33PM +0100, Ingo Molnar wrote:
    >
    > * Adrian Bunk wrote:
    >
    > > > > thx, i've added this to x86.git.
    > > >
    > > > this broke "make ARCH=i386 randconfig" from working when there's a
    > > > 64-bit .config present. (it will not properly generate a 32-bit
    > > > config, but still a 64-bit config)

    > >
    > > Does it always generate a 64bit .config or randomly a 32bit or 64bit
    > > .config?
    > >
    > > As far as I see it's the latter.

    >
    > it inherits the existing .config's arch setting - and that's what people
    > expect. I use a tree either in 64-bit mode or in 32-bit mode, fully
    > driven via the .config alone. The Kbuild magic picks up the right arch
    > variant and it all just works fine.


    If you think anything was "fully driven via the .config alone" you
    seem to neither understand how it works without my patch nor how it
    works with my patch.

    What drives your build without my patch is _not_ the .config but your
    ARCH=i386.

    When understand this, you might start understanding why I bang my head
    against the wall each time a "make" fails on a 64bit .config when I try
    to reproduce some compile or section mismatch problem someone reported
    and kconfig automatically forces CONFIG_64BIT=n since I'm on a 32bit
    computer.

    Can we please get my patch into 2.6.24 so that we'll get _one_
    architecture in kconfig and not the current mess with three different
    situations in kconfig based on the ARCH setting (and the 32/64bit of
    your userspace forcing a CONFIG_64BIT setting you have to override with
    ARCH= on the command line)?

    > Ingo


    cu
    Adrian

    BTW: The correct way to drive your randconfigs (that is not limited to
    to 32/64bit) is to use KCONFIG_ALLCONFIG.


    --

    "Is there not promise of rain?" Ling Tan asked suddenly out
    of the darkness. There had been need of rain for many days.
    "Only a promise," Lao Er said.
    Pearl S. Buck - Dragon Seed

    --
    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/

+ Reply to Thread