All of lore.kernel.org
 help / color / mirror / Atom feed
* x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09  7:58 ` Rajat Jain
  0 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09  7:58 UTC (permalink / raw)
  To: kernelnewbies

Hi,

Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?

Thanks,

Rajat

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09  7:58 ` Rajat Jain
  0 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09  7:58 UTC (permalink / raw)
  To: linux-newbie, kernelnewbies

Hi,

Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?

Thanks,

Rajat

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09  7:58 ` Rajat Jain
@ 2014-09-09 13:21   ` Valdis.Kletnieks
  -1 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks at vt.edu @ 2014-09-09 13:21 UTC (permalink / raw)
  To: kernelnewbies

On Tue, 09 Sep 2014 07:58:49 -0000, Rajat Jain said:

> Can someone tell me if the i386 one is to be used when we want to build for a
> 32bit machine and the x86_64 is to be used for 64 bit machine?

I wouldn't run either one on an actual machine.  Defconfigs are *example*
configs, only useful as a template for customizing for actual hardware.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 848 bytes
Desc: not available
Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140909/d8c7ad79/attachment.bin 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 13:21   ` Valdis.Kletnieks
  0 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks @ 2014-09-09 13:21 UTC (permalink / raw)
  To: Rajat Jain; +Cc: linux-newbie, kernelnewbies


[-- Attachment #1.1: Type: text/plain, Size: 346 bytes --]

On Tue, 09 Sep 2014 07:58:49 -0000, Rajat Jain said:

> Can someone tell me if the i386 one is to be used when we want to build for a
> 32bit machine and the x86_64 is to be used for 64 bit machine?

I wouldn't run either one on an actual machine.  Defconfigs are *example*
configs, only useful as a template for customizing for actual hardware.

[-- Attachment #1.2: Type: application/pgp-signature, Size: 848 bytes --]

[-- Attachment #2: Type: text/plain, Size: 169 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09  7:58 ` Rajat Jain
@ 2014-09-09 14:06   ` Matthias Brugger
  -1 siblings, 0 replies; 23+ messages in thread
From: Matthias Brugger @ 2014-09-09 14:06 UTC (permalink / raw)
  To: kernelnewbies



On 09/09/14 09:58, Rajat Jain wrote:
> Hi,
> 
> Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?

You can build the kernel with any architecture for any architecture.
This is called cross-compiling. The homepage [0] should explain you how
to do that.

Cheers,
Matthias

[0] http://kernelnewbies.org/FAQ/KernelCrossCompilation

> 
> Thanks,
> 
> Rajat
> 
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 14:06   ` Matthias Brugger
  0 siblings, 0 replies; 23+ messages in thread
From: Matthias Brugger @ 2014-09-09 14:06 UTC (permalink / raw)
  To: Rajat Jain, linux-newbie, kernelnewbies



On 09/09/14 09:58, Rajat Jain wrote:
> Hi,
> 
> Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?

You can build the kernel with any architecture for any architecture.
This is called cross-compiling. The homepage [0] should explain you how
to do that.

Cheers,
Matthias

[0] http://kernelnewbies.org/FAQ/KernelCrossCompilation

> 
> Thanks,
> 
> Rajat
> 
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies@kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 13:21   ` Valdis.Kletnieks
@ 2014-09-09 14:19     ` Paul Bolle
  -1 siblings, 0 replies; 23+ messages in thread
From: Paul Bolle @ 2014-09-09 14:19 UTC (permalink / raw)
  To: kernelnewbies

On Tue, 2014-09-09 at 09:21 -0400, Valdis.Kletnieks at vt.edu wrote:
> On Tue, 09 Sep 2014 07:58:49 -0000, Rajat Jain said:
> > Can someone tell me if the i386 one is to be used when we want to build for a
> > 32bit machine and the x86_64 is to be used for 64 bit machine?
> 
> I wouldn't run either one on an actual machine.  Defconfigs are *example*
> configs, only useful as a template for customizing for actual hardware.

It is probably easiest to take the .config file of the latest kernel of
the distribution you are using as a starting point. In that case you
know that this starting point at least works on your machine.

