Commit a8dc4214 authored by Frediano Ziglio's avatar Frediano Ziglio Committed by Gerd Hoffmann

drm/qxl: change the way slot is detected

Instead of relaying on surface type use the actual placement.
This allow to have different placement for a single type of
surface.
Signed-off-by: default avatarFrediano Ziglio <fziglio@redhat.com>
Acked-by: default avatarNoralf Trønnes <noralf@tronnes.org>
Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20190118122020.27596-5-kraxel@redhat.com

[ kraxel: rebased, adapted to upstream changes ]
Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
parent 2ec6bd67
......@@ -311,7 +311,8 @@ static inline uint64_t
qxl_bo_physical_address(struct qxl_device *qdev, struct qxl_bo *bo,
unsigned long offset)
{
struct qxl_memslot *slot = bo->type == QXL_GEM_DOMAIN_VRAM
struct qxl_memslot *slot =
(bo->tbo.mem.mem_type == TTM_PL_VRAM)
? &qdev->main_slot : &qdev->surfaces_slot;
/* TODO - need to hold one of the locks to read tbo.offset */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment