Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[gentoo-user] anyone tried amdgpu (kernel module)

174 views
Skip to first unread message

Tsukasa Mcp_Reznor

unread,
Dec 18, 2015, 4:10:04 PM12/18/15
to
I have a Bonaire gpu, which has legacy support using the amdgpu kernel module.  I currently use the Radeon dri module with radeonsi mesa drivers and am quite happy.  But gentoo being gentoo I thought I'd give the amdgpu a go for the fun of it.

Tried a few variations and keep coming up with a black screen on boot and it's hard locked.  I'm using the same Firmware includes that the radeon driver requires, and from reading it looks like that's fine with amdgpu, so I'm not sure what else could be the issue.

Has anyone here tried and had success with it?  I've tried Kernels 4.2 4.2.4 4.3 and 4.3.2.  So I believe I'm missing something simple and it's not a kernel bug.

Alexander Kapshuk

unread,
Dec 19, 2015, 2:40:04 AM12/19/15
to
Did you consult the wiki article shown below when configuring your system to use admgpu?

https://wiki.gentoo.org/wiki/Amdgpu

Tsukasa Mcp_Reznor

unread,
Dec 19, 2015, 10:50:04 AM12/19/15
to
From: alexande...@gmail.com
Date: Sat, 19 Dec 2015 09:35:28 +0200
Subject: Re: [gentoo-user] anyone tried amdgpu (kernel module)
To: gento...@lists.gentoo.org

Yes I have.  The CIK parts kernel option is enabled.  the only thing I find a bit odd, is in the firmware include list is radeon/bonaire_sdma1.bin which doesn't exist on my system using sys-kernel/linux-firmware-20150812.  So I'm assuming it's an error on the wiki page.

Alexander Kapshuk

unread,
Dec 19, 2015, 11:20:03 AM12/19/15
to
Have you tried this firmware package instead, sys-firmware/amdgpu-ucode?

Do you have the firmware included in your kernel config file?
Device Drivers  --->
    Generic Driver Options  --->
        -*- Userspace firmware loading support
        [*] Include in-kernel firmware blobs in kernel binary
            (amdgpu/<YOUR-MODEL>.bin radeon/<YOUR-MODEL>.bin)
            (/lib/firmware) Firmware blobs root directory

Tsukasa Mcp_Reznor

unread,
Dec 19, 2015, 11:20:03 AM12/19/15
to



From: alexande...@gmail.com
Date: Sat, 19 Dec 2015 18:13:03 +0200
Yes I have the firmware includes, I'll try the amdgpu-ucode and report back.

Tsukasa Mcp_Reznor

unread,
Dec 19, 2015, 11:50:04 AM12/19/15
to



From: mcp_r...@hotmail.com
To: gento...@lists.gentoo.org
Subject: RE: [gentoo-user] anyone tried amdgpu (kernel module)
Date: Sat, 19 Dec 2015 11:17:40 -0500



-------------

Mission successful!  Thanks everyone, it appears the missing sdma1.bin from linux-firmware is contained in amdgpu-ucode and after switching everything is running fine.


James

unread,
Dec 19, 2015, 12:20:03 PM12/19/15
to
Tsukasa Mcp_Reznor <mcp_reznor <at> hotmail.com> writes:


> I have a Bonaire gpu, which has legacy support using the amdgpu
> kernel module.  


I'd be most curios to know if anyone has any version of the radeon Fury
(Fury X2) that uses the HBM running on Gentoo, regardless of configuration.

Multiple cards in the same system?


James

Alexander Kapshuk

unread,
Dec 19, 2015, 12:20:03 PM12/19/15
to
 
Have you tried this firmware package instead, sys-firmware/amdgpu-ucode?

Do you have the firmware included in your kernel config file?
Device Drivers  --->
    Generic Driver Options  --->
        -*- Userspace firmware loading support
        [*] Include in-kernel firmware blobs in kernel binary
            (amdgpu/<YOUR-MODEL>.bin radeon/<YOUR-MODEL>.bin)
            (/lib/firmware) Firmware blobs root directory


Yes I have the firmware includes, I'll try the amdgpu-ucode and report back.

-------------

Mission successful!  Thanks everyone, it appears the missing sdma1.bin from linux-firmware is contained in amdgpu-ucode and after switching everything is running fine.



Good to hear.

Thanks for letting us know.

Mick

unread,
Dec 20, 2015, 2:10:05 PM12/20/15
to
This is not working for me on a Kaveri system.

The wiki page suggests these firmware blobs:

