How to disable UEFI for legacy only boot on recent AMD Radeon GPUs

Hello,

Recent AMD GPUs have a hybrid ROM which contains two images: A legacy video BIOS (vBIOS) image and a compressed graphics output protocol (GOP) driver image. In theory this allows the card to work well on both legacy systems (which will use the vBIOS image) and more modern systems with a unified extensible firmware interface (UEFI) compatible pre-boot firmware architecture (which use the GOP driver).

However some early UEFI implementations cannot cope with the hybrid BIOS, they try to load the GOP driver and fail, hanging at boot with a blank screen. I have personally experienced this with an AMD RX480 and an Alienware Aurora R3 system (other examples: RX 480 incompatibility thread on reddit, R3 with an RX580, another R3 with an RX480)

It is a particular problem for branded systems with custom motherboards like many systems from HP, Dell, Lenovo etc that no longer receive BIOS updates from the manufacturer and have no options within the BIOS to force legacy mode boot when an EFI module is detected.

Some older video cards have a physical switch on them to swap between legacy and UEFI mode. The RX 480 however has no switch and exposes both the legacy and the GOP images to the pre boot firmware. I found that by modifying the firmware ROM for my GPU to mark the legacy image as the “last” image it would hide the GOP image and render the system bootable.

Here is what I did (cross posted from the AMD and Nvidia GOP update thread):


To perform this fix you will need a system that will boot with the card you plan to modifiy (I had an older legacy BIOS only Q6600 system to hand). I downloaded the firmware of my GPU to a ROM file using atiwinflash (included with the command line too atiflash.exe, which would also work). I then used HxD to edit the ROM and verified that the ROM checksum matched that of the original BIOS with atiflash (atiflash.exe -cf <FILE> on both original and modified bios, or load the modified bios into atiwinflash without programming it to the card).

I programmed the modified BIOS to the GPU using atiflash.

IMPORTANT: If you plan to do this - backup your original BIOS first (make all edits to second copy) and be very careful you are modifying the correct bytes in the ROM, an error could easily brick your GPU.

NOTE: The offsets mentioned in the table I link above are from the start of the PCIR header. The actual location of this header will vary depending on your GPU rom, it won’t start at 0x00. For example, in the ROM of my RX 480 the PCIR header of the legacy VBIOS image starts at offset 0x254 and the last image indicator byte which I modified from 0x00 to 0x80 is at offset 0x269 (0x254 + 0x15):

Capture.PNG



Below is an example showing how I modified ROM of my card at offset 0xE568 in the the padding at the end of the legacy vBIOS image to balance the checksum so it would match the checksum of the original BIOS. You can also see the start of the next image (the GOP UEFI driver) which begins at 0xE600:

Modify padding to balance checksum.PNG


ALSO NOTE: All the offsets and values mentioned above are in hexadecimal Don’t attempt this unless you understand what that means and what a hex editor is.

EDIT: corrected hex range example for legacy image in my ROM.


I tried loading the ROM into Polaris editor (v 1.4) but it complained that the ROM was not 512kb (my card uses 256kb ROMs) and the values loaded made no sense. Polaris editor thought my card vendor id was 0x5249 when that is in fact the last two bytes of the PCIR signature, the other values also looked off (2000 Mhz is not the card’s max frequency!) so I did not risk using it:

Capture.PNG

Capture2.PNG

Capture 3.PNG



Also the method I detailed above resulted in a bios that did not require use of the ati pixel patcher, which for simplicity I would prefer not to have to use.

Like I said in reply to your post about this over on TPU, just delete the UEFI GOP module and be done with it. You seriously overcomplicated things by doing what you did. I’m glad it worked for you. But I wouldn’t suggest anybody else waste their time with it.


I think that should work as well in most cases, though by deleting the GOP driver image without also setting the last image byte in the PCIR header of the vBIOS image you end up with a GPU firmware that doesn’t meet the PCI specification (the last image should be marked as such according to the spec):



I imagine there may be some motherboard firmwares out there that may not like it if no image on the card is marked as last.

