Raspberry pi 5 bookworm aplay -l no soundcards found

Hello,

I have a Raspberry PI 5 running on bookworm:

Linux Home 6.6.20+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.20-1+rpt1 (2024-03-07) aarch64

When I run aplay -l, I get:

aplay: device_list:274: no soundcards found...

In dietpi-config I selected:

Sound card          : [rpi-bcm2835-hdmi] 
Auto-conversion     : [Off] Automatic software conversions
PSU noise reduction : [Off]
cat /proc/asound/cards:
--- no soundcards ---
lsmod | grep snd:
snd_soc_hdmi_codec     49152  0
snd_soc_core          327680  2 vc4,snd_soc_hdmi_codec
snd_compress           49152  1 snd_soc_core
snd_pcm_dmaengine      49152  1 snd_soc_core
snd_pcm               163840  4 snd_soc_hdmi_codec,snd_compress,snd_soc_core,snd_pcm_dmaengine
snd_timer              65536  1 snd_pcm
snd                   147456  5 snd_soc_hdmi_codec,snd_timer,snd_compress,snd_soc_core,snd_pcm
/boot/dietpi.txt:
# Sound card
CONFIG_SOUNDCARD=rpi-bcm2835-hdmi
/boot/firmware/config.txt:
#-------Onboard sound-----------
dtparam=audio=on

When I play a wav file I get:

ALSA lib confmisc.c:165:(snd_config_get_card) Cannot get card index for 0
Can't open libao driver with device hw:0,0 (is device in use?)

What can I do to get the soundcard bcm2835 working?

Thanks in advance for helping me!

@MichaIng maybe you can have a look pls.

Hi,

I changed the config.txt file to:

#-------Onboard sound-----------
dtparam=audio=off
dtoverlay=vc4-kms-v3d

Now I get sound but can’t execute startx .
I get the following error:

Fatal server error:
[    50.141] (EE) Cannot run in framebuffer mode. Please specify busIDs        for all framebuffer devices

Does anyone know what I can do to solve this?

Many thanks in advance.

So with KMS disabled (no dtoverlay=vc4-kms-v3d), hence using the Broadcom onboard audio driver, you do not get HDMI audio, not even a HDMI device listed in aplay -l? This worked well on my RPi Zero W, but not sure whether I tested it on RPi 5. You did a reboot after changing/selecting the sound card, right?

Ah, wait a second, dtoverlay=vc4-kms-v3d (in case with ,noaudio appended) was present, i.e. KMS used in the first place, based on the loaded kernel modules. In this case, when you select rpi-bcm2835-hdmi, dtparam=audio=off should be set automatically, and in case the noaudio parameter for the KMS dtoverlay removed. After a reboot, you should then have HDMI audio via KMS HDMI audio driver, shown as vc4hdmi in aplay -l and /proc/asound/card0/name.

The X11 error indicates that it tries to use the framebuffer for video output, while it should use KMS/DRM. Can you show the full output of X11? There should be also a log file mentioned which contains more details.
What can be the case is missing permissions to access the DRM devices. If you do not use root, the user needs to be member of the render group, like:

sudo usermod -aG render <username>

Hello,

First of all, I would like to thank you for your answer!

The answer to your first 2 questions is yes.

The log file “/var/log/Xorg.0.log” gives:

