Alignment trap in kernel: swapper (0) message

I am a newbie regarding the Beagleboard XM so please excuse if this is a naive question. On occasions I see the following message on the console using the default image supplied with the board:

root@beagleboard:~# [ 1412.340881] Alignment trap in kernel: swapper (0) PC=0xc0436954 Instr=0xe8930003 Address=0xdeef802a FSR 0x001

Searching the archives I found a suggestion to remove IPv6 support which I did by renaming /lib/modules/2.6.32/kernel/net/ipv6/ipv6.ko to /lib/modules/2.6.32/kernel/net/ipv6/ipv6.ko.orig.

The system appears to still work fine, but I still occasionally get the above message on the console.

Best regards,

Dave.

David Lambert <dave@lambsys.com> writes:

I am a newbie regarding the Beagleboard XM so please excuse if this is
a naive question. On occasions I see the following message on the
console using the default image supplied with the board:

root@beagleboard:~# [ 1412.340881] Alignment trap in kernel: swapper
(0) PC=0xc0436954 Instr=0xe8930003 Address=0xdeef802a FSR 0x001

Searching the archives I found a suggestion to remove IPv6 support
which I did by renaming /lib/modules/2.6.32/kernel/net/ipv6/ipv6.ko to
/lib/modules/2.6.32/kernel/net/ipv6/ipv6.ko.orig.

The system appears to still work fine, but I still occasionally get
the above message on the console.

There are a few other places in networking code that seem to (at least
sometimes) rely on unaligned trap handling. I've seen it in some ICMP
handlers, for instance.

In my opinion, such code should be fixed so as never to do unaligned
accesses. Unfortunately, the powers that be seem to disagree about
this, and there's nothing I can do.

This can be caused by several problems,

but a friend of mine solved this problem with:

echo 2 > /proc/cpu/alignment

which tells the kernel to capture and correct illegal memory accesses.
You can also use 3 instead of 2 to prevent the messages from getting
in the log messages.

And suddenly your beagle is twice as slow. Mans and I spent way too much time in 2008 to figure that out.