[syslinux] [PATCH 1/1] mboot.c32: fix register constraints bug

H. Peter Anvin hpa at zytor.com
Wed May 24 09:06:05 PDT 2006

Tim Deegan wrote:
> From: Tim Deegan <Tim.Deegan at cl.cam.ac.uk>
> Fix register constraints of final jump to kernel entry.  
> When compiled with some GCC versions, mboot.c32 would clobber the kernel
> load address and try to jump to 0x2badb002.

A cleaner way to do this would be:

asm volatile("jmp *%1"
              : : "b" (mbi_run_addr),
         	 "a" (0x2badb002),
                  "cdSI" (entry));

... instead of having explicit mov's which could clobber what gcc has 
set up.


More information about the Syslinux mailing list