radeon/kaveri_ce.bin radeon/kaveri_me.bin radeon/kaveri_mec2.bin
radeon/kaveri_mec.bin radeon/kaveri_pfp.bin radeon/kaveri_rlc.bin
radeon/kaveri_sdma1.bin radeon/kaveri_sdma.bin radeon/kaveri_uvd.bin
radeon/kaveri_vce.bin

Unfortunately, radeon/kaveri_sdma1.bin does not seen to be available when I
use sys-kernel/linux-firmware:

find /lib/firmware/radeon/ -iname KAVERI*sdma*
/lib/firmware/radeon/kaveri_sdma.bin
/lib/firmware/radeon/KAVERI_sdma.bin


I installed sys-firmware/amdgpu-ucode, but KAVERI is not found there either:

find /lib/firmware/amdgpu/ -iname *sdma*
/lib/firmware/amdgpu/carrizo_sdma.bin
/lib/firmware/amdgpu/carrizo_sdma1.bin
/lib/firmware/amdgpu/fiji_sdma.bin
/lib/firmware/amdgpu/fiji_sdma1.bin
/lib/firmware/amdgpu/tonga_sdma.bin
/lib/firmware/amdgpu/tonga_sdma1.bin
/lib/firmware/amdgpu/topaz_sdma.bin
/lib/firmware/amdgpu/topaz_sdma1.bin


Building the recommended blobs fails like so:

# make && make modules_install && make firmware_install
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CHK include/generated/bounds.h
CHK include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
kernel/Makefile:135: *** No X.509 certificates found ***
make[1]: *** No rule to make target '/lib/firmware//radeon/kaveri_sdma1.bin',
needed by 'firmware/radeon/kaveri_sdma1.bin.gen.o'. Stop.
Makefile:947: recipe for target 'firmware' failed
make: *** [firmware] Error 2

What now?

PS. As VIDEO_CARDS in make.conf I used to have radeon and radeonsi, but have
now changed it to amdgpu and radeonsi. Should I revert and forget about
radeon/kaveri_sdma1.bin?
--
Regards,
Mick
signature.asc

Alexander Kapshuk

unread,
Dec 20, 2015, 3:40:03 PM12/20/15
to
That's interesting. 'kaveri_sdma1.bin' is found in the 'sys-firmware/amdgpu-ucode' package. See below.
% pwd
radeon_ucode/kaveri
% ls -1 *sdma*
kaveri_sdma.bin
kaveri_sdma1.bin

Perhaps the path to the binary blobs specified in your kernel config file is wrong? You want to double check that.

Mick

unread,
Dec 20, 2015, 6:30:03 PM12/20/15
to
Hmm .. perhaps I've been doing this wrong? Should I fill in:

(amdgpu/kaveri.bin radeon/kaveri.bin)

instead of:

(radeon/kaveri_ce.bin radeon/kaveri_me.bin radeon/kaveri_mec2.bin
radeon/kaveri_mec.bin radeon/kaveri_pfp.bin radeon/kaveri_rlc.bin
radeon/kaveri_sdma1.bin radeon/kaveri_sdma.bin radeon/kaveri_uvd.bin
radeon/kaveri_vce.bin)

I've been doing the latter for as long as I can remember.
--
Regards,
Mick
signature.asc

Tsukasa Mcp_Reznor

unread,
Dec 20, 2015, 7:30:04 PM12/20/15
to

For my part, switching to amdgpu resulted in hard locking on sleep/resume, when switching back to radeon, there was another hard lock on boot if I continued using the amdgpu-ucode, until I removed it and put linux-firmware back on, there seems to be differences between the two.

amdgpu kernel, amdgpu-ucode, and (radeon/kaveri_ce.bin radeon/kaveri_me.bin radeon/kaveri_mec2.bin radeon/kaveri_mec.bin radeon/kaveri_pfp.bin radeon/kaveri_rlc.bin radeon/kaveri_sdma1.bin radeon/kaveri_sdma.bin radeon/kaveri_uvd.bin radeon/kaveri_vce.bin) all together should do the trick

Mick

unread,
Dec 22, 2015, 2:50:03 PM12/22/15
to
On Sunday 20 Dec 2015 20:29:28 Alexander Kapshuk wrote:
> That's interesting. 'kaveri_sdma1.bin' is found in the
> 'sys-firmware/amdgpu-ucode' package. See below.
> % pwd
> radeon_ucode/kaveri

I don't seem to have such a directory, or the files therein. Where am I
supposed to look?

