View previous topic :: View next topic |
Author |
Message |
Fran Guru
Joined: 29 Feb 2004 Posts: 530 Location: Coruña (Spain)
|
Posted: Sat Jul 30, 2016 9:33 am Post subject: kernel 4.7.0 breaks pci passthrough [SOLVED] |
|
|
I'm getting these errors since updating the kernel:
qemu-system-x86_64: -device vfio-pci,host=01:00.0,multifunction=on,x-vga=on,romfile=/home/fran/sync/vm/Sapphire.R9270X.2048.131209.rom: Failed to add group 1 to KVM VFIO device: Invalid argument
qemu-system-x86_64: -device vfio-pci,host=00:1b.0: Failed to add group 7 to KVM VFIO device: Invalid argument
Has anyone tried pci passthrough with kernel 4.7.0? Did you have to change anything to make it work?
(edit) Solution below.
Last edited by Fran on Sat Aug 20, 2016 6:55 pm; edited 1 time in total |
|
Back to top |
|
|
Myu Apprentice
Joined: 22 Oct 2014 Posts: 164 Location: Belgium
|
Posted: Tue Aug 02, 2016 5:33 pm Post subject: |
|
|
Not yet, that's interesting to know, I will give it a try when I get the chance, right now it works fine with 4.6.5 _________________ Gentoo stable with bits of ~amd64 // Xfce 4.13 + Compiz Reloaded. |
|
Back to top |
|
|
Myu Apprentice
Joined: 22 Oct 2014 Posts: 164 Location: Belgium
|
Posted: Fri Aug 05, 2016 3:17 pm Post subject: |
|
|
It still works for me with 4.7.0 but I'm not passing a UEFI bios ROM for my card like you do so that may be an hint... _________________ Gentoo stable with bits of ~amd64 // Xfce 4.13 + Compiz Reloaded. |
|
Back to top |
|
|
Fran Guru
Joined: 29 Feb 2004 Posts: 530 Location: Coruña (Spain)
|
Posted: Sat Aug 06, 2016 2:32 pm Post subject: |
|
|
Crap. Tried with other options and still doesn't work.
I hope I'm not the only one... don't want to get stuck in 4.6 forever. |
|
Back to top |
|
|
zino n00b
Joined: 14 Jan 2016 Posts: 21 Location: Switzerland
|
Posted: Sat Aug 20, 2016 5:22 pm Post subject: |
|
|
@Fran. Have you by any chance set
Code: | CONFIG_TRIM_UNUSED_KSYMS=y |
in you kernel config? If so, try to unset it and recompile your kernel (and reboot, of course). I've just tested this with hardened-sources-4.7.1 and this newly introduced kernel option seems to actually cause the issues you mentioned. |
|
Back to top |
|
|
Buffoon Veteran
Joined: 17 Jun 2015 Posts: 1369 Location: EU or US
|
Posted: Sat Aug 20, 2016 5:50 pm Post subject: |
|
|
I think this kernel option is safe only if you have no out of kernel modules. |
|
Back to top |
|
|
Fran Guru
Joined: 29 Feb 2004 Posts: 530 Location: Coruña (Spain)
|
Posted: Sat Aug 20, 2016 6:54 pm Post subject: |
|
|
zino wrote: | @Fran. Have you by any chance set
Code: | CONFIG_TRIM_UNUSED_KSYMS=y |
in you kernel config? If so, try to unset it and recompile your kernel (and reboot, of course). I've just tested this with hardened-sources-4.7.1 and this newly introduced kernel option seems to actually cause the issues you mentioned. |
THANK YOU! Setting it to =n makes pci passthrough work again with 4.7.1 (and with 4.8-rc2).
I didn't think it could affect qemu, since kvm is part of the kernel and by the description of the option it looked as if only out-of-kernel modules could be affected (I don't have any so I set it to =y). |
|
Back to top |
|
|
|