[RESOLVED] 7640U, Linux, Can't drive 4k60 over USB-C dock because DSC is not working

OS:

  • Linux (Gentoo)
  • Linux (Fedora)

Release:

  • Gentoo: 2023-11-19 minimal install CD, current running system (Gentoo kernel 6.1.57)
  • Fedora: 39 live CD

(Relevant) hardware:
7640 Laptop 13 motherboard
Anker A8380 USB-C dock (HDMI, USB-A, Ethernet)
Crucial 2x16 CT2K16G56C46S5
55W Battery
USB-C PD power direct to motherboard (Ecoflow River 2)

(Less relevant) hardware:
Western Digital 1TB SN850X
USB stereo DAC (off Anker A8380)
USB HUB (off Anker A8380)
USB mouse, keyboard, Blue Yeti (off USB HUB)

Hey folks,

I have an Anker A8380 USB-C dock that I’m using to interface my 7640U motherboard to the rest of my workstation setup.

The A8380 has two HDMI ports, and exposes itself to the system as a DisplayPort multi-stream transport (MST) device, that supports Display Stream Compression (DSC).

I know that both the dock itself and the TV it’s connected to can operate correctly in the 4k/60Hz configuration, using Windows 11 on a Surface Laptop 4 – but only when the Intel drivers on the Surface Laptop 4 are forced to enable DSC. If DSC is not forced on, the Surface Laptop 4 will only drive the combination at 4k/30Hz.

Under Linux – both my native Gentoo install and the Fedora 39 live CD – I’m only seeing a 30Hz option. The dmesg output in both places implies that DSC is not being engaged.

I have taken a brief look at the amdgpu kernel source that surrounds a dmesg log entry that suggests register access to the graphics subsystem is timing out, but disabling clock gating, and then clock gating + DPM (dynamic power management) both, resulted in a non-booting system.

It seems like the 760M should support DSC at a hardware level, but I can also see this feature getting overlooked by accident on a “normal” Framework 13 configuration on the software side. I suspect that, this being relatively new graphics hardware, that the fine details/gotchas/corner-cases in the kernel driver for this specific graphics subsystem haven’t been fully ironed out yet, and this “just” needs to be looked at and fixed.

For reference, the relevant part of the dmesg spew is:

