Currently we run grub-mkconfig then go and edit the generated output in /boot/grub/grub.cfg to override the "root=" arguments to our label. If another element like project-config's finalise.d/99-fix-grub-timeout then goes and re-runs grub2-install, it overwrites these changes. Grub has GRUB_DEVICE which should override the root device. Let's try using this. Maybe it wasn't around at the time, this code is more-or-less unchanged from I7d83bb2b359e7a8c3858eca04c96e35cf4e1fe9e Change-Id: Ibaaa81124098f3c6febe48e455d3e1cd0a5f1761
bootloader
Installs grub[2] on boot partition on the system. In
case GRUB2 is not available in the system, a fallback to Extlinux will
happen. It's also possible to enforce the use of Extlinux by exporting a
DIB_EXTLINUX variable to the environment.
Arguments
DIB_GRUB_TIMEOUTsets thegrubmenu timeout. It defaults to 5 seconds. Set this to 0 (no timeout) for fast boot times.