]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gvt: Pin vgpu dma address before using
authorTina Zhang <tina.zhang@intel.com>
Fri, 13 Dec 2019 03:23:14 +0000 (11:23 +0800)
committerZhenyu Wang <zhenyuw@linux.intel.com>
Fri, 13 Dec 2019 03:24:01 +0000 (11:24 +0800)
commitaf5f34b7a029f4e0671c8226f46618f6135b2244
tree8085b2e99b332ec85e527abfc436139d20dbdd53
parented611000991d58d220bd9d91ba9fbf3136e9b977
drm/i915/gvt: Pin vgpu dma address before using

Dma-buf display uses the vgpu dma address saved in the guest part GGTT
table which is updated by vCPU thread. In host side, when the dma
address is used by qemu ui thread, gvt-g must make sure the dma address
is validated before letting it go to the HW. Invalid guest dma address
will easily cause DMA fault and make GPU hang.

v2: Rebase

Fixes: 493676e3dbd2 ("drm/i915/gvt: Dmabuf support for GVT-g")
Acked-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Signed-off-by: Tina Zhang <tina.zhang@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20191212141342.3417-1-tina.zhang@intel.com
drivers/gpu/drm/i915/gvt/dmabuf.c
drivers/gpu/drm/i915/gvt/hypercall.h
drivers/gpu/drm/i915/gvt/kvmgt.c
drivers/gpu/drm/i915/gvt/mpt.h