Is finally my turn to mod the VBIOS of my old Radeon 5770 since I need UEFI GOP, but the reasons why I need it are totally different to everyone which posted in this Thread (Edit: Didn’t noticed that TWO guys in the last page do this, too). I use VGA Passthrough to pass a Video Card to a Virtual Machine, so I can get near-native compatibility and performance for gaming inside a Windows VM. At the moment, I’m using the Xen Hypervisor with a Linux host, but I’m intending to migrate to KVM and re-do my entire setup.
The reason why UEFI GOP is very valuable for the virtualization crowd is because the legacy VGA protocol can’t be simultaneously used by multiple Video Cards, causing issues with Linux VGA Arbitration. Not having UEFI GOP rules out doing Primary VGA Passthrough, which is when the Video Card VBIOS PCI Option ROM is loaded by the VM Firmware (OVMF for UEFI) so it can display the POST stage on the Monitor attached to the passthroughed Video Card. Instead, you have to wait that the OS loads the GPU Drivers, which is called Secondary VGA Passthrough. With UEFI GOP, legacy VGA is not used at all so you should be able to do it with no issues related to it. There are other important issues, like not being able to reboot the VM properly due to not working Function Level Reset causing issues with GPU warm boot, requiring a host reboot if you want to reboot the VM, and some other issues depending on the specific Video Card.
The first problem is that UEFI GOP support was unheard about during the Radeon HD 5xxx generation (Except for Apple cards with their custom EFI), so there was scarse info about getting working UEFI GOP “donors” for older GPUs. Regardless, I recall that some people successfully modded their Radeons 5450 somehow and were able to enjoy Fast Boot, so it was possible in that generation. At some point I hear about the Insanely Mac tool that was mentioned in the first Post and tried it, then I found an issue that didn’t allowed me to try the modded ROM: Junipers have a small 128 KiB Flash ROM, and the modded ROM was around 180 KiB or so, so I couldn’t flash it. After some googling I found more people that failed to add UEFI GOP to other Junipers based cards for the same reason, so it seemed like a lost cause.
Recently, I hear that QEMU allows you to sideload a custom PCI Option ROM and replace the PCI Card provided one. This allows me to workaround the size issue, and even test the ROM without even having to actually flash it! The only thing that remained unknow is if the UEFI GOP mod worked in a Juniper, since no one I was aware of did so previously. Then I found in this Thread that there was another guy with a Radeon 5770 with the ROM size issue, but which was workarounded by using a very specific UEFI GOP Driver version that fitted even with the size constrains, and probabily may work for my card, too. Regardless, I think I’m going to use the QEMU custom ROM approach, since it seems easier. Only thing I don’t know if it can be of an arbitrary size or a power of two one (256 KiB), which may require to inflate it.
I still prefer to ask if there is anything else that I should have to check (The other guy with a Radeon 5770 got it working but not with the standard procedure with the GOPUPD tool), or go straight to test the mod to see if it works. GOPUPD seems to complain about being unable to get some data, and to report it. The next magic trick would be if I could mod the Radeon 5770 to a FirePro V5800, heh.
My Video Card is a Radeon 5770 Sapphire Flex, this one. I don’t have the original VBIOS ROM, but I recall that at some point I dumped the VBIOS with GPU-Z and compared the CRC32 with the one on TechPowerUp VGA BIOS Database, here, and it was the same. Currently, my Radeon 5770 has a BIOS modded by myself with Radeon BIOS Editor, since I wanted lower noise and power consumption, so I edited the PowerPlay Power states to underclock and undervolt it, and modify the Fan ramp curve.
I’m using GOPUPD 1.9.3. This is the data…
Sapphire.HD5770.1024.100519.rom (Original from TechPowerUp)
…drag&drop to #AMD_ROM_Info.bat…
Dumping info from = Sapphire.HD5770.1024.100519.rom
Generate Info for file C:\Users\Mengueche\Desktop\DRIVERS_AMD\UEFIGOP\GOPUPD\Sapphire.HD5770.1024.100519.rom: (OpRom Image)
==========================================
Image 1 – Offset 0x0
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x01D8
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xF800
Code revision 0x0C14
Indicator 0x80 (last image)
Code type 0x00 (PCAT Image)
Legacy BIOS File Name 148X0300.106
Legacy BIOS Part Number 113-148X0300-106
Legacy BIOS Build Number 146060
Legacy BIOS Change List 558952
ByteCheckSum 0
At the end of the RomImage (offset 1a000) there is uCode.
…drag&drop to GOPupd.bat, and accepting upgrading offer…
************************* GOPupd 1.9.3
Update EFI GOP
Drop VBIOS file on this .bat
Dumping info from = Sapphire.HD5770.1024.100519.rom
ID of ROM file = 1002-68B8
No EFI ROM found!
No EFI ROM found or error on decompression !!!
Extracting with GOPupd…
---------------------------------------------------------------
Processing with GOPupd…
GOP is not present!!!
AMD microcode was found at offset 0x1A000!
Do you want to update GOP to latest available? Y for yes or N for no: y
Fixing last-image-bit in PCI Structure of Legacy ROM!
Using AMD byte for checksum!
Fixing ID for EFI image. No checksum correction is needed.
Removing unnecessary end padding.
Data after ROM and not part of EFI! Please report it!
Unable to recover extra data at the same offset 0x1A000! Please report it!
File “Sapphire.HD5770.1024.100519_updGOP.rom” with updated GOP 1.60.0.15.50 was written!
…drag&drop upgraded ROM to #AMD_ROM_Info.bat…
Dumping info from = Sapphire.HD5770.1024.100519_updGOP.rom
Generate Info for file C:\Users\Mengueche\Desktop\DRIVERS_AMD\UEFIGOP\GOPUPD\Sapphire.HD5770.1024.100519_updGOP.rom: (OpRom Image)
==========================================
Image 1 – Offset 0x0
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x01D8
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xF800
Code revision 0x0C14
Indicator 0x00 (Not last image)
Code type 0x00 (PCAT Image)
Legacy BIOS File Name 148X0300.106
Legacy BIOS Part Number 113-148X0300-106
Legacy BIOS Build Number 146060
Legacy BIOS Change List 558952
ByteCheckSum 0
Image 2 – Offset 0xF800
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x001C
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xE800
Code revision 0x0000
Indicator 0x80 (last image)
Code type 0x03 (EFI Image)
EFI Signature 0x0EF1
Compression Type 0x0001 (compressed)
Machine type 0x8664 (X64)
Subsystem 0x000B (EFI boot service driver)
EFI image offset 0x0058 (abs: 0xF858)
Dump Gop Driver Info:
Machine type code X64
Size Of Gop Image 98144 (95 KB)
GOP Driver Name: AMD GOP X64 Release Driver Rev.1.60.0.15.50.Feb 1 2016.14:59:32
GOP AMD_Build 425
GOP AMD_CL 1233155
Now, my current RBE modded VBIOS…
…drag&drop to #AMD_ROM_Info.bat (Notice that all the Legacy BIOS entries are slighty different to original ROM)…
Dumping info from = Juniper.rom
Generate Info for file C:\Users\Mengueche\Desktop\DRIVERS_AMD\UEFIGOP\GOPUPD\Juniper.rom: (OpRom Image)
==========================================
Image 1 – Offset 0x0
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x01D8
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xF800
Code revision 0x0C14
Indicator 0x80 (last image)
Code type 0x00 (PCAT Image)
Legacy BIOS File Name 148X0300.DP3
Legacy BIOS Part Number 113-E14820-X03
Legacy BIOS Build Number 154251
Legacy BIOS Change List 578423
ByteCheckSum 0
At the end of the RomImage (offset 1a000) there is uCode.
…drag&drop to GOPupd.bat, and accepting upgrading offer…
GOPupd 1.9.3
Update EFI GOP
Drop VBIOS file on this .bat
Dumping info from = Juniper.rom
ID of ROM file = 1002-68B8
No EFI ROM found!
No EFI ROM found or error on decompression !!!
Extracting with GOPupd…
---------------------------------------------------------------
Processing with GOPupd…
*************************
GOP is not present!!!
AMD microcode was found at offset 0x1A000!
Do you want to update GOP to latest available? Y for yes or N for no: y
Fixing last-image-bit in PCI Structure of Legacy ROM!
Using AMD byte for checksum!
Fixing ID for EFI image. No checksum correction is needed.
Removing unnecessary end padding.
Data after ROM and not part of EFI! Please report it!
Unable to recover extra data at the same offset 0x1A000! Please report it!
File “Juniper_updGOP.rom” with updated GOP 1.60.0.15.50 was written!
…drag&drop upgraded ROM to
#AMD_ROM_Info.bat…
Dumping info from = Juniper_updGOP.rom
Generate Info for file C:\Users\Mengueche\Desktop\DRIVERS_AMD\UEFIGOP\GOPUPD\Juniper_updGOP.rom: (OpRom Image)
==========================================
Image 1 – Offset 0x0
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x01D8
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xF800
Code revision 0x0C14
Indicator 0x00 (Not last image)
Code type 0x00 (PCAT Image)
Legacy BIOS File Name 148X0300.DP3
Legacy BIOS Part Number 113-E14820-X03
Legacy BIOS Build Number 154251
Legacy BIOS Change List 578423
ByteCheckSum 0
Image 2 – Offset 0xF800
=======================
ROM header contents:
Signature 0xAA55
PCIR offset 0x001C
PCI Data Structure
Signature PCIR
Vendor ID 0x1002
Device ID 0x68B8
PCI Revision 0x00
Image size 0xE800
Code revision 0x0000
Indicator 0x80 (last image)
Code type 0x03 (EFI Image)
EFI Signature 0x0EF1
Compression Type 0x0001 (compressed)
Machine type 0x8664 (X64)
Subsystem 0x000B (EFI boot service driver)
EFI image offset 0x0058 (abs: 0xF858)
Dump Gop Driver Info:
Machine type code X64
Size Of Gop Image 98144 (95 KB)
GOP Driver Name: AMD GOP X64 Release Driver Rev.1.60.0.15.50.Feb 1 2016.14:59:32
GOP AMD_Build 425
GOP AMD_CL 1233155
Besides the obvious thing that would be to test if pure UEFI Boot works, is there anything else that I would have to check? I hear that some people get a half-working mod where the ACPI VFCT Table is missing, Power States may not work properly (Though
I have that issue on warm reboots since lack of FLR), but not sure what else I would need to check.
Juniper.zip (44.9 KB)