Skip to content
  • Changbin Du's avatar
    drm/i915/gvt: Rework shadow page management code · 44b46733
    Changbin Du authored
    
    
    This is a another big one and the GVT shadow page management code is
    heavily refined.
    
    The new code only use struct intel_vgpu_ppgtt_spt to represent a vgpu
    shadow page table - w/ or wo/ a guest page associated with. A pure shadow
    page (no guest page associated) will be used to shadow splited 2M huge
    gtt. In this case, the spt.guest_page.gfn should be a zero.
    
    To search a existed shadow page table, we have two new interfaces:
     - intel_vgpu_find_spt_by_gfn(), find a spt by guest gfn. It must not
       be a pure spt.
     - intel_vgpu_find_spt_by_mfn, Find the spt using shadow page mfn in
       shadowed PTE.
    
    The oos_page management is remained as what is was.
    
    v2: Split some changes into small standalone patches.
    
    Signed-off-by: default avatarChangbin Du <changbin.du@intel.com>
    Signed-off-by: default avatarZhenyu Wang <zhenyuw@linux.intel.com>
    44b46733