USB4 Display Output During Boot

Hello all. I’m running Arch Linux on the Framework Desktop with /dev/nvme0n1p1 as my EFI System Partition (ESP) and /dev/nvme0n1p2 as my LUKS encrypted partition with / and /home btrfs subvolumes within. The bootloader is systemd-boot.

When I boot the machine with USB4 connected to my monitor I see the Framework logo and then I see the logs that prompt for my LUKS password for about 1-2 seconds and then the screen goes black and does not come back until I type in my correct LUKS password and the desktop environment boots. It seems almost as if the monitor and machine negotiated a different resolution that’s not being properly displayed.

I’ve tried disconnecting and reconnecting the USB4 cable and using different USB4 monitors to no avail. This issue does not occur when using HDMI.

I read [Answered] External displays not active during boot [12th Gen docked on Anker 777 TB4] - #7 by Matt_Hartley but that did not seem to have a conclusive answer relevant for the Framework Desktop.

Is anyone else experiencing this? Anyone resolve it?

Move amdgpu out of your initramfs, I suspect it will help this issue.

And if it doesnt; try to use the module parameter for thunderbolt.ko on your kernel command line to disable a reset at boot.

Thank you for the reply! I’m not super familiar with the configuration at this layer of the stack so I appreciate the help. Here’s what I did in response to your reply.

My /etc/mkinitcpio.conf looked like this originally.

MODULES=()
BINARIES=()
FILES=()
HOOKS=(base systemd autodetect microcode modconf kms keyboard sd-vconsole block sd-encrypt filesystems fsck)

I didn’t see anything related to amdgpu. Based on some AI research I removed kms from HOOKS, ran sudo mkinitcpio -P, and rebooted. The LUKS prompted no longer disappeared but when I entered my correct LUKS password and the system continued booting my USB4 monitor remained blank and did not show me my desktop environment.

diff --git a/etc/mkinitcpio.conf b/etc/mkinitcpio.conf
index ccad89a..51667c3 100644
--- a/etc/mkinitcpio.conf
+++ b/etc/mkinitcpio.conf
@@ -1,4 +1,4 @@
 MODULES=()
 BINARIES=()
 FILES=()
-HOOKS=(base systemd autodetect microcode modconf kms keyboard sd-vconsole block sd-encrypt filesystems fsck)
+HOOKS=(base systemd autodetect microcode modconf keyboard sd-vconsole block sd-encrypt filesystems fsck)

I then reverted that change and looked at the thunderbolt kernel parameters.

> modinfo thunderbolt | rg parm
parm:           clx:allow low power states on the high-speed lanes (default: true) (bool)
parm:           xdomain:allow XDomain protocol (default: true) (bool)
parm:           start_icm:start ICM firmware if it is not running (default: false) (bool)
parm:           dprx_timeout:DPRX capability read timeout in ms, -1 waits forever (default: 12000) (int)
parm:           dma_credits:specify custom credits for DMA tunnels (default: 14) (uint)
parm:           bw_alloc_mode:enable bandwidth allocation mode if supported (default: true) (bool)
parm:           asym_threshold:threshold (Mb/s) when to Gen 4 switch link symmetry. 0 disables. (default: 45000) (uint)
parm:           host_reset:reset USB4 host router (default: true) (bool)

I added thunderbolt.host_reset=false to my bootloader and rebooted. The LUKS prompt disappeared as initially described in this thread and when I entered the correct LUKS password I did not see the desktop environment on the USB4 monitor.

diff --git a/boot/loader/entries/arch.conf b/boot/loader/entries/arch.conf
index d61bc7f..abbc4cb 100644
--- a/boot/loader/entries/arch.conf
+++ b/boot/loader/entries/arch.conf
@@ -1,4 +1,4 @@
 title Arch Linux
 linux /vmlinuz-linux
 initrd /initramfs-linux.img
-options rd.luks.name=e7da534a-b0b8-4ae7-8f1d-7666d093cc15=root root=/dev/mapper/root zswap.enabled=0 rootflags=subvol=@ rw
+options rd.luks.name=e7da534a-b0b8-4ae7-8f1d-7666d093cc15=root root=/dev/mapper/root zswap.enabled=0 rootflags=subvol=@ thunderbolt.host_reset=false rw

I had a similar issue. What I ended up doing was loading the thunderbolt module in the MODULE=() hook.

e.g. MODULE=(somemodule_01 thunderbolt)

Then I did the whole mkinitcpio -P rigamarole and rebooted. I also found that setting thunderbolt.host_reset=false in conjunction removed some other cruft I was seeing a bit further down in the boot process.

I hope this helps.

MODULES=(thunderbolt) worked for me!

When I added thunderbolt.host_reset=false I experienced the same behavior described earlier.

2 Likes

Cool! Glad it worked out for you.

1 Like