Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f898d99 authored by Jakob Bornecrantz's avatar Jakob Bornecrantz Committed by Dave Airlie
Browse files

vmwgfx: Make sure the reserved area is at the start of vram

parent 497a3ff9
Loading
Loading
Loading
Loading
+3 −0
Original line number Original line Diff line number Diff line
@@ -717,6 +717,9 @@ static int vmw_surface_dmabuf_pin(struct vmw_framebuffer *vfb)
		vmw_framebuffer_to_vfbs(&vfb->base);
		vmw_framebuffer_to_vfbs(&vfb->base);
	unsigned long size = vfbs->base.base.pitch * vfbs->base.base.height;
	unsigned long size = vfbs->base.base.pitch * vfbs->base.base.height;
	int ret;
	int ret;
	struct ttm_placement ne_placement = vmw_vram_ne_placement;

	ne_placement.lpfn = (size + (PAGE_SIZE - 1)) / PAGE_SIZE;


	vfbs->buffer = kzalloc(sizeof(*vfbs->buffer), GFP_KERNEL);
	vfbs->buffer = kzalloc(sizeof(*vfbs->buffer), GFP_KERNEL);
	if (unlikely(vfbs->buffer == NULL))
	if (unlikely(vfbs->buffer == NULL))