You are not logged in.

#1 2018-06-08 00:01:55

pacorrop
Member
Registered: 2010-02-05
Posts: 14

[SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

EDIT because the title has been set to [SOLVED] and there's no room to add "[SOLVED]". This was the original title: Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U - PCI issue?
Hi there,
I've bought a Dell Inspiron 5575 (I created that wiki page) and I'm trying to get Arch working on it. The main problem I'm having is that the screen will freeze at boot. It hangs at udev Kernel Manager stage, and dmesg shows this as the most involved part:

 [drm] VCN decode is enabled in VM mode
 [drm] VCN encode is enabled in VM mode
 [drm] BIOS signature incorrect 0 0
 resource sanity check: requesting [mem 0x000c0000-0x000dffff], which spans more than PCI Bus 0000:00 [mem 0x000c0000-0x000c3fff window]
 caller pci_map_rom+0xc7/0x1d0 mapping multiple BARs
 [drm] BIOS signature incorrect 0 0
 [drm:amdgpu_get_bios.cold.2 [amdgpu]] *ERROR* Unable to locate a BIOS ROM
 amdgpu 0000:03:00.0: Fatal error during GPU init
 [drm] amdgpu: finishing device.
 amdgpu: probe of 0000:03:00.0 failed with error -22

However, as stated in the wiki page for that laptop it is possible to ssh or locally blind login, since everything else is not affected by this amdgpu issue. After several times removing and insmod'ing the amdgpu driver, the screen comes back. The dmesg part is changed to the following:

 [drm] VCN decode is enabled in VM mode
 [drm] VCN encode is enabled in VM mode
 [drm] BIOS signature incorrect 0 0
 resource sanity check: requesting [mem 0x000c0000-0x000dffff], which spans more than PCI Bus 0000:00 [mem 0x000c0000-0x000c3fff window]
 caller pci_map_rom+0xc7/0x1d0 mapping multiple BARs
 ATOM BIOS: 113-RAVEN-102
 [drm] vm size is 262144 GB, 4 levels, block size is 9-bit, fragment size is 9-bit
 amdgpu 0000:03:00.0: VRAM: 256M 0x000000F400000000 - 0x000000F40FFFFFFF (256M used)
 amdgpu 0000:03:00.0: GTT: 1024M 0x000000F500000000 - 0x000000F53FFFFFFF
 [drm] Detected VRAM RAM=256M, BAR=256M
 [drm] RAM width 128bits DDR4
 [TTM] Zone  kernel: Available graphics memory: 3933674 kiB
 [TTM] Zone   dma32: Available graphics memory: 2097152 kiB
 [TTM] Initializing pool allocator
 [TTM] Initializing DMA pool allocator
 [drm] amdgpu: 256M of VRAM memory ready
 [drm] amdgpu: 3072M of GTT memory ready.
 [drm] GART: num cpu pages 262144, num gpu pages 262144
 [drm] PCIE GART of 1024M enabled (table at 0x000000F400800000).

I have the latest BIOS firmware installed from Dell. Before installing it the behaviour was exactly the same.
This issue happens both booting from UEFI or from Legacy Boot.

I've been digging into the linux 4.17 sources, and so far I've deduced the pci_map_rom call from the amdgpu driver returns different contents, depending on some context that I'm not aware of. As anyone can follow when reading the pci_rom_map implementation, it's going to determine the actual ROM size that is present in the device's ioremapped ROM (this case, the graphic card) by checking some sentinel values. However, it turns out that when the driver is not properly loaded, the rom image that is ioremapped will start with 0xffff, whereas the times that the driver is correctly loaded it commences with the correct sentinel  value 0xAA55 (or 0x55AA, not sure).

Hence, my question. I'm not expert at all at PCI devices nor how they are initialized in the boot process, but I presume that the times that the screen freezes is because the BAR for the graphic card's PCIe device is not properly set. Can anyone tell me how or what should I check to get the amdgpu driver properly loaded?

Last edited by pacorrop (2018-06-12 20:41:47)

Offline

#2 2018-06-08 00:20:00

loqs
Member
Registered: 2014-03-06
Posts: 13,173

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

Is your testing and the outputs from 4.17-rc7 or was that just the source you were inspecting?  Does the amdgpu.dc=0 kernel option make any difference?

Offline

#3 2018-06-08 00:22:10

progandy
Member
Registered: 2012-05-17
Posts: 4,225

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

You are digging into the 4.17 source. Are you booting with 4.17 (currently in [testing]) or still with a 4.16.x release?

Last edited by progandy (2018-06-08 00:22:45)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#4 2018-06-08 06:51:49

pacorrop
Member
Registered: 2010-02-05
Posts: 14

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

Thanks for the quick responses. I'm totally out of ideas.

loqs wrote:

Is your testing and the outputs from 4.17-rc7 or was that just the source you were inspecting?  Does the amdgpu.dc=0 kernel option make any difference?

Exactly, I downloaded the linux-mainline from AUR last week for the rc7 and I started messing around (i.e, putting pr_info traces), compiling, rebooting et al.
Regarding the dc option, I recall seeing it around my googling stage (there should be 6 and no 5 stages of Grief and Loss lol), so I probably used it along with some other. I can't remember the outcome, tbh.
I'm going to work now, but I'll test this option in isolation later this evening and post the results here.

progandy wrote:

You are digging into the 4.17 source. Are you booting with 4.17 (currently in [testing]) or still with a 4.16.x release?

Answered above. Using the mainline (4.17rc7) from AUR.

I think now it's a good moment for ask: is there any more... productive way to test and debug the loading of a kernel module? Like using gdb when I'm going to execute

 # modprobe amdgpu

I presume this approach is naive, because the only things I've seen so far googling is by using virtual machines, but afaik this can't be used on real hardware like I'm trying here. I'm aware this is a very newbie question and I apologize for this, but at least I think it's worth to ask big_smile

Last edited by pacorrop (2018-06-08 06:53:20)

Offline

#5 2018-06-08 15:30:14

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 9,016

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

Does it make a difference if you use early KMS ?


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
Did you use the guided installer ? If yes, I can't help you.

(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#6 2018-06-08 16:25:11

pacorrop
Member
Registered: 2010-02-05
Posts: 14

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

loqs wrote:

Is your testing and the outputs from 4.17-rc7 or was that just the source you were inspecting?  Does the amdgpu.dc=0 kernel option make any difference?

No luck, either. This is the dmesg (a bit longer that previous ones to notice the pcieport errors):

[   18.512365] pcieport 0000:00:01.7: AER: Multiple Corrected error received: id=0008
[   18.512377] pcieport 0000:00:01.7: PCIe Bus Error: severity=Corrected, type=Data Link Layer, id=000f(Receiver ID)
[   18.540129] pcieport 0000:00:01.7:   device [1022:15d3] error status/mask=00000040/00006000
[   18.567684] pcieport 0000:00:01.7:    [ 6] Bad TLP               
[   19.530328] [drm] amdgpu kernel modesetting enabled.
[   19.918373] AMD IOMMUv2 driver by Joerg Roedel <jroedel@suse.de>
[   19.993874] kvm: Nested Virtualization enabled
[   19.993879] kvm: Nested Paging enabled
[   19.993880] SVM: Virtual VMLOAD VMSAVE supported
[   19.993881] SVM: Virtual GIF supported
[   20.088719] MCE: In-kernel MCE decoding enabled.
(This message happens a lot of times) [   20.171347] EDAC amd64: Node 0: DRAM ECC disabled.
(This message happens a lot of times) [   20.171350] EDAC amd64: ECC disabled in the BIOS or no ECC capability, module will not load.
                Either enable ECC checking or force module loading by setting 'ecc_enable_override'.
                (Note that use of the override may cause unknown side effects.)
[   20.176984] Parsing CRAT table with 1 nodes
[   20.176989] Ignoring ACPI CRAT on non-APU system
[   20.176992] Virtual CRAT table created for CPU
[   20.176992] Parsing CRAT table with 1 nodes
[   20.176993] Creating topology SYSFS entries
[   20.177014] Topology: Add CPU node
[   20.177014] Finished initializing topology
[   20.177376] kfd kfd: Initialized module
[   20.183422] checking generic (d0000000 7f0000) vs hw (d0000000 10000000)
[   20.183423] fb: switching to amdgpudrmfb from VESA VGA
[   20.183479] Console: switching to colour dummy device 80x25
[   20.183875] [drm] initializing kernel modesetting (RAVEN 0x1002:0x15DD 0x1028:0x0812 0xC4).
[   20.183892] [drm] register mmio base: 0xE0900000
[   20.183893] [drm] register mmio size: 524288
[   20.183905] [drm] probing gen 2 caps for device 1022:15db = 700d03/e
[   20.183907] [drm] probing mlw for device 1022:15db = 700d03
[   20.183911] [drm] add ip block number 0 <soc15_common>
[   20.183912] [drm] add ip block number 1 <gmc_v9_0>
[   20.183913] [drm] add ip block number 2 <vega10_ih>
[   20.183913] [drm] add ip block number 3 <psp>
[   20.183915] [drm] add ip block number 4 <powerplay>
[   20.183916] [drm] add ip block number 5 <gfx_v9_0>
[   20.183917] [drm] add ip block number 6 <sdma_v4_0>
[   20.183918] [drm] add ip block number 7 <vcn_v1_0>
[   20.549502] [drm] VCN decode is enabled in VM mode
[   20.549505] [drm] VCN encode is enabled in VM mode
[   20.581614] [drm] BIOS signature incorrect 0 0
[   20.581686] resource sanity check: requesting [mem 0x000c0000-0x000dffff], which spans more than PCI Bus 0000:00 [mem 0x000c0000-0x000c3fff window]
[   20.581691] caller pci_map_rom+0xc7/0x1d0 mapping multiple BARs
[   20.581705] amdgpu 0000:03:00.0: Invalid PCI ROM header signature: expecting 0xaa55, got 0xffff
[   20.600779] input: DELL0812:00 044E:120A as /devices/platform/AMDI0010:01/i2c-0/i2c-DELL0812:00/0018:044E:120A.0001/input/input14
[   20.600981] hid-generic 0018:044E:120A.0001: input,hidraw0: I2C HID v1.00 Mouse [DELL0812:00 044E:120A] on i2c-DELL0812:00
[   20.615290] [drm] BIOS signature incorrect 0 0
[   20.615370] [drm:amdgpu_get_bios.cold.2 [amdgpu]] *ERROR* Unable to locate a BIOS ROM
[   20.615382] amdgpu 0000:03:00.0: Fatal error during GPU init
[   20.615386] [drm] amdgpu: finishing device.
[   20.615682] amdgpu: probe of 0000:03:00.0 failed with error -22
Lone_Wolf wrote:

Does it make a difference if you use early KMS ?

Hold on, I'm on my way to try. I'll edit this post once I got something.
Edit: Nah, the screen freezes earlier smile and dmesg output is exactly the same as before.
The thing is that I have been testing my own stuff with the linux-mainline package (4.17), and enabling the early KMS is performed on my "pacman installed" linux version (4.16.12). Sigh.

Last edited by pacorrop (2018-06-08 16:39:10)

Offline

#7 2018-06-08 16:42:03

loqs
Member
Registered: 2014-03-06
Posts: 13,173

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

If that fails you could try https://cgit.freedesktop.org/~agd5f/linux/refs/ either the amd-staging-drm-next or drm-next-4.18 branches those contain the latest commits from amd.
If that still fails would do an upstream bug report.
Edit:
grammar missing branches
Disclaimer as that code is so new take the usual data backup precautions.

Last edited by loqs (2018-06-08 16:43:47)

Offline

#8 2018-06-08 18:01:55

pacorrop
Member
Registered: 2010-02-05
Posts: 14

Re: [SOLVED] Amdgpu driver BIOS ROM not found at boot in Ryzen 2500U

Excellent. Thank you, loqs!

If I have news, I'll post them here.

Edit: it turned out that I was half lying in the first post without knowing it. I did not try every boot combination that the laptop BIOS provides. The solution is to turn off the Legacy Boot and boot in UEFI thereafter. Tried with Secure Boot disabled.
Marking solved.

Last edited by pacorrop (2018-06-12 20:42:39)

Offline

Board footer

Powered by FluxBB