Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 468682 - sys-apps/kmod - insmod fails with illegal instruction (bad syscall?)
Summary: sys-apps/kmod - insmod fails with illegal instruction (bad syscall?)
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: ARM Linux
: Normal normal
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-05 17:46 UTC by John Bowler
Modified: 2013-05-06 14:04 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Bowler 2013-05-05 17:46:31 UTC
I ended up reinstalling from scratch to recover, so no longer have emerge info.  It was only *after* reinstalling that I realized modprobe had started crashing (at the insmod step) after I changed from module-init-tools to kmod.

Note that the crash may have been caused by something else I did (I had rebuilt glibc) but under gdb on modprobe or insmod I saw an illegal instruction in /sbin/kmod syscall.S at the ldmfd after a SWI #0.  I assume this is because the number of the syscall was invalid - possibly a kernel config issue.

I was using a kernel built from the rpi github GIT head (git://github.com/raspberrypi/linux) with CONFIG_BLK_DEV_BSG set (suggested by udev).  No module could be loaded (lsmod, which worked fine, showed nothing).  With an identical kernel module-init-tools modprobe seems to work just fine.
Comment 1 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-05-05 20:26:31 UTC
Illegal instruction could mean that your modprobe was built with incorrect compiler flags.
Comment 2 John Bowler 2013-05-05 21:08:23 UTC
The code looked (In reply to comment #1)
> Illegal instruction could mean that your modprobe was built with incorrect
> compiler flags.

The code looked correct; a SWI followed by an LDMFD, both instructions were in the ARM 1 ;-)

Of course it's possible, but then I don't see why it was just kmod, and why it happened in syscall.S at something that looked innocuous.  I'd rebuilt everything that depended on libc.so

If I'm right, however, it implies that it will repro on any Rpi, and I note that 'stable' now pulls kmod.  I'll double check since I now have a kernel build with no boot-time module requirements.
Comment 3 John Bowler 2013-05-06 14:04:55 UTC
I can no longer reproduce the problem.  I'm guessing it was actually a problem with the recomplication of libc, where compiler flags (CFLAGS) were empty.  That seems a little weird, but it's the only obvious thing that happened other than upgrading the compiler.

The only other possibility is that ~arm has problems (I'm now using stable.)