All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] Modules architecture
@ 2010-03-03 10:51 Sergey Naumov
  2010-03-03 10:54 ` Lionel Landwerlin
  2010-03-03 15:03 ` Thomas Petazzoni
  0 siblings, 2 replies; 6+ messages in thread
From: Sergey Naumov @ 2010-03-03 10:51 UTC (permalink / raw)
  To: buildroot

Hello.

There is a problem with kernel building when .config contains processor
architecture that differs from BR2_ARCH. Then kernel will have architecture
as in BR2_ARCH and modules as in .config.
Expectable behavior is to apply BR2_ARCH to both of them, or ignore it.

As a result of the current implementation I got "invalid module format" for
all modules compiled with the kernel.

What should I do to avoid it "through buildroot configs", but not through
changing architecture in kernel config?

Sergey.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100303/7a0395e9/attachment.htm>

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

* [Buildroot] Modules architecture
  2010-03-03 10:51 [Buildroot] Modules architecture Sergey Naumov
@ 2010-03-03 10:54 ` Lionel Landwerlin
  2010-03-03 13:13   ` Sergey Naumov
  2010-03-03 15:03 ` Thomas Petazzoni
  1 sibling, 1 reply; 6+ messages in thread
From: Lionel Landwerlin @ 2010-03-03 10:54 UTC (permalink / raw)
  To: buildroot

Use KERNEL_ARCH variable.
It's computed from BR2_ARCH in buildroot's makefiles.

--
Lionel

On Wed, Mar 3, 2010 at 11:51 AM, Sergey Naumov <sknaumov@gmail.com> wrote:
> Hello.
> There is a problem with kernel building when .config contains processor
> architecture that differs from BR2_ARCH. Then kernel will have architecture
> as in BR2_ARCH and modules as in?.config.
> Expectable behavior is to apply BR2_ARCH to both of them, or ignore it.
> As a result of the current implementation I got "invalid module format" for
> all modules compiled with the kernel.
> What should I do to avoid it "through buildroot configs", but not through
> changing architecture in kernel config?
> Sergey.
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
>

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

* [Buildroot] Modules architecture
  2010-03-03 10:54 ` Lionel Landwerlin
@ 2010-03-03 13:13   ` Sergey Naumov
  0 siblings, 0 replies; 6+ messages in thread
From: Sergey Naumov @ 2010-03-03 13:13 UTC (permalink / raw)
  To: buildroot

KERNEL_ARCH variable is set to i386 for my configuration, as I understand it
from Makefile, but as I saw in Makefiles its rather makes influence on paths
to modules than on .config file.
Is it possible to avoid buildroot's interference in the build process of
kernel with standard options, but keep all other useful features of
buildroot (so I want kernel to build on a toolchain, but along with
modules.)?

Sergey.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100303/ebcbcff7/attachment.htm>

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

* [Buildroot] Modules architecture
  2010-03-03 10:51 [Buildroot] Modules architecture Sergey Naumov
  2010-03-03 10:54 ` Lionel Landwerlin
@ 2010-03-03 15:03 ` Thomas Petazzoni
  2010-03-03 15:46   ` Sergey Naumov
  1 sibling, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2010-03-03 15:03 UTC (permalink / raw)
  To: buildroot

On Wed, 3 Mar 2010 13:51:05 +0300
Sergey Naumov <sknaumov@gmail.com> wrote:

> There is a problem with kernel building when .config contains
> processor architecture that differs from BR2_ARCH. Then kernel will
> have architecture as in BR2_ARCH and modules as in .config.
> Expectable behavior is to apply BR2_ARCH to both of them, or ignore
> it.
> 
> As a result of the current implementation I got "invalid module
> format" for all modules compiled with the kernel.
> 
> What should I do to avoid it "through buildroot configs", but not
> through changing architecture in kernel config?

Could you give a specific configuration example with which you have
problem ?

Thanks,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

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

* [Buildroot] Modules architecture
  2010-03-03 15:03 ` Thomas Petazzoni
@ 2010-03-03 15:46   ` Sergey Naumov
  2010-03-04 15:52     ` Sergey Naumov
  0 siblings, 1 reply; 6+ messages in thread
From: Sergey Naumov @ 2010-03-03 15:46 UTC (permalink / raw)
  To: buildroot

How I get this trouble (steps):
1. I downloaded the latest buildroot package and all needed packages
(including the kernel) form buildroot/downloads.
2. I unpacked your linux-2.6.32 package in a separate directory, put my
previous kernel config from linux-2.6.26 to this directory and run "make
menuconfig" to convert it to a config for a new linux version. (Note that
CONFIG_M586=y)
3. Then I run "make menuconfig" in the buildroot project top directory,
adjusted configuration for my purposes and specified path to my
kernel-2.6.32 .config file. Also I specified target architecture family as
i386 and target architecture as 586.

*Resulting configs for buildroot and linux-2.6.32 are attached to the mail.*

4. I ran make, got image.ext2 file and dd it to my Compact Flash card. Then
I installed grub.

After boot each modprobe of module resulted in "invalid module format"
error.

I suppose that problem can occur because of separate compilation of kernel
and modules under buildroot.
When I compiled the kernel with the same .config file manually, all was OK.

Sergey.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100303/c310777d/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config-buildroot
Type: application/octet-stream
Size: 20382 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100303/c310777d/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config-kernel
Type: application/octet-stream
Size: 51593 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100303/c310777d/attachment-0003.obj>

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

* [Buildroot] Modules architecture
  2010-03-03 15:46   ` Sergey Naumov
@ 2010-03-04 15:52     ` Sergey Naumov
  0 siblings, 0 replies; 6+ messages in thread
From: Sergey Naumov @ 2010-03-04 15:52 UTC (permalink / raw)
  To: buildroot

>
> Hello again.
If it is interesting for you, I overcome the problem with "invalid module
format" through deleting target "modules" in
./target/linux/Makefile.in.advanced in modules-building section, so "make"
is invoked there without targets. So now my kernel image builds along with
modules.
But the question is should it be considered as buildroot bug or as my fault
with configs?

Sergey.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20100304/ca74d756/attachment.htm>

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

end of thread, other threads:[~2010-03-04 15:52 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-03 10:51 [Buildroot] Modules architecture Sergey Naumov
2010-03-03 10:54 ` Lionel Landwerlin
2010-03-03 13:13   ` Sergey Naumov
2010-03-03 15:03 ` Thomas Petazzoni
2010-03-03 15:46   ` Sergey Naumov
2010-03-04 15:52     ` Sergey Naumov

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.