This is what emerge -uaDv sys-firmware/amdgpu-ucode installed on my PC:

>>> Installing (1 of 1) sys-firmware/amdgpu-ucode-20150803::gentoo
* checking 44 files for package collisions
>>> Merging sys-firmware/amdgpu-ucode-20150803 to /
--- /lib/
--- /lib/firmware/
--- /lib/firmware/amdgpu/
>>> /lib/firmware/amdgpu/carrizo_ce.bin
>>> /lib/firmware/amdgpu/carrizo_me.bin
>>> /lib/firmware/amdgpu/carrizo_mec.bin
>>> /lib/firmware/amdgpu/carrizo_mec2.bin
>>> /lib/firmware/amdgpu/carrizo_pfp.bin
>>> /lib/firmware/amdgpu/carrizo_rlc.bin
>>> /lib/firmware/amdgpu/carrizo_sdma.bin
>>> /lib/firmware/amdgpu/carrizo_sdma1.bin
>>> /lib/firmware/amdgpu/carrizo_uvd.bin
>>> /lib/firmware/amdgpu/carrizo_vce.bin
>>> /lib/firmware/amdgpu/fiji_ce.bin
>>> /lib/firmware/amdgpu/fiji_mc.bin
>>> /lib/firmware/amdgpu/fiji_me.bin
>>> /lib/firmware/amdgpu/fiji_mec.bin
>>> /lib/firmware/amdgpu/fiji_mec2.bin
>>> /lib/firmware/amdgpu/fiji_pfp.bin
>>> /lib/firmware/amdgpu/fiji_rlc.bin
>>> /lib/firmware/amdgpu/fiji_sdma.bin
>>> /lib/firmware/amdgpu/fiji_sdma1.bin
>>> /lib/firmware/amdgpu/fiji_smc.bin
>>> /lib/firmware/amdgpu/fiji_uvd.bin
>>> /lib/firmware/amdgpu/fiji_vce.bin
>>> /lib/firmware/amdgpu/tonga_ce.bin
>>> /lib/firmware/amdgpu/tonga_mc.bin
>>> /lib/firmware/amdgpu/tonga_me.bin
>>> /lib/firmware/amdgpu/tonga_mec.bin
>>> /lib/firmware/amdgpu/tonga_mec2.bin
>>> /lib/firmware/amdgpu/tonga_pfp.bin
>>> /lib/firmware/amdgpu/tonga_rlc.bin
>>> /lib/firmware/amdgpu/tonga_sdma.bin
>>> /lib/firmware/amdgpu/tonga_sdma1.bin
>>> /lib/firmware/amdgpu/tonga_smc.bin
>>> /lib/firmware/amdgpu/tonga_uvd.bin
>>> /lib/firmware/amdgpu/tonga_vce.bin
>>> /lib/firmware/amdgpu/topaz_ce.bin
>>> /lib/firmware/amdgpu/topaz_mc.bin
>>> /lib/firmware/amdgpu/topaz_me.bin
>>> /lib/firmware/amdgpu/topaz_mec.bin
>>> /lib/firmware/amdgpu/topaz_mec2.bin
>>> /lib/firmware/amdgpu/topaz_pfp.bin
>>> /lib/firmware/amdgpu/topaz_rlc.bin
>>> /lib/firmware/amdgpu/topaz_sdma.bin
>>> /lib/firmware/amdgpu/topaz_sdma1.bin
>>> /lib/firmware/amdgpu/topaz_smc.bin

No /kaveri/ in there.


> Perhaps the path to the binary blobs specified in your kernel config file
> is wrong? You want to double check that.


This is what I have:

grep /firmware .config
CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware/"

