Just finished building Ryzen system. Kernel panic whenever Iommu is enabled in bios

Notable parts:
Ryzen 5 1600
asrock ab350m bios version 3.30 (latest)
intel wifi card in top 1x slot
gtx 1070 in top x16 slot
rx 580 in bottom x16/x4 slot

so finished this build yesterday I’m up and running OpenSUSE TW kernel 4.14
I built the system with the intention of it being used in a vfio setup so that I could let people play vr games in windows while i used my computer for other low spec games in linux. right now any time i enable iommu in the bios I get a kernel panic
pictures of panic
i’ve tried amd_iommu=on amd_iommu=pt, and amd_iommu=fullflush all get the same result as nothing in the boot parameters. I’ve also tried booting xubuntu 17.10 and antergos live and both have the same kernel panic.

The AHCI driver is on top of the stack when it panics. Can you boot it without a drive off USB to see if it happens again? Move the drive to a separate controller?

From a 10 second google looks like SATA3_3 is connected to the chipset. Move it to/from there and see how you go.

Thanks for the tip. I moved the drive to either port 1 or 2 still getting kernel panics but they are new ones.

I tried a good bit of google before I posted but didn’t and still don’t know what I should be looking at in the outputs.

I would appreciate a link to where you found that thing about the data ports

im not sure totally about your board, nor where your drives are located, but on my board one m.2 drive and the last pcie 16 slot can not be used at the same time. Maybe move the rx480 just for kicks?

alright so I stripped the system down to just the ssd with linux and the 580. result was still kernel panic.
but then I moved the 580 to the top slot. that results in successful boot. the issue now is that the 1070 can’t go in the bottom slot because the cooler gets in the way of the power,reset, and audio pins for the front panel.

nvm I was able to put the 1070 in the bottom port

Ok so while that fixed the kernel panic it winds up putting the 580 in the wrong iommu group to be the host from what I can tell https://pastebin.com/bUJiyD0x

ok so no panic with nvidia card in either slot? and panic when radeon card in bottom slot only? Do you have another video card laying around? Maybe you can borrow one and seat it where the radeon was? I am just wondering if its the 580 that has issues somewhere. Another video card will debunk this.

Rather than try to chase down an obscure kernel panic, I’m just going to do the ACS patch and keep the GPUs in the configuration that doesn’t have a panic

so I finally actually got this properly resolved. the issue is that for some reason you have to pass the option iommu=pt at boot to avoid this kernel panic. I had seen this suggestion before but had misread it as amd_iommu=pt which does not fix the panic.

edit: I should also note. from my research this issue seems to specifically happen when a GCN gpu is plugged into the chipset pcie slot on a b350 motherboard

3 Likes