[syslinux] [PATCH] efi: leaving long mode in kernel_jump routine

Patrick Masotta masottaus at yahoo.com
Mon Aug 24 07:27:30 PDT 2015


 > On Tue, Aug 4, 2015 at 2:55 AM, Thomas Letan via Syslinux <syslinux at zytor.com> wrote:
 > Syslinux 6.03 (efi64) fails to boot a 32-bit kernel. The way Syslinux
 > leaves long mode in kernel_jump assembly routine does not follow AMD64
 > specifications. More precisely:
 > 1. After setting a new GADT, `cs` has to be refresh by doing a long
 > jump, but it is not
 > 2. Other segments have to be updated, but they are not
 > 3. Disabling paging has to be done before disabling long mode, but the
 > implementation does the opposite
 >
 > In most cases, a computer that tries to execute the kernel_jump routine
 > reboot (it can also hangs). This patch fixes the kernel_jump routine.
 >
 > Signed-off-by: Thomas Letan <thomas.letan at ssi.gouv.fr>
 > ---
 >  efi/x86_64/linux.S | 61
 >
 ++++++++++++++++++++++++++++++++++++------------------
 >  1 file changed, 41 insertions(+), 20 deletions(-)
 >
 
I can just confirm this patch:
1) it is needed.
2) it solves the problem.
3) so far not regression detected.

Test:
Client Hardware: HP 2570P 
Boot Mode:        PXE EFI64
Target OS:         ubuntu-15.04-desktop-i386.iso

Trying to PXE boot "ubuntu-15.04-desktop-i386.iso" on an EFI64
platform quietly aborts after transferring initrd.lz.
After applying the present patch "ubuntu-15.04-desktop-i386.iso" 
booted normally. The normal booting of AMD64 based OSs looks 
unaffected by the patch.

Best,
Patrick





More information about the Syslinux mailing list