(I remember seeing tutorials that show you how to generate a .config
from scratch. I wonder whether anyone actually does that. It should be
quite a bit of work for an uncertain outcome. Ie, you might end up
trying quite a few configurations before hitting one that works
reasonably for your machine.)

Hope this helps,


Paul Bolle

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 14:19     ` Paul Bolle
  0 siblings, 0 replies; 23+ messages in thread
From: Paul Bolle @ 2014-09-09 14:19 UTC (permalink / raw)
  To: Valdis.Kletnieks; +Cc: Rajat Jain, linux-newbie, kernelnewbies

On Tue, 2014-09-09 at 09:21 -0400, Valdis.Kletnieks@vt.edu wrote:
> On Tue, 09 Sep 2014 07:58:49 -0000, Rajat Jain said:
> > Can someone tell me if the i386 one is to be used when we want to build for a
> > 32bit machine and the x86_64 is to be used for 64 bit machine?
> 
> I wouldn't run either one on an actual machine.  Defconfigs are *example*
> configs, only useful as a template for customizing for actual hardware.

It is probably easiest to take the .config file of the latest kernel of
the distribution you are using as a starting point. In that case you
know that this starting point at least works on your machine.

(I remember seeing tutorials that show you how to generate a .config
from scratch. I wonder whether anyone actually does that. It should be
quite a bit of work for an uncertain outcome. Ie, you might end up
trying quite a few configurations before hitting one that works
reasonably for your machine.)

Hope this helps,


Paul Bolle

--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 14:19     ` Paul Bolle
@ 2014-09-09 14:26       ` Valdis.Kletnieks
  -1 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks at vt.edu @ 2014-09-09 14:26 UTC (permalink / raw)
  To: kernelnewbies

On Tue, 09 Sep 2014 16:19:54 +0200, Paul Bolle said:

> (I remember seeing tutorials that show you how to generate a .config
> from scratch. I wonder whether anyone actually does that.

Distros did that originally.  Now they just keep delta'ing their
known-working config.  The pain involved was part of why localmodconfig
and friends were created....
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 848 bytes
Desc: not available
Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140909/b8d35054/attachment.bin 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 14:26       ` Valdis.Kletnieks
  0 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks @ 2014-09-09 14:26 UTC (permalink / raw)
  To: Paul Bolle; +Cc: Rajat Jain, linux-newbie, kernelnewbies

