diff options
author | Dave Airlie <airlied@starflyer.(none)> | 2005-10-24 04:41:39 -0400 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2005-10-24 04:41:39 -0400 |
commit | 67e1a014fbc0e472ccc55766a63640a767ede3bf (patch) | |
tree | b8033bfeb4e9ab2b12e6050565b7d815edd469b3 /drivers/char | |
parent | 5fb4dc9bf5e3af1ae91be97108bc3b1233252ddf (diff) |
drm: fix warning on 64-bit platforms..
This looks ugly, but it is the only thing that makes sense that doesn't
change the API.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/drm/drm_bufs.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/char/drm/drm_bufs.c b/drivers/char/drm/drm_bufs.c index 58e513a44740..319bdea8de8a 100644 --- a/drivers/char/drm/drm_bufs.c +++ b/drivers/char/drm/drm_bufs.c | |||
@@ -309,7 +309,9 @@ int drm_addmap_ioctl(struct inode *inode, struct file *filp, | |||
309 | 309 | ||
310 | if (copy_to_user(argp, maplist->map, sizeof(drm_map_t))) | 310 | if (copy_to_user(argp, maplist->map, sizeof(drm_map_t))) |
311 | return -EFAULT; | 311 | return -EFAULT; |
312 | if (put_user((void *)maplist->user_token, &argp->handle)) | 312 | |
313 | /* avoid a warning on 64-bit, this casting isn't very nice, but the API is set so too late */ | ||
314 | if (put_user((void *)(unsigned long)maplist->user_token, &argp->handle)) | ||
313 | return -EFAULT; | 315 | return -EFAULT; |
314 | return 0; | 316 | return 0; |
315 | } | 317 | } |