Windows 7 (or 8) with GPU passthru on KVM


Recommended Posts

I'm still using my XEN image for Windows 8, but as part of trying to get it working on beta6, it got jacked up and I'm having to reinstall all my programs.  in addition, it turns out the company I bought my license from sold me a 'fake/stolen/jacked' license, and Microsoft revoked it.  I got a refund, but really only bought windows8 to get GPU passthru working, since everyone said it just won't work with Windows7 on XEN.

 

But, now we have KVM, so, the question becomes, does anyone have GPU pass thru (specifically iGPU passthru) working with Windows7, or should I just buy another windows8 license and go that route?

 

Either way I go, I plan to start from scratch with a QCOW2 image, to take advantage of the 'auto-growing' feature.  Does anyone have a guide, or tips on setting this up from scratch in KVM?

 

Thanks in advance for any help.

Link to comment

1. Windows 7 does work in Xen. People in the unRAID community couldn't do it because of the Linux Kernel, Xen and missing patches to both.

 

2. You will need to wait till the next beta version of unRAID if you are trying to do iGPU in KVM. They are missing a few patches that were not included in the last release.

Link to comment
  • 4 months later...

Any idea what the current hangups are?  I looked in my lspci and could find the intel audio device but not the video device.  It's possible that I just need to make sure that the setting is set in the bios for it to run the igpu even when a discrete gpu is detected.

 

Is it that it's too difficult to identify the iGPU, or when you set it to passthrough, it just doesn't work, or doesn't sustain through reboots?

Link to comment

I've personally not tried since XEN was our only option.  However, jonp said he's tried many different things, including compiling the kernel with various options, and trying to work directly with the guy making changes in the Linux kernel to get it working.

 

I'm not sure what success he's had, but it sounds like not very much.

 

With that said, I'll probably give it a try one of these days myself.  my iGPU and onboard HDMI are both recognized just fine, so it's just a matter of plugging in the numbers to see what happens.

Link to comment

I gave it a shot tonight, and this is the error that VMman gave me:

 

message: Error while starting domain: internal error: early end of file from monitor: possible problem: 2014-11-15T13:24:01.932705Z qemu-system-x86_64: -device vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on: vfio: failed to set iommu for container: Operation not permitted 2014-11-15T13:24:01.932720Z qemu-system-x86_64: -device vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on: vfio: failed to setup container for group 2 2014-11-15T13:24:01.932725Z qemu-system-x86_64: -device vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on: vfio: failed to get group 2 2014-11-15T13:24:01.932732Z qemu-system-x86_64: -device vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on: Device initialization failed. 2014-11-15T13:24:01.932738Z qemu-system-x86_64: -device vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on: Device 'vfio-pci' could not be initialized

 

I had simply changed my working xml with the following hardware passthrough:

  <qemu:commandline>
    <qemu:arg value='-device'/>
    <qemu:arg value='ioh3420,bus=pcie.0,addr=1c.0,multifunction=on,port=1,chassis=1,id=root.1'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='vfio-pci,host=01:00.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='vfio-pci,host=01:00.1,bus=pcie.0'/>
  </qemu:commandline>

to

  <qemu:commandline>
    <qemu:arg value='-device'/>
    <qemu:arg value='ioh3420,bus=pcie.0,addr=1c.0,multifunction=on,port=1,chassis=1,id=root.1'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='vfio-pci,host=00:02.0,bus=root.1,addr=00.0,multifunction=on,x-vga=on'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='vfio-pci,host=00:03.0,bus=pcie.0'/>
  </qemu:commandline>

 

My lspci -knn pertinent part is:

00:02.0 Display controller [0380]: Intel Corporation Haswell Integrated Graphics Controller [8086:0412] (rev 06)
        Subsystem: ASRock Incorporation Device [1849:0412]
        Kernel driver in use: vfio-pci
00:03.0 Audio device [0403]: Intel Corporation Haswell HD Audio Controller [8086:0c0c] (rev 06)
        Subsystem: ASRock Incorporation Device [1849:0c0c]
        Kernel driver in use: vfio-pci
01:00.0 VGA compatible controller [0300]: AMD/ATI [Advanced Micro Devices, Inc.] Cape Verde XT [Radeon HD 7770 GHz Edition] [1002:683d]
        Subsystem: PC Partner Limited Device [174b:e244]
        Kernel driver in use: vfio-pci
01:00.1 Audio device [0403]: AMD/ATI [Advanced Micro Devices, Inc.] Cape Verde/Pitcairn HDMI Audio [Radeon HD 7700/7800 Series] [1002:aab0]
        Subsystem: PC Partner Limited Device [174b:aab0]
        Kernel driver in use: vfio-pci

 

My guess is that it has something to do because it's not actually within a PCI lane, hence binding it to vfio-pci driver isn't going to get it to work right.

 

Anyway, thought I'd post my results in case it helps anyone else crack the elusive iGPU passthrough.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.