[-- Attachment #1: Type: text/plain, Size: 352 bytes --]

On Tue, 09 Sep 2014 16:19:54 +0200, Paul Bolle said:

> (I remember seeing tutorials that show you how to generate a .config
> from scratch. I wonder whether anyone actually does that.

Distros did that originally.  Now they just keep delta'ing their
known-working config.  The pain involved was part of why localmodconfig
and friends were created....

[-- Attachment #2: Type: application/pgp-signature, Size: 848 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 14:06   ` Matthias Brugger
@ 2014-09-09 14:27     ` Valdis.Kletnieks
  -1 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks at vt.edu @ 2014-09-09 14:27 UTC (permalink / raw)
  To: kernelnewbies

On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:

> > Can someone tell me if the i386 one is to be used when we want to build for
> > a 32bit machine and the x86_64 is to be used for 64 bit machine?
>
> You can build the kernel with any architecture for any architecture.
> This is called cross-compiling. The homepage [0] should explain you how
> to do that.

Right, but you still need to use a .config appropriate for the target
machine, which is what I think Rajat was asking about.

A defconfig is usually only known verified to boot on a few (possibly one)
examples of that architecture hardware.  For embedded ARM, it may be one
specific development board or hardware device.  For x86, I think they try
to keep it "will probably kind of sort of boot on generic PC hardware with
a common distro, but anything fancylike a webcam or better graphics than
"vga tty emulation" may not work".

A defconfig is pretty much just a proof of concept starting point for
an actual working config for a given hardware system.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 848 bytes
Desc: not available
Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140909/3339c2ad/attachment.bin 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 14:27     ` Valdis.Kletnieks
  0 siblings, 0 replies; 23+ messages in thread
From: Valdis.Kletnieks @ 2014-09-09 14:27 UTC (permalink / raw)
  To: Matthias Brugger; +Cc: Rajat Jain, linux-newbie, kernelnewbies

[-- Attachment #1: Type: text/plain, Size: 1027 bytes --]

On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:

> > Can someone tell me if the i386 one is to be used when we want to build for
> > a 32bit machine and the x86_64 is to be used for 64 bit machine?
>
> You can build the kernel with any architecture for any architecture.
> This is called cross-compiling. The homepage [0] should explain you how
> to do that.

Right, but you still need to use a .config appropriate for the target
machine, which is what I think Rajat was asking about.

A defconfig is usually only known verified to boot on a few (possibly one)
examples of that architecture hardware.  For embedded ARM, it may be one
specific development board or hardware device.  For x86, I think they try
to keep it "will probably kind of sort of boot on generic PC hardware with
a common distro, but anything fancylike a webcam or better graphics than
"vga tty emulation" may not work".

A defconfig is pretty much just a proof of concept starting point for
an actual working config for a given hardware system.

[-- Attachment #2: Type: application/pgp-signature, Size: 848 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 14:27     ` Valdis.Kletnieks
@ 2014-09-09 14:34       ` Abreu, Ian
  -1 siblings, 0 replies; 23+ messages in thread
From: Abreu, Ian @ 2014-09-09 14:34 UTC (permalink / raw)
  To: kernelnewbies

To add to this, if you're trying to compile a kernel to work for a specific
platform or board and it's not working, 'make menuconfig' is your friend for
taking a bare bones kernel .config and making it your own.



-----Original Message-----
From: linux-newbie-owner@vger.kernel.org
[mailto:linux-newbie-owner at vger.kernel.org] On Behalf Of
Valdis.Kletnieks at vt.edu
Sent: Tuesday, September 09, 2014 10:28 AM
To: Matthias Brugger
Cc: Rajat Jain; linux-newbie at vger.kernel.org; kernelnewbies
Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?

On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:

> > Can someone tell me if the i386 one is to be used when we want to 
> > build for a 32bit machine and the x86_64 is to be used for 64 bit
machine?
>
> You can build the kernel with any architecture for any architecture.
> This is called cross-compiling. The homepage [0] should explain you 
> how to do that.

Right, but you still need to use a .config appropriate for the target
machine, which is what I think Rajat was asking about.

A defconfig is usually only known verified to boot on a few (possibly one)
examples of that architecture hardware.  For embedded ARM, it may be one
specific development board or hardware device.  For x86, I think they try to
keep it "will probably kind of sort of boot on generic PC hardware with a
common distro, but anything fancylike a webcam or better graphics than "vga
tty emulation" may not work".

A defconfig is pretty much just a proof of concept starting point for an
actual working config for a given hardware system.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5596 bytes
Desc: not available
Url : http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140909/483b7a34/attachment.bin 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* RE: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 14:34       ` Abreu, Ian
  0 siblings, 0 replies; 23+ messages in thread
From: Abreu, Ian @ 2014-09-09 14:34 UTC (permalink / raw)
  To: Valdis.Kletnieks, Matthias Brugger
  Cc: Rajat Jain, linux-newbie, kernelnewbies

[-- Attachment #1: Type: text/plain, Size: 1592 bytes --]

To add to this, if you're trying to compile a kernel to work for a specific
platform or board and it's not working, 'make menuconfig' is your friend for
taking a bare bones kernel .config and making it your own.



-----Original Message-----
From: linux-newbie-owner@vger.kernel.org
[mailto:linux-newbie-owner@vger.kernel.org] On Behalf Of
Valdis.Kletnieks@vt.edu
Sent: Tuesday, September 09, 2014 10:28 AM
To: Matthias Brugger
Cc: Rajat Jain; linux-newbie@vger.kernel.org; kernelnewbies
Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?

On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:

> > Can someone tell me if the i386 one is to be used when we want to 
> > build for a 32bit machine and the x86_64 is to be used for 64 bit
machine?
>
> You can build the kernel with any architecture for any architecture.
> This is called cross-compiling. The homepage [0] should explain you 
> how to do that.

Right, but you still need to use a .config appropriate for the target
machine, which is what I think Rajat was asking about.

A defconfig is usually only known verified to boot on a few (possibly one)
examples of that architecture hardware.  For embedded ARM, it may be one
specific development board or hardware device.  For x86, I think they try to
keep it "will probably kind of sort of boot on generic PC hardware with a
common distro, but anything fancylike a webcam or better graphics than "vga
tty emulation" may not work".

A defconfig is pretty much just a proof of concept starting point for an
actual working config for a given hardware system.

[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5596 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 14:27     ` Valdis.Kletnieks
@ 2014-09-09 15:11       ` Rajat Jain
  -1 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09 15:11 UTC (permalink / raw)
  To: kernelnewbies

Hi,

Thank you all for your responses. I got the answer I was looking for:

> Hello Rajat,
> 
> Indeed, the i386 is for 32bits kernels, and x86_64 for 64 bits ones. If you
> generate the configurations using "make ARCH=x86 defconfig" and "make
> ARCH=i386 defconfig", you can easily compare the resulting configurations :
> 
> .config from i386_defconfig :
> #
> # Automatically generated file; DO NOT EDIT.
> # Linux/i386 3.17.0-rc1 Kernel Configuration # # CONFIG_64BIT is not set
> CONFIG_X86_32=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
> CONFIG_OUTPUT_FORMAT="elf32-i386"
> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/i386_defconfig"
> ...
> 
> .config from x86_64_defconfig :
> #
> # Automatically generated file; DO NOT EDIT.
> # Linux/x86 3.17.0-rc1 Kernel Configuration # CONFIG_64BIT=y
> CONFIG_X86_64=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
> CONFIG_OUTPUT_FORMAT="elf64-x86-64"
> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/x86_64_defconfig"
> ...
> 
> As you can see, i386 is the 32 bits variant of the x86 architecture. There are of
> course many more differences between these two configurations.
> 
> Regards,
> 
> Hubert

Thanks all again,

Rajat


> -----Original Message-----
> From: Valdis.Kletnieks at vt.edu [mailto:Valdis.Kletnieks at vt.edu]
> Sent: Tuesday, September 09, 2014 7:28 AM
> To: Matthias Brugger
> Cc: Rajat Jain; linux-newbie at vger.kernel.org; kernelnewbies
> Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?
> 
> On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:
> 
> > > Can someone tell me if the i386 one is to be used when we want to
> > > build for a 32bit machine and the x86_64 is to be used for 64 bit machine?
> >
> > You can build the kernel with any architecture for any architecture.
> > This is called cross-compiling. The homepage [0] should explain you
> > how to do that.
> 
> Right, but you still need to use a .config appropriate for the target machine,
> which is what I think Rajat was asking about.
> 
> A defconfig is usually only known verified to boot on a few (possibly one)
> examples of that architecture hardware.  For embedded ARM, it may be one
> specific development board or hardware device.  For x86, I think they try to
> keep it "will probably kind of sort of boot on generic PC hardware with a
> common distro, but anything fancylike a webcam or better graphics than "vga
> tty emulation" may not work".
> 
> A defconfig is pretty much just a proof of concept starting point for an actual
> working config for a given hardware system.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* RE: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 15:11       ` Rajat Jain
  0 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09 15:11 UTC (permalink / raw)
  To: Valdis.Kletnieks, Matthias Brugger; +Cc: linux-newbie, kernelnewbies

Hi,

Thank you all for your responses. I got the answer I was looking for:

> Hello Rajat,
> 
> Indeed, the i386 is for 32bits kernels, and x86_64 for 64 bits ones. If you
> generate the configurations using "make ARCH=x86 defconfig" and "make
> ARCH=i386 defconfig", you can easily compare the resulting configurations :
> 
> .config from i386_defconfig :
> #
> # Automatically generated file; DO NOT EDIT.
> # Linux/i386 3.17.0-rc1 Kernel Configuration # # CONFIG_64BIT is not set
> CONFIG_X86_32=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
> CONFIG_OUTPUT_FORMAT="elf32-i386"
> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/i386_defconfig"
> ...
> 
> .config from x86_64_defconfig :
> #
> # Automatically generated file; DO NOT EDIT.
> # Linux/x86 3.17.0-rc1 Kernel Configuration # CONFIG_64BIT=y
> CONFIG_X86_64=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
> CONFIG_OUTPUT_FORMAT="elf64-x86-64"
> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/x86_64_defconfig"
> ...
> 
> As you can see, i386 is the 32 bits variant of the x86 architecture. There are of
> course many more differences between these two configurations.
> 
> Regards,
> 
> Hubert

Thanks all again,

Rajat


> -----Original Message-----
> From: Valdis.Kletnieks@vt.edu [mailto:Valdis.Kletnieks@vt.edu]
> Sent: Tuesday, September 09, 2014 7:28 AM
> To: Matthias Brugger
> Cc: Rajat Jain; linux-newbie@vger.kernel.org; kernelnewbies
> Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?
> 
> On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:
> 
> > > Can someone tell me if the i386 one is to be used when we want to
> > > build for a 32bit machine and the x86_64 is to be used for 64 bit machine?
> >
> > You can build the kernel with any architecture for any architecture.
> > This is called cross-compiling. The homepage [0] should explain you
> > how to do that.
> 
> Right, but you still need to use a .config appropriate for the target machine,
> which is what I think Rajat was asking about.
> 
> A defconfig is usually only known verified to boot on a few (possibly one)
> examples of that architecture hardware.  For embedded ARM, it may be one
> specific development board or hardware device.  For x86, I think they try to
> keep it "will probably kind of sort of boot on generic PC hardware with a
> common distro, but anything fancylike a webcam or better graphics than "vga
> tty emulation" may not work".
> 
> A defconfig is pretty much just a proof of concept starting point for an actual
> working config for a given hardware system.
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 15:11       ` Rajat Jain
  (?)
@ 2014-09-09 15:28       ` Hubert CHAUMETTE
  -1 siblings, 0 replies; 23+ messages in thread
From: Hubert CHAUMETTE @ 2014-09-09 15:28 UTC (permalink / raw)
  To: Rajat Jain, Valdis.Kletnieks, Matthias Brugger
  Cc: linux-newbie, kernelnewbies


Le 09/09/2014 17:11, Rajat Jain a écrit :
> Hi,
>
> Thank you all for your responses. I got the answer I was looking for:
>
>> Hello Rajat,
>>
>> Indeed, the i386 is for 32bits kernels, and x86_64 for 64 bits ones. If you
>> generate the configurations using "make ARCH=x86 defconfig" and "make
>> ARCH=i386 defconfig", you can easily compare the resulting configurations :
>>
>> .config from i386_defconfig :
>> #
>> # Automatically generated file; DO NOT EDIT.
>> # Linux/i386 3.17.0-rc1 Kernel Configuration # # CONFIG_64BIT is not set
>> CONFIG_X86_32=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
>> CONFIG_OUTPUT_FORMAT="elf32-i386"
>> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/i386_defconfig"
>> ...
>>
>> .config from x86_64_defconfig :
>> #
>> # Automatically generated file; DO NOT EDIT.
>> # Linux/x86 3.17.0-rc1 Kernel Configuration # CONFIG_64BIT=y
>> CONFIG_X86_64=y CONFIG_X86=y CONFIG_INSTRUCTION_DECODER=y
>> CONFIG_OUTPUT_FORMAT="elf64-x86-64"
>> CONFIG_ARCH_DEFCONFIG="arch/x86/configs/x86_64_defconfig"
>> ...
>>
>> As you can see, i386 is the 32 bits variant of the x86 architecture. There are of
>> course many more differences between these two configurations.
>>
>> Regards,
>>
>> Hubert
> Thanks all again,
>
> Rajat
>
>
>> -----Original Message-----
>> From: Valdis.Kletnieks@vt.edu [mailto:Valdis.Kletnieks@vt.edu]
>> Sent: Tuesday, September 09, 2014 7:28 AM
>> To: Matthias Brugger
>> Cc: Rajat Jain; linux-newbie@vger.kernel.org; kernelnewbies
>> Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?
>>
>> On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:
>>
>>>> Can someone tell me if the i386 one is to be used when we want to
>>>> build for a 32bit machine and the x86_64 is to be used for 64 bit machine?
>>> You can build the kernel with any architecture for any architecture.
>>> This is called cross-compiling. The homepage [0] should explain you
>>> how to do that.
>> Right, but you still need to use a .config appropriate for the target machine,
>> which is what I think Rajat was asking about.
>>
>> A defconfig is usually only known verified to boot on a few (possibly one)
>> examples of that architecture hardware.  For embedded ARM, it may be one
>> specific development board or hardware device.  For x86, I think they try to
>> keep it "will probably kind of sort of boot on generic PC hardware with a
>> common distro, but anything fancylike a webcam or better graphics than "vga
>> tty emulation" may not work".
>>
>> A defconfig is pretty much just a proof of concept starting point for an actual
>> working config for a given hardware system.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

Sorry, I mistakenly replied only to the OP.
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09 14:27     ` Valdis.Kletnieks
@ 2014-09-09 17:51       ` Rajat Jain
  -1 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09 17:51 UTC (permalink / raw)
  To: kernelnewbies

Hi,

> -----Original Message-----
> From: Valdis.Kletnieks at vt.edu [mailto:Valdis.Kletnieks at vt.edu]
> Sent: Tuesday, September 09, 2014 7:28 AM
> To: Matthias Brugger
> Cc: Rajat Jain; linux-newbie at vger.kernel.org; kernelnewbies
> Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?
> 
> On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:
> 
> > > Can someone tell me if the i386 one is to be used when we want to
> > > build for a 32bit machine and the x86_64 is to be used for 64 bit machine?
> >
> > You can build the kernel with any architecture for any architecture.
> > This is called cross-compiling. The homepage [0] should explain you
> > how to do that.
> 
> Right, but you still need to use a .config appropriate for the target machine,
> which is what I think Rajat was asking about.

Right.

I'm trying to generate x86 images for someone else to test, who's going to test it on a standard / generic x86 machine:

https://lkml.org/lkml/2014/9/9/35

What I was not sure is that which config should I use to generate an image for a "standard x86 machine". Now I do understand (I provided him 2 images - 1 for the 32 bit (using i386_defconfig) and another for 64 bit (using x86_64_defconfig).

Thanks,

Rajat


> 
> A defconfig is usually only known verified to boot on a few (possibly one)
> examples of that architecture hardware.  For embedded ARM, it may be one
> specific development board or hardware device.  For x86, I think they try to
> keep it "will probably kind of sort of boot on generic PC hardware with a
> common distro, but anything fancylike a webcam or better graphics than "vga
> tty emulation" may not work".
> 
> A defconfig is pretty much just a proof of concept starting point for an actual
> working config for a given hardware system.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* RE: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-09 17:51       ` Rajat Jain
  0 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-09 17:51 UTC (permalink / raw)
  To: Valdis.Kletnieks, Matthias Brugger; +Cc: linux-newbie, kernelnewbies

Hi,

> -----Original Message-----
> From: Valdis.Kletnieks@vt.edu [mailto:Valdis.Kletnieks@vt.edu]
> Sent: Tuesday, September 09, 2014 7:28 AM
> To: Matthias Brugger
> Cc: Rajat Jain; linux-newbie@vger.kernel.org; kernelnewbies
> Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?
> 
> On Tue, 09 Sep 2014 16:06:07 +0200, Matthias Brugger said:
> 
> > > Can someone tell me if the i386 one is to be used when we want to
> > > build for a 32bit machine and the x86_64 is to be used for 64 bit machine?
> >
> > You can build the kernel with any architecture for any architecture.
> > This is called cross-compiling. The homepage [0] should explain you
> > how to do that.
> 
> Right, but you still need to use a .config appropriate for the target machine,
> which is what I think Rajat was asking about.

Right.

I'm trying to generate x86 images for someone else to test, who's going to test it on a standard / generic x86 machine:

https://lkml.org/lkml/2014/9/9/35

What I was not sure is that which config should I use to generate an image for a "standard x86 machine". Now I do understand (I provided him 2 images - 1 for the 32 bit (using i386_defconfig) and another for 64 bit (using x86_64_defconfig).

Thanks,

Rajat


> 
> A defconfig is usually only known verified to boot on a few (possibly one)
> examples of that architecture hardware.  For embedded ARM, it may be one
> specific development board or hardware device.  For x86, I think they try to
> keep it "will probably kind of sort of boot on generic PC hardware with a
> common distro, but anything fancylike a webcam or better graphics than "vga
> tty emulation" may not work".
> 
> A defconfig is pretty much just a proof of concept starting point for an actual
> working config for a given hardware system.
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" 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.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-09  7:58 ` Rajat Jain
@ 2014-09-13  1:10   ` Peter Teoh
  -1 siblings, 0 replies; 23+ messages in thread
From: Peter Teoh @ 2014-09-13  1:10 UTC (permalink / raw)
  To: kernelnewbies

On Tue, Sep 9, 2014 at 3:58 PM, Rajat Jain <rajatjain@juniper.net> wrote:

> Hi,
>
> Can someone tell me if the i386 one is to be used when we want to build
> for a 32bit machine and the x86_64 is to be used for 64 bit machine?
>


i386 or 32-bit machines?   i think it don't exists anymore, but what likely
is correct: i386-compatible machine.

The i386 config is for 32-bit OS, ie, the entire binaries must be build for
32-bit architecture.

So choose the correct config provided u have the correct userspace
files/libraries to support it.


>
> Thanks,
>
> Rajat
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>



-- 
Regards,
Peter Teoh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140913/94435c4f/attachment.html 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-13  1:10   ` Peter Teoh
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Teoh @ 2014-09-13  1:10 UTC (permalink / raw)
  To: Rajat Jain; +Cc: linux-newbie, kernelnewbies


[-- Attachment #1.1: Type: text/plain, Size: 774 bytes --]

On Tue, Sep 9, 2014 at 3:58 PM, Rajat Jain <rajatjain@juniper.net> wrote:

> Hi,
>
> Can someone tell me if the i386 one is to be used when we want to build
> for a 32bit machine and the x86_64 is to be used for 64 bit machine?
>


i386 or 32-bit machines?   i think it don't exists anymore, but what likely
is correct: i386-compatible machine.

The i386 config is for 32-bit OS, ie, the entire binaries must be build for
32-bit architecture.

So choose the correct config provided u have the correct userspace
files/libraries to support it.


>
> Thanks,
>
> Rajat
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies@kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>



-- 
Regards,
Peter Teoh

[-- Attachment #1.2: Type: text/html, Size: 1618 bytes --]

[-- Attachment #2: Type: text/plain, Size: 169 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 23+ messages in thread

* x86_64_defconfig and i386_defconfig: What is the difference?
  2014-09-13  1:10   ` Peter Teoh
@ 2014-09-13  3:44     ` Rajat Jain
  -1 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-13  3:44 UTC (permalink / raw)
  To: kernelnewbies

Thanks,

One more question. Can I continue to use my same 64bit compiler when compiling images for both?

In the other words, Are both of these ok?

Make CROSS_COMPILE=my-compiler-path- i386_defconfig
Make CROSS_COMPILE=my-compiler-path- all

Make CROSS_COMPILE=my-compiler-path- x86_64_defconfig
Make CROSS_COMPILE=my-compiler-path- all

Where my-compiler-path is the gcc compiler that I use to generate 64 bit code.

Thanks,

Rajat


From: Peter Teoh [mailto:htmldeveloper at gmail.com]
Sent: Friday, September 12, 2014 6:10 PM
To: Rajat Jain
Cc: linux-newbie at vger.kernel.org; kernelnewbies
Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?



On Tue, Sep 9, 2014 at 3:58 PM, Rajat Jain <rajatjain at juniper.net<mailto:rajatjain@juniper.net>> wrote:
Hi,

Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?


i386 or 32-bit machines?   i think it don't exists anymore, but what likely is correct: i386-compatible machine.

The i386 config is for 32-bit OS, ie, the entire binaries must be build for 32-bit architecture.

So choose the correct config provided u have the correct userspace files/libraries to support it.


Thanks,

Rajat

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org<mailto:Kernelnewbies@kernelnewbies.org>
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



--
Regards,
Peter Teoh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140913/5b9e8dc9/attachment.html 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* RE: x86_64_defconfig and i386_defconfig: What is the difference?
@ 2014-09-13  3:44     ` Rajat Jain
  0 siblings, 0 replies; 23+ messages in thread
From: Rajat Jain @ 2014-09-13  3:44 UTC (permalink / raw)
  To: Peter Teoh; +Cc: linux-newbie, kernelnewbies


[-- Attachment #1.1: Type: text/plain, Size: 1536 bytes --]

Thanks,

One more question. Can I continue to use my same 64bit compiler when compiling images for both?

In the other words, Are both of these ok?

Make CROSS_COMPILE=my-compiler-path- i386_defconfig
Make CROSS_COMPILE=my-compiler-path- all

Make CROSS_COMPILE=my-compiler-path- x86_64_defconfig
Make CROSS_COMPILE=my-compiler-path- all

Where my-compiler-path is the gcc compiler that I use to generate 64 bit code.

Thanks,

Rajat


From: Peter Teoh [mailto:htmldeveloper@gmail.com]
Sent: Friday, September 12, 2014 6:10 PM
To: Rajat Jain
Cc: linux-newbie@vger.kernel.org; kernelnewbies
Subject: Re: x86_64_defconfig and i386_defconfig: What is the difference?



On Tue, Sep 9, 2014 at 3:58 PM, Rajat Jain <rajatjain@juniper.net<mailto:rajatjain@juniper.net>> wrote:
Hi,

Can someone tell me if the i386 one is to be used when we want to build for a 32bit machine and the x86_64 is to be used for 64 bit machine?


i386 or 32-bit machines?   i think it don't exists anymore, but what likely is correct: i386-compatible machine.

The i386 config is for 32-bit OS, ie, the entire binaries must be build for 32-bit architecture.

So choose the correct config provided u have the correct userspace files/libraries to support it.


Thanks,

Rajat

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org<mailto:Kernelnewbies@kernelnewbies.org>
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



--
Regards,
Peter Teoh

[-- Attachment #1.2: Type: text/html, Size: 7720 bytes --]

[-- Attachment #2: Type: text/plain, Size: 169 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2014-09-13  3:44 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-09  7:58 x86_64_defconfig and i386_defconfig: What is the difference? Rajat Jain
2014-09-09  7:58 ` Rajat Jain
2014-09-09 13:21 ` Valdis.Kletnieks at vt.edu
2014-09-09 13:21   ` Valdis.Kletnieks
2014-09-09 14:19   ` Paul Bolle
2014-09-09 14:19     ` Paul Bolle
2014-09-09 14:26     ` Valdis.Kletnieks at vt.edu
2014-09-09 14:26       ` Valdis.Kletnieks
2014-09-09 14:06 ` Matthias Brugger
2014-09-09 14:06   ` Matthias Brugger
2014-09-09 14:27   ` Valdis.Kletnieks at vt.edu
2014-09-09 14:27     ` Valdis.Kletnieks
2014-09-09 14:34     ` Abreu, Ian
2014-09-09 14:34       ` Abreu, Ian
2014-09-09 15:11     ` Rajat Jain
2014-09-09 15:11       ` Rajat Jain
2014-09-09 15:28       ` Hubert CHAUMETTE
2014-09-09 17:51     ` Rajat Jain
2014-09-09 17:51       ` Rajat Jain
2014-09-13  1:10 ` Peter Teoh
2014-09-13  1:10   ` Peter Teoh
2014-09-13  3:44   ` Rajat Jain
2014-09-13  3:44     ` Rajat Jain

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.