[   584.843] 
X.Org X Server 1.21.1.7
X Protocol Version 11, Revision 0
[   584.843] Current Operating System: Linux Pandora 6.6.20+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.20-1+rpt1 (2024-03-07) aarch64
[   584.843] Kernel command line: reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1  smsc95xx.macaddr=2C:CF:67:26:D5:BA vc_mem.mem_base=0x3fc00000 vc_mem.mem_size=0x40000000  root=PARTUUID=8b0ac6f5-02 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0 logo.nologo quiet console=ttyS0,115200 console=tty1 snd_bcm2835.enable_headphones=0
[   584.843] xorg-server 2:21.1.7-3+rpt2+deb12u5 (https://www.debian.org/support) 
[   584.843] Current version of pixman: 0.42.2
[   584.843] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[   584.843] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[   584.843] (==) Log file: "/var/log/Xorg.0.log", Time: Fri Mar 29 22:34:56 2024
[   584.843] (==) Using config directory: "/etc/X11/xorg.conf.d"
[   584.843] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[   584.843] (==) No Layout section.  Using the first Screen section.
[   584.843] (==) No screen section available. Using defaults.
[   584.843] (**) |-->Screen "Default Screen Section" (0)
[   584.843] (**) |   |-->Monitor "<default monitor>"
[   584.843] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[   584.843] (**) Option "BlankTime" "0"
[   584.843] (==) Automatically adding devices
[   584.843] (==) Automatically enabling devices
[   584.843] (==) Automatically adding GPU devices
[   584.843] (==) Automatically binding GPU devices
[   584.843] (==) Max clients allowed: 256, resource mask: 0x1fffff
[   584.843] (WW) The directory "/usr/share/fonts/X11/cyrillic" does not exist.
[   584.843] 	Entry deleted from font path.
[   584.843] (WW) The directory "/usr/share/fonts/X11/100dpi/" does not exist.
[   584.843] 	Entry deleted from font path.
[   584.843] (WW) The directory "/usr/share/fonts/X11/75dpi/" does not exist.
[   584.843] 	Entry deleted from font path.
[   584.843] (WW) The directory "/usr/share/fonts/X11/100dpi" does not exist.
[   584.843] 	Entry deleted from font path.
[   584.843] (WW) The directory "/usr/share/fonts/X11/75dpi" does not exist.
[   584.843] 	Entry deleted from font path.
[   584.843] (==) FontPath set to:
	/usr/share/fonts/X11/misc,
	/usr/share/fonts/X11/Type1,
	built-ins
[   584.843] (==) ModulePath set to "/usr/lib/xorg/modules"
[   584.843] (**) Extension "DPMS" is disabled
[   584.843] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[   584.843] (II) Loader magic: 0x5555a5b50ef0
[   584.843] (II) Module ABI versions:
[   584.843] 	X.Org ANSI C Emulation: 0.4
[   584.843] 	X.Org Video Driver: 25.2
[   584.843] 	X.Org XInput driver : 24.4
[   584.843] 	X.Org Server Extension : 10.0
[   584.844] (--) using VT number 2

[   584.844] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[   584.845] (II) xfree86: Adding drm device (/dev/dri/card0)
[   584.845] (II) Platform probe for /sys/devices/platform/axi/1002000000.v3d/drm/card0
[   584.845] (II) xfree86: Adding drm device (/dev/dri/card1)
[   584.845] (II) Platform probe for /sys/devices/platform/axi/axi:gpu/drm/card1
[   584.856] (II) no primary bus or device found
[   584.856] 	falling back to /sys/devices/platform/axi/1002000000.v3d/drm/card0
[   584.856] (II) LoadModule: "glx"
[   584.856] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[   584.857] (II) Module glx: vendor="X.Org Foundation"
[   584.857] 	compiled for 1.21.1.7, module version = 1.0.0
[   584.857] 	ABI class: X.Org Server Extension, version 10.0
[   584.857] (==) Matched modesetting as autoconfigured driver 0
[   584.857] (==) Matched fbdev as autoconfigured driver 1
[   584.857] (==) Assigned the driver to the xf86ConfigLayout
[   584.857] (II) LoadModule: "modesetting"
[   584.857] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[   584.858] (II) Module modesetting: vendor="X.Org Foundation"
[   584.858] 	compiled for 1.21.1.7, module version = 1.21.1
[   584.858] 	Module class: X.Org Video Driver
[   584.858] 	ABI class: X.Org Video Driver, version 25.2
[   584.858] (II) LoadModule: "fbdev"
[   584.858] (II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
[   584.858] (II) Module fbdev: vendor="X.Org Foundation"
[   584.858] 	compiled for 1.21.1.3, module version = 0.5.0
[   584.858] 	Module class: X.Org Video Driver
[   584.858] 	ABI class: X.Org Video Driver, version 25.2
[   584.858] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[   584.858] (II) FBDEV: driver for framebuffer: fbdev
[   584.874] (WW) Falling back to old probe method for modesetting
[   584.874] (WW) Falling back to old probe method for fbdev
[   584.874] (II) Loading sub module "fbdevhw"
[   584.874] (II) LoadModule: "fbdevhw"
[   584.874] (II) Loading /usr/lib/xorg/modules/libfbdevhw.so
[   584.875] (II) Module fbdevhw: vendor="X.Org Foundation"
[   584.875] 	compiled for 1.21.1.7, module version = 0.0.2
[   584.875] 	ABI class: X.Org Video Driver, version 25.2
[   584.875] (II) FBDEV(0): using default device
[   584.889] (II) modeset(G0): using drv /dev/dri/card1
[   584.889] (EE) 
Fatal server error:
[   584.889] (EE) Cannot run in framebuffer mode. Please specify busIDs        for all framebuffer devices
[   584.889] (EE) 
[   584.889] (EE) 
Please consult the The X.Org Foundation support 
	 at http://wiki.x.org
 for help. 
[   584.889] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[   584.889] (EE) 
[   584.958] (EE) Server terminated with error (1). Closing log file.

config.txt file:

# Docs: https://github.com/raspberrypi/documentation/blob/33ea36435a7843ac9de9c79ed79304654be2bc9f/configuration/config-txt/README.md
# Overlays: https://github.com/raspberrypi/firmware/blob/a43358b730465f0b53287b890ee73ec2d3c1819a/boot/overlays/README

#-------Display---------
# Max allocated framebuffers: Set to "0" in headless mode to reduce memory usage
# - Defaults to "2" on RPi4 and "1" on earlier RPi models
#max_framebuffers=0

# If you get no picture, set the following to "1" to apply most compatible HDMI settings.
hdmi_safe=1

# Uncomment to adjust the HDMI signal strength if you have interferences, blanking, or no display.
# - Values from "0" to "11" are allowed, use values above "7" only if required, e.g. with very long
# - Default on first RPi1 A/B is "2", else "5", on RPi4 this setting is ignored.
#config_hdmi_boost=5

# Uncomment if HDMI display is not detected and composite is being outputted.
hdmi_force_hotplug=1

# Uncomment to disable HDMI even if plugged, e.g. to force composite output.
#hdmi_ignore_hotplug=1

# Uncomment to force a console size. By default it will be display's size minus overscan.
framebuffer_width=1920
framebuffer_height=1080

# Uncomment to enable SDTV/composite output on RPi4. This has no effect on previous RPi models.
#enable_tvout=0
# SDTV mode
#sdtv_mode=0

# Uncomment to force a specific HDMI mode (this will force VGA).
#hdmi_group=1
#hdmi_mode=1

# Uncomment to force an HDMI mode rather than DVI. This can make audio work in DMT (computer monito
hdmi_drive=2
hdmi_drive:1=2

# Set "hdmi_blanking=1" to allow the display going into standby after 10 minutes without input.
# With default value "0", the display shows a blank screen instead, but will not go into standby.
# NB: With "1" some applications (e.g. Kodi, OMXPlayer) cannot prevent display standby due to missi
#hdmi_blanking=1

# Set to "1" if your display has a black border of unused pixels visible.
disable_overscan=1

# Uncomment the following to adjust overscan. Use positive numbers if console goes off screen, and 
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

# Rotation
#display_hdmi_rotate=0
#lcd_rotate=0

#-------RPi camera module-------
#start_x=1 
disable_camera_led=1

#-------GPU memory splits-------
gpu_mem_256=96
gpu_mem_512=96
gpu_mem_1024=96

#-------Boot splash screen------
disable_splash=1

#-------Onboard sound-----------
dtparam=audio=off
dtoverlay=vc4-kms-v3d

#-------I2C-------------
dtparam=i2c_arm=on
#dtparam=i2c_arm_baudrate=100000
dtoverlay=i2c-gpio,bus=4,i2c_gpio_delay_us=1,i2c_gpio_sda=23,i2c_gpio_scl=24

#-------SPI-------------
#dtparam=spi=off

#-------Serial/UART-----
# NB: Enabled for 1st run only. If you want to keep this setting, please set CONFIG_SERIAL_CONSOLE_
# NB: "enable_uart=1" will forcefully set "core_freq=250" on WiFi/BT-capable RPi models, unless "fo
enable_uart=0

#-------Overclock-------
temp_limit=75
#initial_turbo=20

#over_voltage=0
#arm_freq=1400
#core_freq=400
#sdram_freq=500

#over_voltage_min=0
#arm_freq_min=300
#core_freq_min=250
#sdram_freq_min=400
arm_64bit=1

#undervoltage waarschuwing voorkomen
avoid_warnings=2

#fout van usb modem huawei voorkomen
dtoverlay=dwc2

cmdline.txt:

root=PARTUUID=8b0ac6f5-02 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0 logo.nologo quiet console=ttyS0,115200 console=tty1 snd_bcm2835.enable_headphones=0
usbcore.autosuspend=-1

It loads the KMS driver, even states to use /dev/dri/card1, but in the end still tries to and fails to load the framebuffer driver, for some reason. Does it help to remove the related DDX package:

sudo apt autopurge xserver-xorg-video-fbdev

Don’t do that: If you get voltage warnings, use a better PSU, else you are risking I/O errors and data loss :wink:. This can theoretically even be the reason for audio and HDMI issues, if e.g. the devices are disconnecting for short periods, due to insufficient/unstable voltage/powering.

Unfortunately this did not solve the problem:

[    28.426] 
X.Org X Server 1.21.1.7
X Protocol Version 11, Revision 0
[    28.426] Current Operating System: Linux Pandora 6.6.20+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.20-1+rpt1 (2024-03-07) aarch64
[    28.426] Kernel command line: reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1  smsc95xx.macaddr=2C:CF:67:26:D5:BA vc_mem.mem_base=0x3fc00000 vc_mem.mem_size=0x40000000  root=PARTUUID=8b0ac6f5-02 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0 logo.nologo quiet console=ttyS0,115200 console=tty1 snd_bcm2835.enable_headphones=0
[    28.426] xorg-server 2:21.1.7-3+rpt2+deb12u5 (https://www.debian.org/support) 
[    28.426] Current version of pixman: 0.42.2
[    28.426] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[    28.426] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    28.426] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Apr  1 09:59:25 2024
[    28.436] (==) Using config directory: "/etc/X11/xorg.conf.d"
[    28.436] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[    28.440] (==) No Layout section.  Using the first Screen section.
[    28.440] (==) No screen section available. Using defaults.
[    28.440] (**) |-->Screen "Default Screen Section" (0)
[    28.440] (**) |   |-->Monitor "<default monitor>"
[    28.441] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[    28.441] (**) Option "BlankTime" "0"
[    28.441] (==) Automatically adding devices
[    28.441] (==) Automatically enabling devices
[    28.441] (==) Automatically adding GPU devices
[    28.441] (==) Automatically binding GPU devices
[    28.443] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    28.446] (WW) The directory "/usr/share/fonts/X11/cyrillic" does not exist.
[    28.446] 	Entry deleted from font path.
[    28.446] (WW) The directory "/usr/share/fonts/X11/100dpi/" does not exist.
[    28.446] 	Entry deleted from font path.
[    28.446] (WW) The directory "/usr/share/fonts/X11/75dpi/" does not exist.
[    28.446] 	Entry deleted from font path.
[    28.446] (WW) The directory "/usr/share/fonts/X11/100dpi" does not exist.
[    28.446] 	Entry deleted from font path.
[    28.446] (WW) The directory "/usr/share/fonts/X11/75dpi" does not exist.
[    28.446] 	Entry deleted from font path.
[    28.446] (==) FontPath set to:
	/usr/share/fonts/X11/misc,
	/usr/share/fonts/X11/Type1,
	built-ins
[    28.446] (==) ModulePath set to "/usr/lib/xorg/modules"
[    28.446] (**) Extension "DPMS" is disabled
[    28.446] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[    28.446] (II) Loader magic: 0x5555fc9f0ef0
[    28.446] (II) Module ABI versions:
[    28.446] 	X.Org ANSI C Emulation: 0.4
[    28.446] 	X.Org Video Driver: 25.2
[    28.446] 	X.Org XInput driver : 24.4
[    28.446] 	X.Org Server Extension : 10.0
[    28.447] (--) using VT number 2

[    28.447] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[    28.448] (II) xfree86: Adding drm device (/dev/dri/card0)
[    28.448] (II) Platform probe for /sys/devices/platform/axi/1002000000.v3d/drm/card0
[    28.448] (II) xfree86: Adding drm device (/dev/dri/card1)
[    28.448] (II) Platform probe for /sys/devices/platform/axi/axi:gpu/drm/card1
[    28.451] (II) no primary bus or device found
[    28.451] 	falling back to /sys/devices/platform/axi/1002000000.v3d/drm/card0
[    28.451] (II) LoadModule: "glx"
[    28.452] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[    28.497] (II) Module glx: vendor="X.Org Foundation"
[    28.497] 	compiled for 1.21.1.7, module version = 1.0.0
[    28.497] 	ABI class: X.Org Server Extension, version 10.0
[    28.497] (==) Matched modesetting as autoconfigured driver 0
[    28.497] (==) Matched fbdev as autoconfigured driver 1
[    28.497] (==) Assigned the driver to the xf86ConfigLayout
[    28.497] (II) LoadModule: "modesetting"
[    28.498] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[    28.508] (II) Module modesetting: vendor="X.Org Foundation"
[    28.508] 	compiled for 1.21.1.7, module version = 1.21.1
[    28.508] 	Module class: X.Org Video Driver
[    28.508] 	ABI class: X.Org Video Driver, version 25.2
[    28.509] (II) LoadModule: "fbdev"
[    28.510] (WW) Warning, couldn't open module fbdev
[    28.510] (EE) Failed to load module "fbdev" (module does not exist, 0)
[    28.510] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[    28.520] (WW) Falling back to old probe method for modesetting
[    28.520] (WW) Falling back to old probe method for modesetting
[    28.534] (II) modeset(G0): using drv /dev/dri/card1
[    28.534] (EE) No devices detected.
[    28.534] (EE) 
Fatal server error:
[    28.534] (EE) no screens found(EE) 
[    28.534] (EE) 
Please consult the The X.Org Foundation support 
	 at http://wiki.x.org
 for help. 
[    28.534] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[    28.534] (EE) 
[    28.602] (EE) Server terminated with error (1). Closing log file.

I’m using an original raspberry PSU now, avoid_warnings has been commented in config.txt:
#avoid_warnings=2

Do you have any other ideas I can try?

can you have a look into this lxde + kodi - #4 by Joulinar

I reinstalled fbdev but the problem stays the same:


[    29.513] 
X.Org X Server 1.21.1.7
X Protocol Version 11, Revision 0
[    29.513] Current Operating System: Linux Pandora 6.6.20+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.20-1+rpt1 (2024-03-07) aarch64
[    29.513] Kernel command line: reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1  smsc95xx.macaddr=2C:CF:67:26:D5:BA vc_mem.mem_base=0x3fc00000 vc_mem.mem_size=0x40000000  root=PARTUUID=8b0ac6f5-02 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0 logo.nologo quiet console=ttyS0,115200 console=tty1 snd_bcm2835.enable_headphones=0
[    29.513] xorg-server 2:21.1.7-3+rpt2+deb12u5 (https://www.debian.org/support) 
[    29.513] Current version of pixman: 0.42.2
[    29.513] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[    29.513] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    29.513] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Apr  1 10:56:44 2024
[    29.518] (==) Using config directory: "/etc/X11/xorg.conf.d"
[    29.518] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[    29.522] (==) No Layout section.  Using the first Screen section.
[    29.522] (==) No screen section available. Using defaults.
[    29.522] (**) |-->Screen "Default Screen Section" (0)
[    29.522] (**) |   |-->Monitor "<default monitor>"
[    29.522] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[    29.522] (**) Option "BlankTime" "0"
[    29.522] (==) Automatically adding devices
[    29.522] (==) Automatically enabling devices
[    29.522] (==) Automatically adding GPU devices
[    29.522] (==) Automatically binding GPU devices
[    29.525] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    29.528] (WW) The directory "/usr/share/fonts/X11/cyrillic" does not exist.
[    29.528] 	Entry deleted from font path.
[    29.528] (WW) The directory "/usr/share/fonts/X11/100dpi/" does not exist.
[    29.528] 	Entry deleted from font path.
[    29.528] (WW) The directory "/usr/share/fonts/X11/75dpi/" does not exist.
[    29.528] 	Entry deleted from font path.
[    29.528] (WW) The directory "/usr/share/fonts/X11/100dpi" does not exist.
[    29.528] 	Entry deleted from font path.
[    29.528] (WW) The directory "/usr/share/fonts/X11/75dpi" does not exist.
[    29.528] 	Entry deleted from font path.
[    29.528] (==) FontPath set to:
	/usr/share/fonts/X11/misc,
	/usr/share/fonts/X11/Type1,
	built-ins
