ACRN:DM:VGPU: Free the memory after creating udmabuf
In course of creating the udmabuf, udmabuf_create_list is allocated and
passed to kernel. After the dmabuf is returned, it is not used
any more. Need to free it otherwises it will cause the memory leak.
Acked-by: Wang Yu
@@ -1026,6 +1026,7 @@ static struct dma_buf_info *virtio_gpu_create_udmabuf(struct virtio_gpu *gpu,
info->dmabuf_fd = dmabuf_fd;
atomic_store(&info->ref_count, 1);
}
+ free(list);
return info;
}
