The Notebook Review forums were hosted by TechTarget, who shut down them down on January 31, 2022. This static read-only archive was pulled by NBR forum users between January 20 and January 31, 2022, in an effort to make sure that the valuable technical information that had been posted on the forums is preserved. For current discussions, many NBR forum users moved over to NotebookTalk.net after the shutdown.
Problems? See this thread at archive.org.

    t420 nvs4200 rom dump

    Discussion in 'Lenovo' started by verynice, Nov 7, 2017.

  1. verynice

    verynice Newbie

    Reputations:
    0
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    5
    Hello everyone.
    Can anyone be of help and provide a working nvs bios dump (from a vendor bios not the coreboot one) using two of those methods.
    If it's not possible to put it on forum, please email it [email protected]
    Thank you.

    Retrieval via Linux kernel
    Some Linux drivers (e.g. radeon for AMD) make option ROMs like the video blob available to user space via sysfs. To use that to get the blob you need to enable it first. To that end you need to determine the path within /sys corresponding to your graphics chip. It looks like this: /sys/devices/pci<domain>:<bus>/<domain>:<bus>:<slot>.<function>/rom.

    You can get the respective information with lspci, for example:

    # lspci -tv
    -[0000:00]-+-00.0 Advanced Micro Devices, Inc. [AMD] Family 16h Processor Root Complex
    +-01.0 Advanced Micro Devices, Inc. [AMD/ATI] Kabini [Radeon HD 8210]
    ...

    Here the the needed bits (for the ROM of the Kabini device) are:

    • PCI domain: (almost always) 0000
    • PCI bus: (also very commonly) 00
    • PCI slot: 01 (logical slot; different from any physical slots)
    • PCI function: 0 (a PCI device might have multiple functions... shouldn't matter here)
    To enable reading of the ROM you need to write 1 to the respective file, e.g.:

    echo 1 > /sys/devices/pci0000:00/0000:00:01.0/rom

    The same file should then contain the video blob and it should be possible to simply copy it, e.g.:

    cp /sys/devices/pci0000:00/0000:00:01.0/rom vgabios.bin

    romheaders should print reasonable output for this file.


    Extraction from mapped memory (if everything else fails)
    However you might be able to retrieve your on-board video BIOS with Linux as well.

    • Boot up a machine with a commercial BIOS (not coreboot) with the video card you wish to work under coreboot.
    • You can see where and how much your card's bios is using by doing a
    grep 'Video ROM' /proc/iomem
    • From the command line enter:
      dd if=/dev/mem of=vgabios.bin bs=1k count=64 skip=768
      This assumes you card's BIOS is cached at 0xc0000, and is 64K long.

    dd if=/dev/mem of=video.bios.bin.4 bs=65536 count=1 skip=12
     
    Last edited: Nov 7, 2017
  2. Khenglish

    Khenglish Notebook Deity

    Reputations:
    799
    Messages:
    1,127
    Likes Received:
    979
    Trophy Points:
    131
    I can get you an NVS 5200 dump with a 64-bit GDDR5 memory interface. It's the same GF108 core as the 4200 but half isn't disabled. The device ID will need to be modded but it should otherwise be fine assuming the memory interfaces match.
     
  3. verynice

    verynice Newbie

    Reputations:
    0
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    5
    I tried the dump from t520 nvs4200 with no luck. And I need the in-memory rom, as it looks like that the rom is modified on load.
     
  4. verynice

    verynice Newbie

    Reputations:
    0
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    5
    On a second thought, send it. from those two dumps and one from the EFI tables.
    I'll try all of them.
    Here you can take a look on how to extract one coreboot[dot]org/VGA_support
     
    Last edited: Nov 7, 2017
  5. Khenglish

    Khenglish Notebook Deity

    Reputations:
    799
    Messages:
    1,127
    Likes Received:
    979
    Trophy Points:
    131
    What do you mean by in-memory? Do you mean how it's loaded into the system memory, or how it is flashed on the BIOS chip? I can only get you the raw flash.
     
  6. verynice

    verynice Newbie

    Reputations:
    0
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    5
    You can send me the raw one I'll test will it make my video better or not. But in the main post there is a statement what type of vbios I need and where should it be extracted from.