Tiny Core Extensions > TCE Tips & Tricks
How to fix failed firmware loading in TC16
CNK:
In Devuan udev(7) it says that when using RUN "the program is expected to live in /lib/udev; otherwise, the absolute path must be specified" and /lib/udev is where I find firmware.sh.
Although another man page for udev online says /usr/lib/udev and there's no udev-doc.tcz for TC's udev.
I could try running udev debugging via SSH on the laptop as described here while loading graphics-KERNEL with the default firmware configuration if that's worthwhile?
Juanito:
If you could try the debugging that would be much appreciated.
CNK:
It turns out the Radeon driver does time-out after 60sec when the firmware loading fails and the display returns to the text-mode terminal, I wasn't waiting long enough before.
udev correctly receives the firmware event:
--- Code: ---KERNEL[366.250566] add /devices/pci0000:00/0000:00:01.0/0000:01:00.0/firmware/radeon!R520_cp.bin (firmware)
ACTION=add
ASYNC=0
DEVPATH=/devices/pci0000:00/0000:00:01.0/0000:01:00.0/firmware/radeon!R520_cp.bin
FIRMWARE=radeon/R520_cp.bin
SEQNUM=4721
SUBSYSTEM=firmware
TIMEOUT=60
--- End code ---
In the syslog (with extra udev logging enabled using "sudo udevadm control --log-priority debug") you can see that firmware.sh seems to hang until udevd aborts due to the timeout:
--- Code: ---Jun 5 10:57:11 TPT60 daemon.info udevd[4267]: seq 4721 running
Jun 5 10:57:11 TPT60 daemon.info udevd[4267]: device 0x3ff90340 has devpath '/devices/pci0000:00/0000:00:01.0/0000:01:00.0/firmware/radeon!R520_cp.bin'
Jun 5 10:57:11 TPT60 daemon.info udevd[4267]: no db file to read /run/udev/data/+firmware:radeon!R520_cp.bin: No such file or directory
Jun 5 10:57:11 TPT60 daemon.info udevd[4267]: RUN 'firmware.sh' /etc/udev/rules.d/50-firmware.rules:5
Jun 5 10:57:11 TPT60 daemon.info udevd[4267]: device 0x3ffb9b70 has devpath '/devices/pci0000:00/0000:00:01.0/0000:01:00.0'
Jun 5 10:58:10 TPT60 daemon.err udevd[4308]: timeout '/sbin/modprobe -bv pci:v00001002d00007149sv000017AAsd00002005bc03sc00i00'
--- End code ---
dmesg shows this:
--- Code: ---[ 360.789186] i801_smbus 0000:00:1f.3: SMBus using PCI interrupt
[ 365.319064] Linux agpgart interface v0.103
[ 365.431641] ACPI: bus type drm_connector registered
[ 366.176654] [drm] amdgpu kernel modesetting enabled.
[ 366.176881] amdgpu: Virtual CRAT table created for CPU
[ 366.176917] amdgpu: Topology: Add CPU node
[ 366.240728] [drm] radeon kernel modesetting enabled.
[ 366.241067] Console: switching to colour dummy device 80x25
[ 366.241187] radeon 0000:01:00.0: vgaarb: deactivate vga console
[ 366.241387] [drm] initializing kernel modesetting (RV515 0x1002:0x7149 0x17AA:0x2005 0x00).
[ 366.241458] resource: resource sanity check: requesting [mem 0x00000000000c0000-0x00000000000dffff], which spans more than PCI Bus 0000:00 [mem 0x000d0000-0x000dbfff window]
[ 366.241465] caller 0xffffffff814c86b3 mapping multiple BARs
[ 366.241576] ATOM BIOS: M64CSP/M62CSP/M54CSP/M52CSP
[ 366.241619] [drm] Generation 2 PCI interface, using max accessible memory
[ 366.241628] radeon 0000:01:00.0: VRAM: 128M 0x0000000000000000 - 0x0000000007FFFFFF (64M used)
[ 366.241635] radeon 0000:01:00.0: GTT: 512M 0x0000000008000000 - 0x0000000027FFFFFF
[ 366.241662] [drm] Detected VRAM RAM=128M, BAR=128M
[ 366.241666] [drm] RAM width 64bits DDR
[ 366.241849] [drm] radeon: 64M of VRAM memory ready
[ 366.241855] [drm] radeon: 512M of GTT memory ready.
[ 366.241874] [drm] GART: num cpu pages 131072, num gpu pages 131072
[ 366.242756] [drm] radeon: power management initialized
[ 366.247987] [drm] radeon: 1 quad pipes, 1 z pipes initialized.
[ 366.250396] [drm] PCIE GART of 512M enabled (table at 0x0000000000040000).
[ 366.250430] radeon 0000:01:00.0: WB enabled
[ 366.250437] radeon 0000:01:00.0: fence driver on ring 0 use gpu addr 0x0000000008000000
[ 366.250647] radeon 0000:01:00.0: radeon: MSI limited to 32-bit
[ 366.250680] [drm] radeon: irq initialized.
[ 366.250699] [drm] Loading R500 Microcode
[ 366.250752] radeon 0000:01:00.0: Direct firmware load for radeon/R520_cp.bin failed with error -2
[ 366.250757] radeon 0000:01:00.0: Falling back to sysfs fallback for: radeon/R520_cp.bin
[ 426.227308] radeon_cp: Failed to load firmware "radeon/R520_cp.bin"
[ 426.227329] [drm:0xffffffffa0a9b3a8] *ERROR* Failed to load firmware!
[ 426.227345] radeon 0000:01:00.0: failed initializing CP (-4).
[ 426.227356] radeon 0000:01:00.0: Disabling GPU acceleration
--- End code ---
I've uploaded full logs here, however there's a lot of noise from other udev events triggered when graphics-KERNEL is loaded. It seems to hang running /lib/udev/firmware.sh, or perhaps after it.
Juanito:
--- Quote from: Rich on June 03, 2025, 11:46:46 PM ---There is no path included with "firmware.sh", so I don't think
it will be found.
--- End quote ---
Could you try with the full path to firmware.sh and see if it helps?
i.e.
--- Code: ---SUBSYSTEM=="firmware", ACTION=="add", RUN+="/lib/udev/firmware.sh"
--- End code ---
Rich:
Hi Juanito
It's starting to sound like the simplest fix would be to add a
link in rootfs.gz from /usr/local/lib/firmware to /lib/firmware.
If the kernel is loading firmware from /lib/firmware, why fight it.
Existing firmware extensions could remain as is, and just work.
Just my 2 cents.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version