[    29.528] (==) ModulePath set to "/usr/lib/xorg/modules"
[    29.528] (**) Extension "DPMS" is disabled
[    29.528] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[    29.528] (II) Loader magic: 0x55560c6c0ef0
[    29.528] (II) Module ABI versions:
[    29.528] 	X.Org ANSI C Emulation: 0.4
[    29.528] 	X.Org Video Driver: 25.2
[    29.528] 	X.Org XInput driver : 24.4
[    29.528] 	X.Org Server Extension : 10.0
[    29.529] (--) using VT number 2

[    29.529] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[    29.529] (II) xfree86: Adding drm device (/dev/dri/card0)
[    29.529] (II) Platform probe for /sys/devices/platform/axi/1002000000.v3d/drm/card0
[    29.529] (II) xfree86: Adding drm device (/dev/dri/card1)
[    29.529] (II) Platform probe for /sys/devices/platform/axi/axi:gpu/drm/card1
[    29.537] (II) no primary bus or device found
[    29.537] 	falling back to /sys/devices/platform/axi/1002000000.v3d/drm/card0
[    29.537] (II) LoadModule: "glx"
[    29.538] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[    29.571] (II) Module glx: vendor="X.Org Foundation"
[    29.571] 	compiled for 1.21.1.7, module version = 1.0.0
[    29.571] 	ABI class: X.Org Server Extension, version 10.0
[    29.571] (==) Matched modesetting as autoconfigured driver 0
[    29.571] (==) Matched fbdev as autoconfigured driver 1
[    29.571] (==) Assigned the driver to the xf86ConfigLayout
[    29.571] (II) LoadModule: "modesetting"
[    29.572] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[    29.581] (II) Module modesetting: vendor="X.Org Foundation"
[    29.581] 	compiled for 1.21.1.7, module version = 1.21.1
[    29.581] 	Module class: X.Org Video Driver
[    29.581] 	ABI class: X.Org Video Driver, version 25.2
[    29.583] (II) LoadModule: "fbdev"
[    29.583] (II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
[    29.584] (II) Module fbdev: vendor="X.Org Foundation"
[    29.584] 	compiled for 1.21.1.3, module version = 0.5.0
[    29.584] 	Module class: X.Org Video Driver
[    29.584] 	ABI class: X.Org Video Driver, version 25.2
[    29.584] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[    29.584] (II) FBDEV: driver for framebuffer: fbdev
[    29.588] (WW) Falling back to old probe method for modesetting
[    29.588] (WW) Falling back to old probe method for fbdev
[    29.588] (II) Loading sub module "fbdevhw"
[    29.588] (II) LoadModule: "fbdevhw"
[    29.589] (II) Loading /usr/lib/xorg/modules/libfbdevhw.so
[    29.591] (II) Module fbdevhw: vendor="X.Org Foundation"
[    29.591] 	compiled for 1.21.1.7, module version = 0.0.2
[    29.591] 	ABI class: X.Org Video Driver, version 25.2
[    29.591] (II) FBDEV(0): using default device
[    29.603] (II) modeset(G0): using drv /dev/dri/card1
[    29.603] (EE) 
Fatal server error:
[    29.603] (EE) Cannot run in framebuffer mode. Please specify busIDs        for all framebuffer devices
[    29.603] (EE) 
[    29.603] (EE) 
Please consult the The X.Org Foundation support 
	 at http://wiki.x.org
 for help. 
[    29.603] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[    29.603] (EE) 
[    29.672] (EE) Server terminated with error (1). Closing log file.

Adding /etc/X11/xorg.conf.d99-vc4.conf with the following content seems to solve the problem!

Section "OutputClass"
  Identifier "vc4"
  MatchDriver "vc4"
  Driver "modesetting"
  Option "PrimaryGPU" "true"
EndSection
1 Like

Weird that the default modesetting driver/config does not do this correctly OOTB. This seems to be the main issue:

[    28.534] (EE) No devices detected.

Switching to the other HDMI port does not help either? I’ll try to replicate it now on my RPi 5.

EDIT: Hmm, it worked here OOTB without KMS (hence framebuffer driver), but indeed with KMS/DRM, I get the same error.

Found the X11 config and explanation why it works: https://forums.raspberrypi.com/viewtopic.php?t=358853
I thought /dev/drm/card0 was the first HDMI port, and card1 the 2nd. But it is related to vc4 and v3d, and the config tells X11 to use whichever device is related to vc4. I’ll add this config to X11 installs on RPi 5 via dietpi-software.

EDIT2: And regarding HDMI audio, indeed I cannot get it to work either with the firmware driver. Even loading the snd_bcm2835 module manually does not help, so it seems to be simply not supported at all on RPi 5. I also recognised just now that it has no 3.5mm jack anymore, hence the firmware audio driver indeed mostly lost its purpose on this device.
Somehow related: https://forums.raspberrypi.com/viewtopic.php?t=359183

So we need to remove the analogue audio option on RPi 5 and use HDMI audio + enable KMS by default.

EDIT3: This should address both issues: v9.3 · MichaIng/DietPi@afe0074 · GitHub