1. Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

Problem flashing original BIOS

Discussion in 'AMD / ATI' started by Ty_Bower, Apr 1, 2017.

  1. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    I have a pair of Powerrcolor Red Devil RX470 cards. They are not identical - one has Samsung memory, the other is Hynix. I made backups of the original BIOS from each, using both GPU-Z and AtiWinFlash. I have the originals carefully named and saved in a safe location.

    I used Polaris Bios Editor to modify the memory timings on each, trying to get a little more ETH mining hashrate from them. It seemed to work, but the rate gain isn't really worth it. I'm "stuck" on Radeon Crimson 16.11.5, since the driver signature check built into later Radeon drivers prevents them from loading.

    I'd like to go back and restore my original BIOS, but it doesn't seem possible. I've used AtiWinFlash to put the .rom file back in, being careful to keep the correct version (Samsung/Hynix) with each card. However, if I extract the BIOS a second time immediately after flashing in the original, it doesn't match during a binary file compare!

    C:\Util\AWF>fc /b before.rom after.rom
    Comparing files before.rom and after.rom
    00000021: B2 B4
    00000267: D2 D0

    In other words, the BIOS that I just flashed moments ago does not match itself. The file that I flash into the card doesn't match what I read right back out.

    I still can't get the current Radeon releases to recognize these cards as having official, signed BIOSes. Any hints as to what I'm doing wrong?
     
  2. Derek12

    Joined:
    Jan 12, 2010
    Messages:
    1,471 (0.54/day)
    Thanks Received:
    301
    Location:
    Spain
  3. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    Yes, ATIflash 2.74 is what I'm using.

    I would try to follow the guide and flash from a "pure DOS environment" (i.e., create a DOS boot on USB using Rufus or similar), but I understand that ATIflash 4.17 doesn't support Polaris, and ATIflash 2.74 only runs under Windows.
     
  4. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    So, the value at offset 0x0021 is apparently the BIOS checksum value. Does anyone know the purpose of the value stored at offset 0x0267? Apparently, that's changing when ATIflash flashes the BIOS. I'm tempted to use a hex editor, modify that value by 0x02 in the other direction, and try flashing again to see what happens. It looks like a piece of binary shortly after the "AMD ATOMBIOS" in the file. Maybe some kind of version number or something?

    BIOS.png
     
  5. gupsterg

    gupsterg

    Joined:
    Jan 17, 2015
    Messages:
    225 (0.25/day)
    Thanks Received:
    189
    Location:
    Lurking over a keyboard ...
    Do not worry about that change. Flashing does this change.

    I have seen this on Fiji and Polaris also has this "quirk", see this post and reply by The Stilt. The "area" is a little larger that can change than highlighted in my linked post.

    Now if you say flash original ROM, then save from card and flash the saved ROM there will be no change from what I have seen in my testing.
     
    Ty_Bower says thanks.
  6. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    Yes, this is exactly what I observe.

    1) I save the original, factory ROM from a brand new, out of the box card.
    2) I modify the ROM, and flash. The modified ROM performs as expected.
    3) I attempt to restore the original ROM, but this "quirk" results in a few bytes getting altered.
    4) The latest "BIOS signature check enabled" drivers do not work.

    I'm OK with the first three items in my list, but number four is what bothers me. Should the latest Crimson drivers be loading on my card? Or once I flash the card, it is permanently and irreparably changed, the factory BIOS signature is gone, and the sig-check drivers will never run again?
     
  7. gupsterg

    gupsterg

    Joined:
    Jan 17, 2015
    Messages:
    225 (0.25/day)
    Thanks Received:
    189
    Location:
    Lurking over a keyboard ...
    Number 4 is concerning. The latest drivers should work.

    I own Fiji and done roms for members on OCN. Fiji has signature, but drivers do not check. But when CSM: Disabled the signature in ROM is not correct will not work.

    So besides testing drivers working I would see if when you have flashed stock ROM do you get video output with CSM: Disabled, also see if Secure Boot on/off makes difference.
     
  8. W1zzard

    W1zzard Administrator Staff Member

    Joined:
    May 14, 2004
    Messages:
    16,644 (3.47/day)
    Thanks Received:
    17,226
    I vaguely remember there being some kind of checksum after the AMD ATOMBIOS string.

    Try flashing your card with zero-filled rom first (do not reboot) and then flash the original rom, maybe the flasher preserves some bytes
     
    10 Year Member at TPU
  9. gupsterg

    gupsterg

    Joined:
    Jan 17, 2015
    Messages:
    225 (0.25/day)
    Thanks Received:
    189
    Location:
    Lurking over a keyboard ...
    @Ty_Bower

    [​IMG]

    You can use the -ai command switch within shortcut property for AtiWinFlash or use the command line version of AtiWinFlash in DOS prompt in windows, (ie atiflash.exe within zip of AtiWinFlash v2.74).

    Code:
    Format: ATIFLASH [command] [parameter1] [parameter2] [parameter3] <option/s>
    [command]:
    -i [Num]               Display information of ATI adapters in the system.
                           Display information of adapter [Num] if specified.
    -ai [Num]              Display advanced information of ATI adapters on system.
                           Display advanced information of adapter [Num]
    I believe the header on Polaris is a little longer than Fiji, so we are seeing the offset location difference but doing -ai command will confirm it for us IMO.
     
  10. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    I'm not quite certain I understand what CSM disabled/enabled means, but I'll go learn. I'm guessing it's some sort of motherboard BIOS option, possibly related to UEFI?

    Here's the output of my atiflash -ai. Unfortunately, I do not have a copy of this output prior to any BIOS flash activities. I would have liked to have known if the "Binary BIOS_IDTF" has changed.

    C:\Util\AWF>AtiFlash.exe -ai

    Adapter 0 (BN=01, DN=00, FN=00, PCIID=00001002, SSID=00002373)
    Asic Family : Polaris10
    Flash Type : GD25Q21B (256 KB)
    Product Name is : D00003 Polaris10 PRO A1 GDDR5 128Mx32 4GB I2930OAZ.SJC 2016
    Bios Config File: I2930OAZ.SJC
    Bios P/N is : 113-D0000301_101
    Bios Version : 015.050.000.000.000000
    Bios Date is : 09/30/16 00:08

    Image 1 -- Offset 0x0
    =======================
    ROM header contents:
    Signature 0xAA55
    PCIR offset 0x0240
    PCI Data Structure
    Signature PCIR
    Vendor ID 0x1002
    Device ID 0x67DF
    PCI Revision 0x00
    Image size 0xE800
    Code revision 0x0F32
    Indicator 0x00 (Not last image)
    Code type 0x00 (PCAT Image)
    Legacy BIOS File Name I2930OAZ.SJC
    Legacy BIOS Part Number 113-D0000301_101
    Legacy BIOS Build Number 360402
    Legacy BIOS Change List 1320963
    Binary BIOS_IDTF 0x94FECE80
    ByteCheckSum 0

    Image 2 -- Offset 0xE800
    =======================
    ROM header contents:
    Signature 0xAA55
    PCIR offset 0x001C
    PCI Data Structure
    Signature PCIR
    Vendor ID 0x1002
    Device ID 0x67DF
    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: 0xE858)
    Uefi Ids from EFI_PCI_EXPANSION_ROM_HEADER:
    UefiSourceRevision GOP AMD REV: x.x.x.x.x
    UefiSourceChangeList xxxx
    UefiBiosBuildNumber xxxx

    Dump Gop Driver Info:
    Machine type code X64
    The GOP Driver appears to be Authenticode signed.
    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
    GOP BIOS_IDTF 0xDEADBEEF
    GOP Driver does not carry tables!

    Adapter 1 (BN=02, DN=00, FN=00, PCIID=00001002, SSID=00002373)
    Asic Family : Polaris10
    Flash Type : GD25Q21B (256 KB)
    Product Name is : D00003 Polaris10 PRO A1 GDDR5 128Mx32 4GB I2930OAJ.HJC 2016
    Bios Config File: I2930OAJ.HJC
    Bios P/N is : 113-D0000301_101
    Bios Version : 015.050.000.000.000000
    Bios Date is : 09/29/16 23:43

    Image 1 -- Offset 0x0
    =======================
    ROM header contents:
    Signature 0xAA55
    PCIR offset 0x0240
    PCI Data Structure
    Signature PCIR
    Vendor ID 0x1002
    Device ID 0x67DF
    PCI Revision 0x00
    Image size 0xE800
    Code revision 0x0F32
    Indicator 0x00 (Not last image)
    Code type 0x00 (PCAT Image)
    Legacy BIOS File Name I2930OAJ.HJC
    Legacy BIOS Part Number 113-D0000301_101
    Legacy BIOS Build Number 360391
    Legacy BIOS Change List 1320944
    Binary BIOS_IDTF 0x215CA8F9
    ByteCheckSum 0

    Image 2 -- Offset 0xE800
    =======================
    ROM header contents:
    Signature 0xAA55
    PCIR offset 0x001C
    PCI Data Structure
    Signature PCIR
    Vendor ID 0x1002
    Device ID 0x67DF
    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: 0xE858)
    Uefi Ids from EFI_PCI_EXPANSION_ROM_HEADER:
    UefiSourceRevision GOP AMD REV: x.x.x.x.x
    UefiSourceChangeList xxxx
    UefiBiosBuildNumber xxxx

    Dump Gop Driver Info:
    Machine type code X64
    The GOP Driver appears to be Authenticode signed.
    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
    GOP BIOS_IDTF 0xDEADBEEF
    GOP Driver does not carry tables!
     
  11. Ty_Bower New Member

    Joined:
    Feb 26, 2017
    Messages:
    6 (0.05/day)
    Thanks Received:
    0
    Ok, I just installed 17.4.2. It's working fine now. I'm not sure what has changed. I did run the "amdcleanuputility.exe" (which I got from the AMD website) after uninstalling driver version 16.11.5.

    Maybe I can chalk this whole thing up to user error?
     
  12. gupsterg

    gupsterg

    Joined:
    Jan 17, 2015
    Messages:
    225 (0.25/day)
    Thanks Received:
    189
    Location:
    Lurking over a keyboard ...
    @Ty_Bower

    To make validation that it Binary BIOS_IDTF changing, we need comparison of Binary BIOS_IDTF shown in information gained with atiflash -ai, with ROM dumped from card at that time.

    I envisage from v17.4.2 working it is Binary BIOS_IDTF changing which is irrelevant from what I have seen in my testing and from what The Stilt stated (Pro Overclocker/AMD Guru).

    The issue you may have had between drivers not working may have just been an "issue" of installation / OS quirk which you have resolved :) .

    Yes, CSM: Disabled / Enabled is via motherboard UEFI. I would suggest disregard my request to test that now, there is no point IMO. Your successful use of v17.4.2 to me is indicative you do not have a "signature" issue within rom or from flashing rom. I believe still that driver version checks "signature" in rom to know if bios modification has been done. A search on the web should get you that information.
     

Currently Active Users Viewing This Thread: 2 (0 members and 2 guests)