From 448509bb4e93b3ffe870f048c6b4a82b1f2cb9a7 Mon Sep 17 00:00:00 2001 From: Mark Marshall Date: Thu, 5 Nov 2009 09:09:20 +0000 Subject: Get the passed in Bus/Device/Function from the correct location on the stack. Signed-off-by: Mark Marshall Clarified the comment and Acked-by: Stefan Reinauer git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4911 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- util/x86emu/x86_asm.S | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/util/x86emu/x86_asm.S b/util/x86emu/x86_asm.S index c41e39dc18..5e2518c695 100644 --- a/util/x86emu/x86_asm.S +++ b/util/x86emu/x86_asm.S @@ -68,8 +68,10 @@ __run_optionrom = RELOCATED(.) /* Get devfn into %ecx */ movl %esp, %ebp - // FIXME: Should this function be called with regparm=0? - movl 8(%ebp), %ecx + /* This function is called with regparm=0 and we have + * to skip the 32 byte from pushal: + */ + movl 36(%ebp), %ecx /* Activate the right segment descriptor real mode. */ ljmp $0x28, $RELOCATED(1f) -- cgit v1.2.3