drm/omap: gem: Clean up GEM objects memory flags
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Mon, 14 Dec 2015 20:39:37 +0000 (22:39 +0200)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Thu, 3 Mar 2016 15:36:41 +0000 (17:36 +0200)
commitcdb0381d2f19974dc092d5aac672978d0f771eb6
tree3d9999917c956ef0be89b6ad29c367d2232a9022
parent8d83bbd1198d7d0de2968ec0bde85810b26341e1
drm/omap: gem: Clean up GEM objects memory flags

The driver assumes that only objects backed by shmem need to be mapped
through DMM. While this is true with the current code, the assumption
won't hold with dma_buf import support.

Condition the mapping based on whether the buffer has been allocated
using the DMA mapping API instead and clean up the flags to avoid having
to check both flags and GEM object filp field to decide how to process
buffers. Flags are not the authoritative source of information regarding
where the buffer memory comes from, and are renamed to make that
clearer.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/gpu/drm/omapdrm/omap_gem.c