Looking at it again the amdgpu wiki page does not list amdgpu firmwares for
the KAVERI APU. However, I am confused as to why I can't find
radeon/kaveri_sdma1 in my installed firmwares (either from linux-firmware, or
from amdgpu-ucode.

--
Regards,
Mick
signature.asc

Alexander Kapshuk

unread,
Dec 22, 2015, 4:40:03 PM12/22/15
to
What USE flags did you compile 'sys-firmware/amdgpu-ucode' with?

If I am reading the section of the ebuild shown below correctly, having 'legacy' enabled is what installs the 'kaveri' binaries.
/usr/portage/sys-firmware/amdgpu-ucode/amdgpu-ucode-20150803.ebuild:23,33
AMDGPU_LEGACY_CIK="bonaire hawaii kabini kaveri mullins"

src_install() {
    local directory files legacyfiles
    if use legacy; then
        for directory in ${AMDGPU_LEGACY_CIK}; do
            legacyfiles+=( ${directory}/*.bin )
        done
        insinto /lib/firmware/radeon
        doins ${legacyfiles[@]}
    fi

'legacy' seems to be disabled by default. See below.
# emerge -ap sys-firmware/amdgpu-ucode

These are the packages that would be merged, in order:

Calculating dependencies  ... done!
[ebuild  N    ~] sys-firmware/amdgpu-ucode-20150803  USE="-legacy"

Mick

unread,
Dec 22, 2015, 6:10:03 PM12/22/15
to
Aha! Good catch!

[- ] legacy
sys-firmware/amdgpu-ucode: Install firmware for older chipsets which
are optionally supported by AMDGPU
[- ] 20150803 [gentoo]


Can I have both amdgpu and linux-firmware?

The latter has some wireless firmware I think I need to retain.
--
Regards,
Mick
signature.asc

Mick

unread,
Dec 22, 2015, 6:10:03 PM12/22/15
to
OK, I can have both emerged with the legacy USE flag, because of radeon
firmware file collisions.

--
Regards,
Mick
signature.asc

Mick

unread,
Dec 22, 2015, 6:50:03 PM12/22/15
to
I think I have some success! :-) It booted without any discernible problems,
although I came across this complain in dmesg:

[ 0.544769] [drm] radeon: 1024M of VRAM memory ready
[ 0.544772] [drm] radeon: 1024M of GTT memory ready.
[ 0.544781] [drm] Loading kaveri Microcode
[ 0.544788] [drm] Internal thermal controller without fan control
[ 0.546112] [drm] radeon: dpm initialized
[ 0.546126] radeon 0000:00:01.0: Direct firmware load for
radeon/BONAIRE_uvd.bin failed with error -2
[ 0.546131] radeon 0000:00:01.0: radeon_uvd: Can't load firmware
"radeon/BONAIRE_uvd.bin"
[ 0.546141] radeon 0000:00:01.0: Direct firmware load for
radeon/BONAIRE_vce.bin failed with error -2
[ 0.546146] radeon 0000:00:01.0: radeon_vce: Can't load firmware
"radeon/BONAIRE_vce.bin"
[ 0.546152] [drm] GART: num cpu pages 262144, num gpu pages 262144
[ 0.559563] [drm] PCIE GART of 1024M enabled (table at 0x0000000000040000).
[ 0.559896] radeon 0000:00:01.0: WB enabled
[ 0.559923] radeon 0000:00:01.0: fence driver on ring 0 use gpu addr
0x0000000040000c00 and cpu addr 0xffff88041dc03c00
[ 0.559931] radeon 0000:00:01.0: fence driver on ring 1 use gpu addr
0x0000000040000c04 and cpu addr 0xffff88041dc03c04
[ 0.559937] radeon 0000:00:01.0: fence driver on ring 2 use gpu addr
0x0000000040000c08 and cpu addr 0xffff88041dc03c08
[ 0.559944] radeon 0000:00:01.0: fence driver on ring 3 use gpu addr
0x0000000040000c0c and cpu addr 0xffff88041dc03c0c
[ 0.559950] radeon 0000:00:01.0: fence driver on ring 4 use gpu addr
0x0000000040000c10 and cpu addr 0xffff88041dc03c10
[ 0.559957] radeon 0000:00:01.0: VCE init error (-22).
[ 0.559961] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[ 0.559965] [drm] Driver supports precise vblank timestamp query.
[ 0.559997] radeon 0000:00:01.0: radeon: using MSI.
[ 0.560020] [drm] radeon: irq initialized.


Why is it asking for radeon/BONAIRE_*.bin? :-/

The wiki page suggests I use the kaveri list of firmwares. Should I use
bonaire instead? Or should I add the bonaire list to my existing kaveri
firmwares in the kernel?
--
Regards,
Mick
signature.asc

Tsukasa Mcp_Reznor

unread,
Dec 23, 2015, 6:20:04 AM12/23/15
to
> From: michael...@gmail.com
> To: gento...@lists.gentoo.org
> Subject: Re: [gentoo-user] (Not Solved for me) anyone tried amdgpu (kernel module)



yes you can, you have to install linux-firmware with the savedconfig use flag, after emerging it'll give the location of the config file in the output, open it up and remove the radeon firmware from being built so there are no collisions and you can remove anything else you are sure you won't need, then re-emerge linux-firmware and you should be good to go
I needed network firmware also
0 new messages