]> Git Repo - J-linux.git/commitdiff
drm/i915/gvt: clear ggtt entries when destroy vgpu
authorZhipeng Gong <[email protected]>
Mon, 17 Sep 2018 07:45:08 +0000 (15:45 +0800)
committerZhenyu Wang <[email protected]>
Tue, 18 Sep 2018 02:39:44 +0000 (10:39 +0800)
When one vgpu is destroyed, its ggtt entries are not cleared.
This patch clears ggtt entries to avoid information leak.

v2: add 'Fixes' tag (Zhenyu)

Fixes: 2707e4446688 ("drm/i915/gvt: vGPU graphics memory virtualization")
Signed-off-by: Zhipeng Gong <[email protected]>
Reviewed-by: Hang Yuan <[email protected]>
Signed-off-by: Zhenyu Wang <[email protected]>
drivers/gpu/drm/i915/gvt/vgpu.c

index a4e8e3cf74fd58b400331bc608516e9414e458d3..c628be05fbfe907a1bce89fd4727df79906fe63f 100644 (file)
@@ -281,6 +281,7 @@ void intel_gvt_destroy_vgpu(struct intel_vgpu *vgpu)
        intel_vgpu_clean_submission(vgpu);
        intel_vgpu_clean_display(vgpu);
        intel_vgpu_clean_opregion(vgpu);
+       intel_vgpu_reset_ggtt(vgpu, true);
        intel_vgpu_clean_gtt(vgpu);
        intel_gvt_hypervisor_detach_vgpu(vgpu);
        intel_vgpu_free_resource(vgpu);
This page took 0.05568 seconds and 4 git commands to generate.