[    2.463172] [drm] amdgpu kernel modesetting enabled.
[    2.466073] amdgpu 0000:c0:00.0: enabling device (0006 -> 0007)
[    2.466119] [drm] initializing kernel modesetting (IP DISCOVERY 0x1002:0x15BF 0xF111:0x0006 0xCB).
[    2.466125] [drm] register mmio base: 0x90500000
[    2.466126] [drm] register mmio size: 524288
[    2.467798] [drm] add ip block number 0 <soc21_common>
[    2.467799] [drm] add ip block number 1 <gmc_v11_0>
[    2.467800] [drm] add ip block number 2 <ih_v6_0>
[    2.467801] [drm] add ip block number 3 <psp>
[    2.467802] [drm] add ip block number 4 <smu>
[    2.467803] [drm] add ip block number 5 <dm>
[    2.467804] [drm] add ip block number 6 <gfx_v11_0>
[    2.467805] [drm] add ip block number 7 <sdma_v6_0>
[    2.467806] [drm] add ip block number 8 <vcn_v4_0>
[    2.467806] [drm] add ip block number 9 <jpeg_v4_0>
[    2.467807] [drm] add ip block number 10 <mes_v11_0>
[    2.467820] amdgpu 0000:c0:00.0: amdgpu: Fetched VBIOS from VFCT
[    2.467821] amdgpu: ATOM BIOS: 113-PHXGENERIC-001
[    2.467827] [drm] VCN(0) encode/decode are enabled in VM mode
[    2.467828] amdgpu 0000:c0:00.0: [drm:jpeg_v4_0_early_init] JPEG decode is enabled in VM mode
[    2.467835] Loading firmware: amdgpu/gc_11_0_1_mes_2.bin
[    2.467863] Loading firmware: amdgpu/gc_11_0_1_mes1.bin
[    2.467886] amdgpu 0000:c0:00.0: amdgpu: Trusted Memory Zone (TMZ) feature enabled
[    2.467922] [drm] vm size is 262144 GB, 4 levels, block size is 9-bit, fragment size is 9-bit
[    2.467942] amdgpu 0000:c0:00.0: amdgpu: VRAM: 512M 0x0000008000000000 - 0x000000801FFFFFFF (512M used)
[    2.467944] amdgpu 0000:c0:00.0: amdgpu: GART: 512M 0x0000000000000000 - 0x000000001FFFFFFF
[    2.467957] [drm] Detected VRAM RAM=512M, BAR=512M
[    2.467957] [drm] RAM width 128bits DDR5
[    2.467982] [drm] amdgpu: 512M of VRAM memory ready
[    2.467983] [drm] amdgpu: 15416M of GTT memory ready.
[    2.467989] [drm] GART: num cpu pages 131072, num gpu pages 131072
[    2.468464] [drm] PCIE GART of 512M enabled (table at 0x000000801FD00000).
[    2.468565] Loading firmware: amdgpu/psp_13_0_4_toc.bin
[    2.468574] Loading firmware: amdgpu/psp_13_0_4_ta.bin
[    2.468614] amdgpu 0000:c0:00.0: amdgpu: PSP runtime database doesn't exist
[    2.468616] amdgpu 0000:c0:00.0: amdgpu: PSP runtime database doesn't exist
[    2.468669] Loading firmware: amdgpu/dcn_3_1_4_dmcub.bin
[    2.468723] [drm] Loading DMUB firmware via PSP: version=0x08002300
[    2.468730] Loading firmware: amdgpu/gc_11_0_1_imu.bin
[    2.468759] Loading firmware: amdgpu/gc_11_0_1_pfp.bin
[    2.468806] Loading firmware: amdgpu/gc_11_0_1_me.bin
[    2.468856] Loading firmware: amdgpu/gc_11_0_1_rlc.bin
[    2.468891] Loading firmware: amdgpu/gc_11_0_1_mec.bin
[    2.469481] Loading firmware: amdgpu/sdma_6_0_1.bin
[    2.469520] Loading firmware: amdgpu/vcn_4_0_2.bin
[    2.469581] [drm] Found VCN firmware Version ENC: 1.10 DEC: 5 VEP: 0 Revision: 0
[    2.469586] amdgpu 0000:c0:00.0: amdgpu: Will use PSP to load VCN firmware
[    2.469701] [drm] max_doorbell_slices=255
[    2.494014] [drm] reserve 0x4000000 from 0x8018000000 for PSP TMR
[    3.011015] amdgpu 0000:c0:00.0: amdgpu: RAS: optional ras ta ucode is not available
[    3.019424] amdgpu 0000:c0:00.0: amdgpu: RAP: optional rap ta ucode is not available
[    3.019428] amdgpu 0000:c0:00.0: amdgpu: SECUREDISPLAY: securedisplay ta ucode is not available
[    3.050908] amdgpu 0000:c0:00.0: amdgpu: SMU is initialized successfully!
[    3.051977] [drm] Display Core initialized with v3.2.207!
[    3.054307] [drm] DMUB hardware initialized: version=0x08002300
[    3.414992] [drm] dce110_edp_wait_for_hpd_ready: wait timed out!
[    3.483311] [drm] REG_WAIT timeout 1us * 1000 tries - dcn314_dsc_pg_control line:266
[    3.485599] [drm] REG_WAIT timeout 1us * 1000 tries - dcn314_dsc_pg_control line:274
[    3.487887] [drm] REG_WAIT timeout 1us * 1000 tries - dcn314_dsc_pg_control line:282
[    3.490174] [drm] REG_WAIT timeout 1us * 1000 tries - dcn314_dsc_pg_control line:290
[    3.852996] [drm] dce110_edp_wait_for_hpd_ready: wait timed out!
[    4.212951] [drm] dce110_edp_wait_for_hpd_ready: wait timed out!
[    4.213257] [drm] DP Alt mode state on HPD: 1
[    4.277192] [drm] DM_MST: Differing MST start on aconnector: (____ptrval____) [id: 91]
[    4.278310] [drm] kiq ring mec 3 pipe 1 q 0
[    4.280857] [drm] VCN decode and encode initialized successfully(under DPG Mode).
[    4.280888] amdgpu 0000:c0:00.0: [drm:jpeg_v4_0_hw_init] JPEG decode initialized successfully.
[    4.282434] amdgpu 0000:c0:00.0: amdgpu: SE 1, SH per SE 2, CU per SH 6, active_cu_number 8
[    4.282474] amdgpu 0000:c0:00.0: amdgpu: ring gfx_0.0.0 uses VM inv eng 0 on hub 0
[    4.282476] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.0.0 uses VM inv eng 1 on hub 0
[    4.282477] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.1.0 uses VM inv eng 4 on hub 0
[    4.282479] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.2.0 uses VM inv eng 6 on hub 0
[    4.282480] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.3.0 uses VM inv eng 7 on hub 0
[    4.282481] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.0.1 uses VM inv eng 8 on hub 0
[    4.282481] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.1.1 uses VM inv eng 9 on hub 0
[    4.282482] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.2.1 uses VM inv eng 10 on hub 0
[    4.282483] amdgpu 0000:c0:00.0: amdgpu: ring comp_1.3.1 uses VM inv eng 11 on hub 0
[    4.282484] amdgpu 0000:c0:00.0: amdgpu: ring sdma0 uses VM inv eng 12 on hub 0
[    4.282485] amdgpu 0000:c0:00.0: amdgpu: ring vcn_unified_0 uses VM inv eng 0 on hub 1
[    4.282486] amdgpu 0000:c0:00.0: amdgpu: ring jpeg_dec uses VM inv eng 1 on hub 1
[    4.282487] amdgpu 0000:c0:00.0: amdgpu: ring mes_kiq_3.1.0 uses VM inv eng 13 on hub 0
[    4.287916] [drm] ring gfx_32768.1.1 was added
[    4.288522] [drm] ring compute_32768.2.2 was added
[    4.289047] [drm] ring sdma_32768.3.3 was added
[    4.289070] [drm] ring gfx_32768.1.1 test pass
[    4.289122] [drm] ring gfx_32768.1.1 ib test pass
[    4.289133] [drm] ring compute_32768.2.2 test pass
[    4.289190] [drm] ring compute_32768.2.2 ib test pass
[    4.289203] [drm] ring sdma_32768.3.3 test pass
[    4.289256] [drm] ring sdma_32768.3.3 ib test pass
[    4.290538] [drm] Initialized amdgpu 3.49.0 20150101 for 0000:c0:00.0 on minor 0
[    4.292373] amdgpu 0000:c0:00.0: [drm] Cannot find any crtc or sizes
[    4.292381] [drm] DSC precompute is not needed.

Has anyone else got a counterexample of DSC working? (What about over MST?)

PEBKAC.

Upon reviewing the EDID information for my monitor, 4k @ 60Hz was not being offered – somehow, my TV had left “game mode,” which is a requirement for it to operate at the correct frequency. [Edit: it appears that the TV automatically exits this mode every time it detects it is unplugged from a source – which, naturally, occurred when I moved it off my old, working setup, to this new one.]

After changing modes, the TV started supplying an EDID that listed a 4k @ 60Hz entry, and xrandr was able to take it from there.

2 Likes

I had a few PEBKAC moments over the weekend, no worries. :slight_smile:

Glad this is resolved.