Full 3D gaming in virtual machine

Page 2 - Seeking answers? Join the Tom's Hardware community: where nearly two million members share solutions and discuss the latest tech.
Status
Not open for further replies.
Here are my onboard devices show with lspci -nn:

00:00.0 Host bridge [0600]: Intel Corporation 2nd Generation Core Processor Family DRAM Controller [8086:0100] (rev 09)
00:01.0 PCI bridge [0604]: Intel Corporation Xeon E3-1200/2nd Generation Core Processor Family PCI Express Root Port [8086:0101] (rev 09)
00:02.0 VGA compatible controller [0300]: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller [8086:0102] (rev 09)
00:16.0 Communication controller [0780]: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #1 [8086:1c3a] (rev 04)
00:1a.0 USB controller [0c03]: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #2 [8086:1c2d] (rev 05)
00:1c.0 PCI bridge [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 [8086:1c10] (rev b5)
00:1c.7 PCI bridge [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 8 [8086:1c1e] (rev b5)
00:1d.0 USB controller [0c03]: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #1 [8086:1c26] (rev 05)
00:1f.0 ISA bridge [0601]: Intel Corporation Z68 Express Chipset Family LPC Controller [8086:1c44] (rev 05)
00:1f.2 SATA controller [0106]: Intel Corporation 6 Series/C200 Series Chipset Family 6 port SATA AHCI Controller [8086:1c02] (rev 05)
00:1f.3 SMBus [0c05]: Intel Corporation 6 Series/C200 Series Chipset Family SMBus Controller [8086:1c22] (rev 05)

I am exporting 00:1a.0, ID 8086:1c2d.
I suppose the ID should be the same for you, since it's same chipset, same manufacturer just different BIOS.
And about the X-Fi, I had similar issues with "native" drivers. But it seems it's installed with some generic HDA drivers by default (I don't remember if it asked me to update over the net). What is most surprising is that in linux it's ID is 1102:000B (and also with the Creative drivers), but with this emulation it's 1102:000D. I have no idea how to switch between them. But maybe this can be done only under 7. Again showing how lucky I was 😀.
 


I'm trying to forward my ASMedia USB 3.0 controller, but I get this during the process:
# echo "0000:0a:00.0" > /sys/bus/pci/drivers/pci-stub/bind
bash: echo: write error: No such device

This is my lspci:
00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200/2nd Generation Core Processor Family PCI Express Root Port (rev 09)
00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)
00:16.0 Communication controller: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #1 (rev 04)
00:1a.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #2 (rev 05)
00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller (rev 05)
00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5)
00:1c.4 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 5 (rev b5)
00:1c.6 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 7 (rev b5)
00:1c.7 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 8 (rev b5)
00:1d.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #1 (rev 05)
00:1f.0 ISA bridge: Intel Corporation Z68 Express Chipset Family LPC Controller (rev 05)
00:1f.2 SATA controller: Intel Corporation 6 Series/C200 Series Chipset Family 6 port SATA AHCI Controller (rev 05)
00:1f.3 SMBus: Intel Corporation 6 Series/C200 Series Chipset Family SMBus Controller (rev 05)
01:00.0 VGA compatible controller: ATI Technologies Inc Cypress [Radeon HD 5800 Series]
01:00.1 Audio device: ATI Technologies Inc Cypress HDMI Audio [Radeon HD 5800 Series]
03:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 01)
04:00.0 USB controller: ASMedia Technology Inc. ASM1042 SuperSpeed USB Host Controller
05:00.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:01.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:04.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:05.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:06.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:07.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:08.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
06:09.0 PCI bridge: PLX Technology, Inc. PEX 8608 8-lane, 8-Port PCI Express Gen 2 (5.0 GT/s) Switch (rev ba)
07:00.0 USB controller: ASMedia Technology Inc. ASM1042 SuperSpeed USB Host Controller
08:00.0 PCI bridge: ASMedia Technology Inc. ASM108x PCIe to PCI Bridge Controller (rev 03)
09:01.0 Multimedia audio controller: Creative Labs SB X-Fi
0a:00.0 USB controller: ASMedia Technology Inc. ASM1042 SuperSpeed USB Host Controller
0b:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 06)
0c:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 01)
0d:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 06)
0e:00.0 FireWire (IEEE 1394): VIA Technologies, Inc. VT6315 Series Firewire Controller
0e:00.1 IDE interface: VIA Technologies, Inc. VT6415 PATA IDE Host Controller (rev a0)

This is the very same process that I've been using earlier to forward my Radeon and X-Fi cards, without a hitch.
The same error happens when I try to use the controller you use (yes, we really have the same ID and bus).

Google only turned up people trying to use the wrong address and a few who didn't have VT-d but tried anyway.
 
Never mind, I solved it by switching to pciback instead of pci-stub, as recommended by the Xen wiki.

One odd thing I noticed is that when I move my new Razer Lachesis (5600 DPI version) a lot, it drops out for a split second before resetting.
This doesn't happen in Debian though, so I guess it's because of the ASMedia USB controller drivers.
I swapped it with my Razer Diamondback and all is great.

The USB sound card I bought (Deltaco UAC-03, cheap thing) works right away with generic drivers.
No clicks and pops, no crashing, just a bit of distortion sometimes but hardly noticeable in most games.
 
Small status update, I have managed to solve pretty much every issue by now, here's how:

Razer Lachesis:
Install drivers from official website and turn down the polling rate to 125Hz (might be optional), then plug it into a powered hub.
It now works like a wonder.

