Skip to content
  • Andrii Pauk's avatar
    drm/virtio: implement guest vram · 48cf079c
    Andrii Pauk authored and Gurchetan Singh's avatar Gurchetan Singh committed
    
    
    Add support of GUEST_VRAM type of blob. These are dedicated heap memory
    allocations required for vk support on hypervisors that don't support
    runtime injections of host memory into guest physical address space.
    
    The flow of usage:
    1) Host VM reserves dedicated heap memory in it's dts
    2) Device get info about memory reservations and report it to guest using
    new mmio registers
    3) Guest virtio-gpu driver on starts checks new mmio registers for physical
    address and length of reserved region. Then it reserves it in guest.
    4) On create_blob drm ioctl guest driver gets chunk of required memory and
    send it to host using sg list. It uses one sg entry for 1 blob call. Heap
    is managed on guest using drm memory manager (drm_mm).
    
    Signed-off-by: default avatarAndrii Pauk <Andrii.Pauk@opensynergy.com>
    48cf079c