Graphics not working on Ryzen 2400g ubuntu 18.04.2

System specs:
-ASRock Fatal1ty B450 Gaming-ITX/ac motherboard. latest bios (3.3)
-2x8gb Crucial Ballistix Sport LT 8GB DDR4-3200 PC4-25600 ram BLS8G4D32AESBK
-ryzen 2400g

Distros tried:
-19.04
-18.04.2

Question:
How do you properly install amd graphics drivers for ubuntu 18.04.2 on a raven ridge system? Do I install AMDGPU 19.20 first, then MESA, then x.org xf86 driver? Do I need some specific patch? Do I need to bother with a kernel upgrade?

Backstory:
I purchased this setup on Sunday from microcenter. All new, no openbox. I’ve been tinkering with it for a good number of hours and I have not been able to get the graphics working soundly yet.

I first tried ubuntu 19.04. The screen defaulted to 640x480 graphics and I could not change the resolution. I tried installing the “AMDGPU” graphics and it made the machine black screen on reboot and it wouldn’t come back after that. I later found out that AMDGPU driver does not work at all on 19.04, so I switched to 18.04.2

18.04.2 worked right out of the box and everything seemed normal. general use was pretty fluid, and the machine booted and operated normally. However, after mildly stressing the machine with basic games from the ubuntu store, there was visual scrolling horizontal line tearing while playing extreme tux racer. I tried Open arena and it would immediately quit and error when I tried setting up a skermish.

I then used ukuu to upgrade to the latest kernel (5.1.6) and installed the AMDGPU-PRO driver, but this caused a black screen on reboot. I reinstalled 18.04.2 and tried kernel 5.0, same results.

I reinstalled 18.04.2 and stuck with the native kernel 4.18 from here on in.

After a bit of research it turns out there are a whole slew of amd graphics drivers for linux. I found a good explanation here:

I went ahead and installed the latest MESA and the xf86 driver from xorg. This was definitely an improvement over stock 18.04.2 drivers and there was no more horizontal scrolling line tearing in extreme tux racer. Open arena is still broken though.
I went ahead and installed the 19.20 radeon drivers. I verified the driver install via terminal it checked out. However, the AMDGPU driver made the graphics situation significantly worse, and created horrific line tearing on even a simple window drag. Also, ubuntu x no longer worked, and ubuntu wayland was the only functioning gui environment.

At this point, more than a year after raven ridge was released, I really expected significant issues to be ironed out. There doesn’t seem to be a consistent solution for the raven ridge platform on linux.
Some folks have got this to work though. I’m still amazed how Michael at phoronix was able to setup a similar machine and stress test it under openarena. I have absolutely no idea how he pulled it off, but for the life of me I can not replicate his results.

https://www.phoronix.com/scan.php?page=article&item=ryzen-2400g-may&num=1

If anyone has any input, I would be all ears.

Thanks a ton!

Have you tried upgrading your kernel to latest version? 2400G is still relatively new and require a 5.0+ kernel IIRC. Might be wrong.

Other than that it should work out of the box.

https://www.tecmint.com/upgrade-kernel-in-ubuntu/

Thanks for the input! I tried the latest kernel and installed it using ukuu. It forces the machine into 640x480 mode. I ran “xrandr” and it only allowed for 640x480 mode. I tried to install the amd microcode from /~agd5f/radeon_ucode/ and it did not fix the problem. I detailed my problem as well here:

At this point im running 18.04.2 with native 4.18 kernel with mesa and amdgpu included driver. It still picks it up as vega 8 graphics, not vega11. I have my 1920x1200 resolution back with 4.18 and there do not seem to be any line tearing or graphical glitches.
It is mostly stable, and seems to be working ok, but there are random lockups once every day or every other day. I have not been able to resolve these. There is a very good chance that I will be returning this 2400g system as support doesnt look anywhere near close to being finished.

*Note: I found out that open arena has not worked properly out of the box since ubuntu 16.04, so this is not an exclusive AMD ryzen g problem at all.

Unfortunately I have yet to acquire a 2400G myself, but another thing you could try is Manjaro (which is based on Arch, only more newbie friendly): https://www.reddit.com/r/archlinux/comments/9duc0n/arch_on_raven_ridge_ryzen_5_2400g/

Support I think should be pretty good nowadays, but you do need the latest kernel (4.19+).