Bug 102497 - Fatal error during GPU init when using an aarch64 board
Summary: Fatal error during GPU init when using an aarch64 board
Status: NEW
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Radeon (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-08-31 20:03 UTC by Bernhard Rosenkraenzer
Modified: 2018-08-02 17:59 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernhard Rosenkraenzer 2017-08-31 20:03:36 UTC
Putting a Radeon graphics card into the PCI slot of an Aarch64 board (the particular one I tried is the Solidrun MACCHIATObin) results in:

[Wed Jul 12 14:01:10 2017] [drm] Initialized drm 1.1.0 20060810
[Wed Jul 12 14:01:10 2017] [drm] radeon kernel modesetting enabled.
[Wed Jul 12 14:01:10 2017] [drm] initializing kernel modesetting (RV620 0x1002:0x95C5 0x174B:0xE400).
[Wed Jul 12 14:01:10 2017] [drm] register mmio base: 0xF6120000
[Wed Jul 12 14:01:10 2017] [drm] register mmio size: 65536
[Wed Jul 12 14:01:10 2017] ATOM BIOS: 
[Wed Jul 12 14:01:10 2017] [drm] GPU not posted. posting now...
[Wed Jul 12 14:01:10 2017] radeon 0000:01:00.0: VRAM: 512M 0x0000000000000000 - 0x000000001FFFFFFF (512M used)
[Wed Jul 12 14:01:10 2017] radeon 0000:01:00.0: GTT: 512M 0x0000000020000000 - 0x000000003FFFFFFF
[Wed Jul 12 14:01:10 2017] [drm] Detected VRAM RAM=512M, BAR=0M
[Wed Jul 12 14:01:10 2017] [drm] RAM width 64bits DDR
[Wed Jul 12 14:01:10 2017] [TTM] Zone  kernel: Available graphics memory: 1889730 kiB
[Wed Jul 12 14:01:10 2017] [TTM] Initializing pool allocator
[Wed Jul 12 14:01:10 2017] [TTM] Initializing DMA pool allocator
[Wed Jul 12 14:01:10 2017] radeon 0000:01:00.0: Fatal error during GPU init
[Wed Jul 12 14:01:10 2017] [drm] radeon: finishing device.
[Wed Jul 12 14:01:10 2017] [TTM] Trying to take down uninitialized memory manager type 1
[Wed Jul 12 14:01:10 2017] [TTM] Finalizing pool allocator
[Wed Jul 12 14:01:10 2017] [TTM] Finalizing DMA pool allocator
[Wed Jul 12 14:01:10 2017] [TTM] Zone  kernel: Used memory at exit: 0 kiB
[Wed Jul 12 14:01:10 2017] [drm] radeon: ttm finalized
[Wed Jul 12 14:01:10 2017] radeon: probe of 0000:01:00.0 failed with error -12

I've tried 3 different radeon cards:

01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] RV620 LE [Radeon HD 3450]

01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] RV710/M92 [Mobility Radeon HD 4530/4570/545v]

01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] RV530LE [Radeon X1600/X1650 PRO]

All behave the exact same.

I presume the problem is caused by the (lack of) BIOS on aarch64 boards not initializing the GPU the same way an x86 box does.

This is on kernel 4.4.52 (latest kernel supported by the board; could try pulling DRI patches from newer kernels if there's any hope of changes being there already), libdrm 2.4.82
Comment 1 Alex Deucher 2017-08-31 20:10:29 UTC
(In reply to Bernhard Rosenkraenzer from comment #0)

> 
> I presume the problem is caused by the (lack of) BIOS on aarch64 boards not
> initializing the GPU the same way an x86 box does.
> 

No, the driver is able to init the card regardless of whether the vbios has been posted or not.

> This is on kernel 4.4.52 (latest kernel supported by the board; could try
> pulling DRI patches from newer kernels if there's any hope of changes being
> there already), libdrm 2.4.82

Here's the problem:

> [Wed Jul 12 14:01:10 2017] [drm] Detected VRAM RAM=512M, BAR=0M

There is no PCI BAR for frame buffer access. I'm guessing your pcie bridge does not have a large enough aperture for the frame buffer BAR.  It's generally 256MB.

The driver can't work without access to vram.

Please attach your full dmesg output.
Comment 2 Mikulas Patocka 2018-08-02 17:59:48 UTC
U-BOOT initializes the PCIe controller with 16MB window - it's too small for GPUs. You have to compile the EDK EFI firmware. You don't have to flash it, you can copy flash-image.bin to sdcard starting at sector 4096 and use the switches on the board to select boot from sdcard.

I've got GPU working this way, but opengl doesn't work because of glitches when writing to the framebuffer.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.