Jean Guyader
2012-May-10 19:07 UTC
[PATCH][RESEND] qemu-xen: Intel GPU passthrough, fix OpRegion mapping (v3)
The OpRegion shouldn''t be mapped 1:1 because the address in the host can''t be used in the guest directly. This patch traps read and write access to the opregion of the Intel GPU config space (offset 0xfc). To work correctly this patch needs a change in hvmloader. HVMloader will allocate 2 pages for the OpRegion and write this address on the config space of the Intel GPU. Qemu will trap and map the host OpRegion to the guest. Any write to this offset after that won''t have any effect. Any read of this config space offset will return the address in the guest. Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Jean Guyader
2012-May-10 20:02 UTC
Re: [PATCH][RESEND] qemu-xen: Intel GPU passthrough, fix OpRegion mapping (v3)
On 10 May 2012 20:07, Jean Guyader <jean.guyader@gmail.com> wrote:> The OpRegion shouldn''t be mapped 1:1 because the address in the host > can''t be used in the guest directly. > > This patch traps read and write access to the opregion of the Intel > GPU config space (offset 0x). > > To work correctly this patch needs a change in hvmloader. > > HVMloader will allocate 2 pages for the OpRegion and write this address > on the config space of the Intel GPU. Qemu will trap and map the host > OpRegion to the guest. Any write to this offset after that won''t have > any effect. Any read of this config space offset will return the address > in the guest. > > Signed-off-by: Jean Guyader <jean.guyader@eu.citrix.com>Sorry forgot to say, it was acked by Stefano. Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Ian Jackson
2012-May-11 11:42 UTC
Re: [PATCH][RESEND] qemu-xen: Intel GPU passthrough, fix OpRegion mapping (v3)
Jean Guyader writes ("Re: [Xen-devel] [PATCH][RESEND] qemu-xen: Intel GPU passthrough, fix OpRegion mapping (v3)"):> On 10 May 2012 20:07, Jean Guyader <jean.guyader@gmail.com> wrote: > > The OpRegion shouldn''t be mapped 1:1 because the address in the host > > can''t be used in the guest directly. > > Sorry forgot to say, it was acked by Stefano. > > Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>Thanks. Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Seemingly Similar Threads
- [PATCH] qemu-xen: Intel GPU passthrough, fix OpRegion mapping.
- [PATCH] hvmloader / qemu-xen: Getting rid of resource conflict for OpRegion.
- [PATCH] Intel GPU passthrough: Host bridge config space
- GPU passthrough issue when VM is configured with 4G memory
- good progress on pci vga passthrough in xen-3.4-rc1