All of lore.kernel.org
 help / color / mirror / Atom feed
* AMD integrated graphics passthrough to KVM guest
@ 2013-07-12 14:48 Gustav Sorenson
  2013-07-12 15:54 ` Alex Williamson
  0 siblings, 1 reply; 9+ messages in thread
From: Gustav Sorenson @ 2013-07-12 14:48 UTC (permalink / raw)
  To: kvm

Hello list,

I hope this is the right place for my question. If it is not, I'd be
very happy if you pointed me in the right direction.

I have an AMD A10 6800K APU with integrated graphics and I'm trying to
pass that graphics adapter to a KVM guest.
My mainboard is an ASRock FM2A75 Pro4 with latest firmware, so that it
(supposedly) supports IOMMU.

Since this is the first time I'm attempting this, I followed this
guide: https://bbs.archlinux.org/viewtopic.php?id=162768

I'm running Debian wheezy amd64, mainline kernel 3.10 with the
kernel-vfio-vga-reset patch mentioned in the link above, and qemu
1.5.1 with a corresponding patch (again, see link above.)
Kernel config options I set that I assume are relevant:
CONFIG_VFIO_IOMMU_TYPE1=y
CONFIG_VFIO=y
CONFIG_VFIO_PCI=y
CONFIG_VFIO_PCI_VGA=y

When I run

qemu-system-x86_64 -enable-kvm -M q35 -m 1024 -cpu host -smp
2,sockets=1,cores=2,threads=1 -bios /home/gustav/myroot/bios.bin -vga
none -device ioh3420,bus=pcie.0,addr=1c.0,multifunction=on,port=1,chassis=1,id=root.1
-device vfio-pci,host=00:01.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on
-device vfio-pci,host=00:01.1,bus=root.1,addr=00.1

I receive the message

qemu-system-x86_64: Attempt to reset PCI bus for VGA support failed
(Device or resource busy).  VGA may not work.

Indeed the display output doesn't change, i.e. the login promt (on the
console, there is no X installed) of the host doesn't vanish, and I
don't get SeaBIOS output from the KVM guest.

Next, I took a really old PCIe graphics card, installed it and set it
to be my primary graphics adapter in BIOS (or rather UEFI?), so that I
now saw POST and kernel messages via the dedicated GPU. Surprisingly
to me, I was able to pass-through the dedicated PCIe card to a KVM
guest, but still not the now supposedly unused integrated GPU, still
getting the same message when I tried.
After changing the primary graphics adapter to be the integrated one,
I still wasn't able to pass through the integrated GPU, but was able
to see SeaBIOS output if I passed the dedicated card to the guest.
However in this case, the graphics output was a bit strange in that
the space bewteen characters and lines was unusually large and I saw
only what seemed to be part of the whole screen output.

Since my integrated GPU is more powerful than the dedicated one, I'd
like to know what I can try to pass it to a guest, or what I can do to
find out why "Device or resource busy" is reported.
Please let me know if you need any more data. Also please note that
the computer is not in any kind of "production" use, so it wouldn't be
a problem if some operation resulted in an unusable operating system,
as long as there is no hardware damage.

Any input is very highly appreciated.
Thanks!

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2013-07-15  3:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-12 14:48 AMD integrated graphics passthrough to KVM guest Gustav Sorenson
2013-07-12 15:54 ` Alex Williamson
2013-07-12 16:13   ` Gustav Sorenson
2013-07-12 16:33     ` Alex Williamson
2013-07-12 18:18       ` Gustav Sorenson
2013-07-12 20:01         ` Alex Williamson
2013-07-12 22:26           ` Gustav Sorenson
2013-07-13 19:45           ` Gustav Sorenson
2013-07-15  3:21             ` Alex Williamson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.