Logitech G25:
Very picky about installation method, install drivers and when prompted to plug it in during install, connect directly to the motherboard.
I had a few attempts trying to get this to work, most of the time it would end up "locked" to a 200 degrees range, if working at all.
I've read about similar experiences on bare metal Windows Vista, so might not be relevant for 7.

Deltaco UAC-03:
Glitchy audio in some games, possibly related to CPU usage (would make sense).
Music in VLC is crystal clear (to the extent you can call a cheap USB sound card crystal clear, works well enough at least).

And finally a heads-up; the ASMedia USB 3.0 controller does not work with the generic drivers, trying to do so will cause minor headaches.
Don't try it.
Seriously, don't.

Again, I'd recommend any Linux user to give this a shot, the reward is really worth it. :bounce:
 
Hello,

I just bought a new computer with the same goal: play with xen and the VGA passthrough. However I discovered too late that not all motherboard support vt-d. I asked gigabyte for a compatible BIOS and I am waiting for it. In the same time I am planning to buy an already compatible MB.

Is the Asrock z68 extreme3 gen 3 compatible or should I buy the extreme4 gen 3?
 
Hello,

I just bought a new computer with the same goal: play with xen and the VGA passthrough. However I discovered too late that not all motherboard support vt-d. I asked gigabyte for a compatible BIOS and I am waiting for it. In the same time I am planning to buy an already compatible MB.

Is the Asrock z68 extreme3 gen 3 compatible or should I buy the extreme4 gen 3?

Ouch, sorry to hear that.

As for the new mobo, I'd go with the Extreme4 Gen3 as it's been verified to work, not sure about the Extreme3 Gen3. There's a good chance it will work, but I wouldn't buy it without verified VT-d functionality.

Have a look at the ESXi forums, they have a whole section for reporting working mobos (you might even find the BIOS you're looking for in there).
 


Synergy works fine for UAC if you install the client as a windows service. Just pop an administrator console and run: [fixed]synergyc --service install --relaunch name_or_ip_of_your_server[/fixed]

Just don't forget to remove your normal client from autostart ;-). If it doesn't work, check under services.msc the properties of the Synergy service - it needs to run as the system user, with allowed access to the desktop. You may also want to edit your registry to allow the service to run in the Safe Mode with Network.
 


I'm a bit of a Linux noob so forgive me if this question doesn't make sense but why Xen instead of KVM? Is there an advantage/disadvantage to either with your specific hardware and/or primary host OS (debian/GNU)? It appears at present there isn't a way to do what you're doing within a Hyper-V or ESX configuration so I may end up going down a Linux path (would RedHat or SUSE work the same as you're doing with debian?).

Additionally, you started with a Creative PCI card but appears you moved to USB. You also referenced using onboard at one point. Does the onboard have significant issues and should not be used within the Windows guest/vm? As you referenced an Audigy and a X-Fi Titanium, did both/neither work, why the switch, etc?

Many thanks for your assistance!!!
 


It was me who moved to a USB sound card, my X-Fi PCI (not PCIe, in contrast to what mathew7 is using) wasn't stable enough and I don't recall it working with generic drivers. However, with this USB sound card only a very small range of applications show any signs of errors due to stalled I/O, and Skyrim and Serious Sam 3 has reversed stereo for some reason (might be a hardware fluke, those are about the only games I play with proper directional sound effects).

It's a bit odd how my USB3 ports are mostly stable though, only had them drop out about 3 or 4 times since the build, usually with a bluescreen and requires a reboot of the host. The driver must be doing something strange with it.

As for KVM, I've read they're working on it but last time I checked a couple of months ago it was still very experimental. There might be better support for it by now, but I'll stay with Xen for a while as it offers very advanced configurations of the virtualized hardware. I know ESXi has support for IOMMU, but I haven't read anything about using graphics cards with it.
 
fascinating thread guys, as this is something i'm looking to do

I have a i7-2600K so it looks like for full VT-D support i might need to swap it out for a new Sandy/Ivy Bridge non-K.

Anyway, just a question on this VT-D


Do the host and guest systems need to be on different GPU's ?

the OP had Linux running on the Intel iGPU, and Linux on the Nvidia - is this a requirement? or could i run both on the nvidia?
 


In short, different. The "controlling" OS will have complete control. So if you still want to "see" your linux, you would need 2 GPUs. There is no paravirtualization driver.....think about it: how would you tell your GPU which "screen" to show (guest or host)?

Anyway, I wanted to update regarding sound cards. Previously when trying PCI (not PCIe) devices, I kept getting a PCI sibling device 0:00.0 is not used by pciback or pci-stub. I found a few posts and saw that this is thrown by a python script. So I made changes to it and have experimented with my 2 older sound cards:
- Creative audigy - same thing from Creative drivers: device appears, but no sound (driver seems to freeze)
- Hercules Fortissimo IV (Via VT1724HT based) - great.....this is my new sound card. Played a little of Quake4, Deus Ex...and no problems till now (knock on wood). As opposed to my USB sound card, I can set this one to 24-bit, 96KHz.

So a summary of what I'm virtualizing:
- (PCIe) ATI 5850 (damn....it's so hard saving money for that 7950)
- (PCIe, onboard) 2nd USB2.0 controller
- (PCI) VT1724 sound card
- (PCI) RTL8169 network adapter (yes...I switched to real HW NIC....no issues with virtual, it's just because I can)
 
Status
Not open for further replies.