[N900/rx-51] Need ability to load keymaps in initramfs
This ticket is for brainstorming how this might be accomplished.
The RX51/N900 needs a custom keymap at boot to be able to enter numbers for unlocking rootfs. Keymaps, in binary format, can be loaded using busybox's loadkmap plugin:
loadkmap < rx_51_kmap.bin
The binary can be generated by running a .map file through loadkeys -b
(I did this on a system with Arch Linux).
The problem is that mkinitfs.sh does not allow for importing arbitrary files into initramfs, the only custom files it will import are those under 'hooks', and only files with a .sh extension.
So there are two immediate possible solutions:
-
extent mkinitfs.sh to allow importing arbitrary files into the initramfs image, so hooks can use them
-
Add some option for identifying keymaps (probably not in the device file, since the desire for users to be able to select keymaps can easily extend beyond unique keyboards on select devices), generating a binary version of the .map file, importing it into the initramfs, and loading it (with a hook) on boot. Maybe 'setting keymap' can be done in
./pmbootstrap init
?
The second option seems like a great way to solve the immediate problem, and the first option seems like it would be desirable if folks really start using hooks for interesting things.