On Tue, Mar 12, 2019 at 09:58:56AM -0400, Jason Andryuk wrote: > On Tue, Mar 12, 2019 at 8:38 AM Marek Marczykowski-Górecki > wrote: > > > > On Tue, Mar 12, 2019 at 01:04:19PM +0100, Roger Pau Monné wrote: > > > On Mon, Mar 11, 2019 at 02:02:15PM -0400, Jason Andryuk wrote: > > > > MSI-X is not supported in Xen stubdoms, so it must be disabled. Use the > > > > existing xen_pt_hide_dev_cap to hide when running under -xen-stubdom. > > > > > > I'm afraid this requires some more context. What's the actual issue > > > that prevents MSI-X from working? > > > > At least missing "Fix PCI passthrough for HVM with stubdomain" series, > > but that's mostly on Xen side (+ one change how QEMU enable MSI-X in > > config space). > > Some of it can be worked around by enabling permissive mode. Jason, did > > you had a chance to test it with any MSI-X device? > > I'm not aware of anything thing particular that breaks MSI-X but not > > MSI. Besides much less devices lying around to test MSI-X... > > OpenXT and Qubes have used a compile time patch that disabled MSI-X > for a long time. The OpenXT patch description doesn't help: > """ > Currently we do not support MSI-X setup for PCI devices passed through. > > Although the specification mentions that PCI-e devices might implement only > MSI-X there is not a lot of those and mostly none that we have encountered yet. > Considering that, we force devices to use MSI by hiding the MSI-X capability. > """ > > To be honest, I didn't question the reasoning and just made the > compile-time disabling into a runtime disabling. > > I tested with a NEC uPD720200 XHCI controller supporting MSI-X. There > was an error related to setting up MSI-X when I failed to pass the > "-xen-stubdom" flag. I can pull that log when I get back to the > machine. With this patch, MSI-X was hidden in the guest, but dom0 > showed MSI-X present but unused. > > Marek, is "Use xc_physdev_msi_set_enable for enabling MSI..." the QEMU > patch you are refer to? Do you think permissive mode would allow > MSI-X to work without that patch? I could test that out. Yes, this one. Permissive mode should work around it. There is also another patch about IRQ permission, but I believe you already have it in OpenXT. -- Best Regards, Marek Marczykowski-Górecki Invisible Things Lab A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?