Graphics glitches and artifacts with Ryzen 5 3400G APU

Same problems can be observed with Ubuntu 20.04 LTS / Ryzen 3 3200G / Gigabyte B450M S2H / 16GB (2x8GB) DDR4 3200.

Workaround 1:

Disable IOMMU in BIOS.

Workaround 2:

Add iommu=pt to command line in /etc/default/grub following the steps below.

  1. Run

    sudo nano /etc/default/grub
    
  2. Make the GRUB_CMDLINE_LINUX_DEFAULT line look like this

    GRUB_CMDLINE_LINUX_DEFAULT="quiet splash iommu=pt"
    
  3. Update grub by

    sudo update-grub
    
  4. Reboot with

    sudo reboot
    

Is there a third workaround ?

The prompt is displayed ok (same picture on both screen) Then my display is sliced horizontally Each slice is shifted

I disabled IOMMU in the bios, changed the grub conf Activated dual screen in bios too.

HDMI monitor on HDMI (full hd) VGA monitor on HDMI>VGA on a DP>HDMI passive adapter (1650x ???) This is not a hardware issue or bios setting issue as I have dual screen working

Fresh ubuntu 20.04 install with kernel 5.4

Found a 3rd workaround with this video https://www.youtube.com/watch?v=WWg8q_f7nI4


I'm currently using Ubuntu 20.10

While support for these devices has been in the kernel for a while, I've found I've had missing firmware when I see an update-initramfs. I also saw some AMDGPU-specific commits to upstream linux-firmware a little while ago, and tried the latest available deb package for Hirsute - it fixed all of my weird issues with the system, including requiring software IOMMU

YMMV, but try the 1.191 deb package under https://launchpad.net/ubuntu/+source/linux-firmware

Edit: step by step instructions as requested!

  1. Navigate to https://launchpad.net/ubuntu/+source/linux-firmware
  2. Expand the 1.191 arrow, under The Hirsute Hippo branch
  3. Download linux-firmware_1.191_all.deb
  4. Install the new firmware
    sudo apt install /path/to/linux-firmware_1.191_all.deb
  5. Reboot

Edit2: For reference, I have two AMD systems this really helped with. One is a Dell Inspiron 5585 w/ AMD Ryzen 3500U, the other is one I built with an AMD Ryzen 3400G.