freedreno/kgsl: fix pointer-to-int cast
authorEric Engestrom <eric.engestrom@imgtec.com>
Thu, 14 Sep 2017 09:56:01 +0000 (10:56 +0100)
committerEric Engestrom <eric.engestrom@imgtec.com>
Fri, 15 Sep 2017 16:06:29 +0000 (17:06 +0100)
Fixes this warning:

freedreno/kgsl/kgsl_ringbuffer.c: In function ‘kgsl_ringbuffer_flush’:
freedreno/kgsl/kgsl_ringbuffer.c:149:19: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
   req.timestamp = (uint32_t)kgsl_ring->bo->hostptr;
                   ^

Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
freedreno/kgsl/kgsl_ringbuffer.c

index e4696b1..f09c433 100644 (file)
@@ -146,7 +146,7 @@ static int kgsl_ringbuffer_flush(struct fd_ringbuffer *ring, uint32_t *last_star
                ibdesc.gpuaddr = kgsl_ring->bo->gpuaddr;
                ibdesc.hostptr = kgsl_ring->bo->hostptr;
                ibdesc.sizedwords = 0x145;
-               req.timestamp = (uint32_t)kgsl_ring->bo->hostptr;
+               req.timestamp = (uintptr_t)kgsl_ring->bo->hostptr;
        }
 
        do {