From 237bb9d0be75978a773a084fe739df261742b913 Mon Sep 17 00:00:00 2001 From: klu2 Date: Mon, 2 Mar 2009 15:03:37 +0000 Subject: Fix bug of wrong stack16 stack for thunk call. This may cause Duet failed to enter graphic mode under Qemu simulator or some platforms. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7771 6f19259b-4bc3-4df7-8a09-765794883524 --- DuetPkg/BiosVideoThunkDxe/BiosVideo.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'DuetPkg/BiosVideoThunkDxe/BiosVideo.c') diff --git a/DuetPkg/BiosVideoThunkDxe/BiosVideo.c b/DuetPkg/BiosVideoThunkDxe/BiosVideo.c index 6a8e55a034..7053a0002c 100644 --- a/DuetPkg/BiosVideoThunkDxe/BiosVideo.c +++ b/DuetPkg/BiosVideoThunkDxe/BiosVideo.c @@ -1043,6 +1043,7 @@ BiosVideoCheckForVbe ( VESA_BIOS_EXTENSIONS_VALID_EDID_TIMING ValidEdidTiming; EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE *GraphicsOutputMode; + DEBUG ((EFI_D_INFO, "Enter BiosVideoCheckForVbe()\n")); // // Allocate buffer under 1MB for VBE data structures // @@ -1095,26 +1096,33 @@ BiosVideoCheckForVbe ( Regs.X.ES = EFI_SEGMENT ((UINTN) BiosVideoPrivate->VbeInformationBlock); Regs.X.DI = EFI_OFFSET ((UINTN) BiosVideoPrivate->VbeInformationBlock); + DEBUG ((EFI_D_INFO, "Before VESA!\n")); LegacyBiosInt86 (BiosVideoPrivate, 0x10, &Regs); - + DEBUG ((EFI_D_INFO, "Call VESA! Return Status=0x%X\n", Regs.X.AX)); + DEBUG ((EFI_D_INFO, "Call VESA! VESA Signature =0x%X\n", BiosVideoPrivate->VbeInformationBlock->VESASignature)); + DEBUG ((EFI_D_INFO, "Call VESA! VESA Version =0x%X\n", BiosVideoPrivate->VbeInformationBlock->VESAVersion)); + Status = EFI_DEVICE_ERROR; // // See if the VESA call succeeded // if (Regs.X.AX != VESA_BIOS_EXTENSIONS_STATUS_SUCCESS) { + DEBUG ((EFI_D_INFO, "Fail to call VESA! Status=0x%X\n", Regs.X.AX)); return Status; } // // Check for 'VESA' signature // if (BiosVideoPrivate->VbeInformationBlock->VESASignature != VESA_BIOS_EXTENSIONS_VESA_SIGNATURE) { + DEBUG ((EFI_D_INFO, "Fail to check VESA signature!\n")); return Status; } // // Check to see if this is VBE 2.0 or higher // if (BiosVideoPrivate->VbeInformationBlock->VESAVersion < VESA_BIOS_EXTENSIONS_VERSION_2_0) { + DEBUG ((EFI_D_INFO, "VBE version is little than 2.0!\n")); return Status; } -- cgit v1.2.3