Commit b2ecb89c authored by Chris Wilson's avatar Chris Wilson Committed by Daniel Vetter

drm/legacy: Fix type for drm_local_map.offset

drm_local_map.offset is not only used for resource_size_t but also
dma_addr_t which may be of different sizes.
Reported-by: default avatarNathan Chancellor <natechancellor@gmail.com>
Fixes: 8e4ff9b5 ("drm: Remove the dma_alloc_coherent wrapper for internal usage")
Tested-by: Nathan Chancellor <natechancellor@gmail.com> # build
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Dave Airlie <airlied@gmail.com>
Cc: Nathan Chancellor <natechancellor@gmail.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20200402215926.30714-1-chris@chris-wilson.co.uk
parent b513b0d4
...@@ -136,7 +136,7 @@ struct drm_sg_mem { ...@@ -136,7 +136,7 @@ struct drm_sg_mem {
* Kernel side of a mapping * Kernel side of a mapping
*/ */
struct drm_local_map { struct drm_local_map {
resource_size_t offset; /**< Requested physical address (0 for SAREA)*/ dma_addr_t offset; /**< Requested physical address (0 for SAREA)*/
unsigned long size; /**< Requested physical size (bytes) */ unsigned long size; /**< Requested physical size (bytes) */
enum drm_map_type type; /**< Type of memory to map */ enum drm_map_type type; /**< Type of memory to map */
enum drm_map_flags flags; /**< Flags */ enum drm_map_flags flags; /**< Flags */
......
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