I need an initramfs for my BeagleBoard xM … since I have its root on NFS (all my SD cards are mostly dead).
So the SD card only has the kernel + initramfs.
Now, I have to generate the initramfs manully each time the kernel is updated by running mkinitpcio -g /boot/initramfs.img -k 4.4.1-2-ARCH (and when I forget, I have to rescue it).
mkinitcpio also supports the -p option, that takes a preset, and can autodetect the kernel version and generate the appropriate initramfs. Unfortunately that autodetection only works on the x86/64 bzImage files - by inspecting the data in the kernel file itself.
Thus, my question is, what needs to be done to detect the version of an ARM zImage kernel file?