Scot Doyle
2015-Feb-06 03:18 UTC
[syslinux] regression: relocatable kernels on a chromebook
A Toshiba CB35 Chromebook running Google's stock SeaBIOS reboots after selecting a relocatable kernel from extlinux 6.03. This is a regression caused by commit 8f470e7b movebits: Add syslinux_memmap_find() which factors syslinux_memmap_find() out of bios_boot_linux(). Prior to the refactoring, prot_mode_size was passed as the length in the first call to syslinux_memmap_type(). After the refactoring, hdr.init_size was passed. Now, with commit ef81a3ad, one or the other is passed according to whether the kernel is relocatable. bios_boot_linux() reaches syslinux_shuffle_boot_rm(), rebooting if the kernel is relocatable and successfully starting the kernel if not. If I modify syslinux_memmap_find() to pass prot_mode_size as the length to syslinux_memmap_type(), extlinux 6.03 is able to start both types of kernel. Possibly related to https://bugzilla.redhat.com/show_bug.cgi?id=1135793 https://bugs.archlinux.org/task/40637 I'd be happy to submit a patch or test one. Thoughts?
> A Toshiba CB35 Chromebook running Google's stock SeaBIOS reboots after > selecting a relocatable kernel from extlinux 6.03. > > This is a regression caused by commit 8f470e7b > movebits: Add syslinux_memmap_find() > > which factors syslinux_memmap_find() out of bios_boot_linux(). Prior to > the refactoring, prot_mode_size was passed as the length in the first call > to syslinux_memmap_type(). After the refactoring, hdr.init_size was > passed. Now, with commit ef81a3ad, one or the other is passed according to > whether the kernel is relocatable. > > bios_boot_linux() reaches syslinux_shuffle_boot_rm(), rebooting if the > kernel is relocatable and successfully starting the kernel if not. > > If I modify syslinux_memmap_find() to pass prot_mode_size as the length to > syslinux_memmap_type(), extlinux 6.03 is able to start both types of > kernel. > > Possibly related to > https://bugzilla.redhat.com/show_bug.cgi?id=1135793 > https://bugs.archlinux.org/task/40637 > > I'd be happy to submit a patch or test one. Thoughts? >Although I lack the necessary knowledge to comment about the patch... In this Syslinux Mailing List, we have seen some issues with {non,}relocatable kernels and syslinux.efi. In short, syslinux.efi 6.03 seems to be requiring kernels built with "perfect" config settings matching those for EFISTUB, and seems to be lacking support for some "fallback" method. This seems to affect also kernels before v3.3. This should be / needs to be corrected/implemented. But if we are talking about Chromebooks with SeaBIOS, are we talking about booting kernels in CSM mode? Or in UEFI mode? Other than Chromebooks with (stock) SeaBIOS, is this new reported behavior also seen under other cases / hardware / firmware / kernels (versions)? TIA, Ady> _______________________________________________ > Syslinux mailing list > Submissions to Syslinux at zytor.com > Unsubscribe or set options at: > http://www.zytor.com/mailman/listinfo/syslinux >
Scot Doyle
2015-Feb-06 15:58 UTC
[syslinux] regression: relocatable kernels on a chromebook
On Fri, 6 Feb 2015, Ady wrote:> ... > But if we are talking about Chromebooks with SeaBIOS, are we talking > about booting kernels in CSM mode? Or in UEFI mode? > > Other than Chromebooks with (stock) SeaBIOS, is this new reported > behavior also seen under other cases / hardware / firmware / kernels > (versions)?Hi Ady, With a clone of the git repo on kernel.org I run make spotless bios; make bios ./bios/extlinux/extlinux -i {target mounted partition} The extlinux partition contains both kernels, ldlinux.sys, ldlinux.c32 and extlinux.conf, which is PROMPT 1 LABEL 1 LINUX {relocatable vmlinuz} APPEND root={target partition} LABEL 2 LINUX {nonrelocatable vmlinuz} APPEND root={target partition} I've heard that the SeaBIOS on these machines may report an incorrect amount of memory, requiring (at least older versions of) syslinux to use/pass "mem=1500m" or some such on the APPEND line for some linux iso installers. As shown above, this does not affect the regression test, but that's not to say any incorrect report from the SeaBIOS is not involved. Also, I don't know if other hardware is affected. Thanks, Scot