Hello, would you please help me with my Asus RX 580 Dual Fan OC? I have an Asus Rampage II Extreme, and it simply won’t boot, because it’s not UEFI.
I would like to know if you could modify my vBios, because i don’t know anything about editing HeX and i don’t want to brick my card.
Thanks in advance,
Sebastian

@drbob ^^ Thanks @sebulis - if you want him to modify your vBIOS for you, and he will do it, you’ll need to dump it via GPU-z and attach the file so he can edit.

Thank you so much!!! My vBios is here http://depositfiles.org/files/spvimtnn9
I will invite both of you a couple of beers!!! :beer::beer:

Edit:
I have attached the bios file to this post. I couldn’t find the option before! Thanks @drbob @Lost_N_BIOS

bios.rom.zip (110 KB)

Hi @sebulis ,

I don’t check this forum very often, sorry for the delay in response. You can try the attached bios. I modified it in the same way I modified my RX480 bios to get it working with an incompatible motherboard (as described in the first post)

Whilst the modification worked for me, you install it at your own risk… It’s also always possible that your Rampage II system has a different issue stopping your card from working (PSU insufficient etc)

Let us know how you get on!

bios_patched.zip (108 KB)

Did this work for the Asus Dual RX 580 OC 8gb card?

@drbob - Just an addition here to the originally considered method, if you edit first image (legacy) indicator to be 80 (Last image), you then shouldn’t you also edit last image (UEFI/EFI) indicator to be 00 (first/other than last etc)?
I assumed you probably did this, but didn’t mention in the above info.

I just did this for someone here, two ways, one using your method (but doing as I mentioned above) and then a second edit blanking out the GOP image (FF) with legacy one set to last
I need help moding vbios

hello, could you do this for my msi armor rx 570 8 gig?

Sorry for the long delay in replying, I don’t read here often!

In answer to your question. I don’t think it matters, the BIOS should treat any other data as junk and ignore it.

AIUI the ROM is read sequentially, the reason the mod works is setting the last image indicator on the VBIOS causes the system to not look for any other ROM images after it has read that first image. So it it’s not necessary to modify anything other than the header on that first VBIOS image.

So… I don’t really know anything about editing the bios and my old X58 mobo (Rampage II Extreme) not giving display even post bios just classic 1 long 4 short beep…

https://yadi.sk/d/a8F1OOBfZ2nKlA here is the my bios. If already shared non ufei bios please leave link thank you so much.

I’ve just modified it for you. This is a temporary link
https://fex.net/s/9n70mmp

i got an RX480 8gb armor OC, just sitting on the shelf for 6 months now, please can anyone mod the bios for me, i know how to flash but im not familiar with Hex, i have attached the bios file, thanks a lot ,in case if the file is corrupt ill provide a link below
https://www.techpowerup.com/vgabios/191088/191088.rom

RX480 GB armor OC.zip (111 KB)

Hi all,

I bought a RX570 to upgrade my girlfriend old computer (a Intel DP55WB motherboard with a very good CPU, and a old crappy video card).
The RX570 doesn’t boot on her computer, but works fine on mine (MSI X370 Gaming with Ryzen 2400g). So I heavily suspect her motherboard is not compatible with some newer UEFI/Legacy vga cards.

As for others, I’d like to edit my bios but it looks quite tricky to do, and I don’t want to brick the card. Here is the RX570 vbios I exported with GPU-Z.
Can you mod it to remove the hybrid UEFI/Legacy bios in order to boot on that old mobo ?

Thanks a lot !!!

Ellesmere.zip (108 KB)

Sorry ı don’t check oftenly… But link is dead…

Mine is working … Ellesmere.zip

This motherboard dont even worked with some gpus (for example r7 260 amd) back then. It need bios update but i cant find in intel site they removed it.


Yep, there is no firmware on intel’s website, but there is no new firmware since several years (5 years or more maybe…). I have the latest one. I also tried to play with the legacy/uefi boot option, but it seems not related, since the BIOS stops at POST (don’t remember the error code, but was related to disk or memory initialisation, nothing plausible, since the video card works well on other computers).
One day I will try that method for disabling UEFI from the bios image, if nobody do it for me…