insmod broken in 1.1.1

Rob Landley rob at landley.net
Sat Mar 25 02:46:52 UTC 2006


On Friday 24 March 2006 1:50 pm, stephane.billiart wrote:
> I tried to upgrade my system today with busybox and realized
> that insmod systematically fails with the messages:
> insmod: ELF file not for this architecture
> insmod: Could not load the module: Success
>
> I added some debug output and saw that the error comes from
> line 3334 of modutils/insmod.c because of ELFDATAM is
> wrongly set on line 519 because BB_LITTLE_ENDIAN is
> not defined (although I am on a P3 compiling for an Elan processor
> which are little endians).
>
> I haven't looked at how BB_LITTLE_ENDIAN is supposed to be
> calculated but there's apparently something wrong there.
> I am not sure how to best fix this so I'm asking the list first.
>
> In 1.1.0 everything worked ok and the test was
> #if __BYTE_ORDER == __LITTLE_ENDIAN

And _this_ is why you want to use if(ENABLE_BLAH) instead of #if ENABLE_BLAH, 
so the compiler barfs if you get the symbol wrong rather than silently 
ignoring it.  (And no, "#ifdef UNKNOWN_SYMBOL" never caught this sort of 
thing either.)

Sigh.  Ok, I'm going to need to throw a patch in the download directory.  (No, 
I'm not coming out with 1.1.1.1, which would be silly.  It'll be 
"busybox-1.1.1.fixes.patch", and we append to it as needed, just for things 
that _would_ have been show stopper bugs if anybody had actually tested the 
thing before we shiped.  (Deal with it.)

1.1.2 is scheduled for June, and I'll start tightening down the tree about 
mid-may.  That's soon enough.

Rob
-- 
Never bet against the cheap plastic solution.




More information about the busybox mailing list