Created attachment 73175 [details] .config used with the kernel Recently, I installed Arch Linux and use their GCC 4.6.3 to compile the kernel. The first one I compiled on that Linux distribution was 3.3.1. I had no problems related to the kernel, but one. As soon as I started the Midnight Commander file manager, I got the attached kernel panic (while it was captured with VirtualBox, I can reproduce it under plain Linux). After dozens of kernel recompilations using 'git bisect' and not being able to reproduce it, I noticed that what caused the kernel panic was a modified keymap I had on my other tree. After more tests, I noticed that it only happens if I don't load another or the same keymap with 'loadkeys' while or after booting. After more tests, I could reproduce it under Slackware Linux -current, compiling the kernel with their GCC 4.7.0. Then, I decided to try GCC 4.5.2 from Slackware 13.37, because either the issue had started recently due to the additional 'loadkeys', or the new GCC was to blame (before Arch Linux, my most recent GCC had been 4.5.3). And yes, I couldn't reproduce it with 4.5.2. While I have no idea if this is a GCC or kernel but, I think it's worth reporting. https://bugzilla.kernel.org/show_bug.cgi?id=15758 looked similar, but is from 2010 and the user reported that it started in 2009, way before GCC 4.6.
Created attachment 73176 [details] kernel panic with the kernel
(In reply to comment #0) > After more tests, I noticed that it only happens if I don't load another or > the > same keymap with 'loadkeys' while or after booting. Sorry, that should read: "After more tests, I noticed that it only happens if I load another or the same keymap with 'loadkeys' while or after booting."
Created attachment 73177 [details] modified defkeymap.c created with 'loadkeys --mktable br-latin1-abnt2'
Just additional information and omission. I can't reproduce it from a X terminal emulator nor connecting with ssh. Also, Midnight Commander isn't involved in any way. While my first kernel panic manifested when I pressed the F3 key inside the file manager to read a file, the crash also happens from a bash shell. And if you load another keymap, like "us", the crash occurs pressing an arrow key, what doesn't happen with "br-abnt2" nor "br-latin1-abnt2". It's just a matter of pressing keys until you get the crash.
Can you attach the actual keymap file Alan
Alan, if you mean the one that crashes the kernel, I attached it earlier at https://bugzilla.kernel.org/attachment.cgi?id=73177 . It's the "br-latin1-abnt2". But I think it crashes with any keymap you generate to replace "defkeymap.c_shipped". I noticed some apparent differences in defkeymap.o using GCC 4.5.2 and 4.6.3, but it's greek for me. I don't know if it's miscompiling the object, and if so, if it's causing the crash. It's just strange to me that the crash only happens if I also use 'loadkeys'. Without doing that, the modified keympap works as expected and all keys appear to be right.
Ah ok.. now I understand. The object file may well different, but the actual data loaded into the kernel via loadkeys isn't a .o file so that shouldn't matter. No matter how broken the keymap file is using it with "loadkeys" shouldn't crash the kernel so I shall do some digging
*** This bug has been marked as a duplicate of bug 15758 ***