uefiseven icon indicating copy to clipboard operation
uefiseven copied to clipboard

"Unable to unlock VGA ROM memory at C0000" error upon booting installation media & installed Windows 7 OS

Open SamJoex opened this issue 4 years ago • 4 comments

I am using a Dell G3 3500, and have done the procedure of Steps 2 & 3 (for the installation media) and Steps 7 & 8 (for a transported Windows 7 installation from another computer). The installation media freezes at the Starting Windows screen, and the installed OS briefly freezes with a red line on top but restarts the computer. This error message appears before the boot screen (F8 variant - the one that disappears quickly omits the last two paragraphs):

Unable to find a way to unlock memory at C0000. Proceeding without unlocking... Unable to unlock VGA ROM memory at C0000, aborting F8 keypress detected, switching to text mode Press Enter to continue and then immediately press F8 again

iirc this error also occurred in QEMU. I looked in the previous Issues articles and some others appear to be having the same problem with different models.

SamJoex avatar Jul 31 '21 18:07 SamJoex

Posting again to say that one of the messages still appears in version 1.30.

Unable to unlock VGA ROM memory at C0000, aborting

SamJoex avatar Nov 20 '21 07:11 SamJoex

Posting again to say that one of the messages still appears in version 1.30.

Unable to unlock VGA ROM memory at C0000, aborting

The reason why Vga/Shim/UefiSeven gave me the C0000 error was because the segment was occupied when I used FlashBoot to boot on real UEFI Class 3 hardware because It is designed to lock the C0000 Int10h segment and mistakenly persists after restart. NOTE: Use this advice only if you use VgaShim/UefiSeven and want to clear the C0000 segment so VgaShim/UefiSeven can use it again. If you don't use VgaShim/UefiSeven, skip these steps and use FlashBoot instead.

To make VgaShim/UefiSeven work again on pure UEFI Class 3 (without the C0000 error), I had to refresh the C0000 segment. This advice is only for UEFI Class 3 VgaShim/UefiSeven users' hardware to empty the hex memory C0000 segment (don't do this on UEFI Class 2 Hardware with CSM enabled, it will erase the Int10h VESA Video handler).

  1. To check the C0000 segment on the UEFI computer, do the following on UEFI shell (if there's content, it means that an Int10h emulator (either CSM Int10h Legacy ROM or temporary OVMF Int10h fakevesa) was used on the computer and the pc didn't clean it up the fakevesa on pure-efi pc): mem C0000 or use SLIC ToolKit > Memory Address tab, set memory address hex to C0000, and memory address length to 20000 on running Windows pc to see the C0000 segment. On UEFI class 3, the hex C0000 segment would be usually empty (Int10h is absent or was tampered with code from another fakevesa emulator if GOP also exists).
  2. To confirm that CSM is truly disabled and to check the existence of GOP, do the following command on the UEFI shell: drivers If it mentions in the video driver's name "GOP" while C0000 is empty then you have pure EFI without fakevesa. If GOP is present and fake Int10h is present (mentions "VESA" on hex after scrolling all the way), then you have pure EFI with fakevesa which persisted after being previously tampered by OVMF VGA emulators like VgaShim/UefiSeven/FlashBoot, which is why you can't lock C0000 if the values aren't 00 after shutdown (fakevesa is only supposed to work on memory and reset and reapply every restart, if the tampered code C0000 persists, it tells you that you can't unlock the code between memory address C0000 and DFFF0 (total length of UefiSeven). On a virtual machine, instead of GOP, you would get something like "VirtualBox VGA", "VirtualBox SVGA", and "Vmware SVGA", meaning that it's not pure EFI. If Int10h handler is present while GOP is non-existent, then you are running UEFI Class 2 with Legacy CSM enabled (the default setting for a GOP-Incompatible VGA graphics card connected to an EFI computer).
  3. On UEFI class 3, to clean up C0000-DFFF0, do the following on UEFI Shell (or another memory address hex editor) but this is just for UefiSeven: hexedit -m C0000 20000 Set all values to 00. A real UEFI class 3 hardware (or pure EFI with CSM disabled) will have GOP present and C0000 empty, meaning that will be fresh and work without problems. Sorry for providing a lot of information, but I just wanted to give some helpful advice.

UsefulVideos avatar Apr 16 '22 19:04 UsefulVideos