aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/sis/sis_mm.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2012-06-24 13:57:24 -0400
committerDave Airlie <airlied@redhat.com>2012-07-19 22:51:58 -0400
commit83bc5fd29afff5898cadf87fb29eb9260eecc63e (patch)
tree3e30342aa5203f4a0789d7968f89446e8fd19dd5 /drivers/gpu/drm/sis/sis_mm.c
parent26587e69946249dc8327c5912d86320c3f63b2c5 (diff)
drm/sis: fixup sis_mm ioctl structs
Userspace uses long in quite a few places more than the kernel. Which gives me neat proof that I'm the only guy on this side of the galaxy who ever tried to run glxgears on a 64bit machine with sis graphics on linux. Note that the longs in drm_sis_mem_t aren't aligned properly, so this won't even work with 32bit userspace on 64bit kernel as-is. Hence the patch can't break that, either. Nope, I'm not nuts enough to write the 32bit ioctl compat layer for this and test it with some wine app. Even though hunting the ebay dungeons for a sis card actually supported by the mesa drivers casts some doubts on this ... Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/sis/sis_mm.c')
-rw-r--r--drivers/gpu/drm/sis/sis_mm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/sis/sis_mm.c b/drivers/gpu/drm/sis/sis_mm.c
index 5acc396ef93..2c231070d25 100644
--- a/drivers/gpu/drm/sis/sis_mm.c
+++ b/drivers/gpu/drm/sis/sis_mm.c
@@ -74,7 +74,7 @@ static int sis_fb_init(struct drm_device *dev, void *data, struct drm_file *file
74 dev_priv->vram_offset = fb->offset; 74 dev_priv->vram_offset = fb->offset;
75 75
76 mutex_unlock(&dev->struct_mutex); 76 mutex_unlock(&dev->struct_mutex);
77 DRM_DEBUG("offset = %u, size = %u\n", fb->offset, fb->size); 77 DRM_DEBUG("offset = %lu, size = %lu\n", fb->offset, fb->size);
78 78
79 return 0; 79 return 0;
80} 80}
@@ -161,7 +161,7 @@ fail_alloc:
161 mem->size = 0; 161 mem->size = 0;
162 mem->free = 0; 162 mem->free = 0;
163 163
164 DRM_DEBUG("alloc %d, size = %d, offset = %d\n", pool, mem->size, 164 DRM_DEBUG("alloc %d, size = %ld, offset = %ld\n", pool, mem->size,
165 mem->offset); 165 mem->offset);
166 166
167 return retval; 167 return retval;
@@ -215,7 +215,7 @@ static int sis_ioctl_agp_init(struct drm_device *dev, void *data,
215 dev_priv->agp_offset = agp->offset; 215 dev_priv->agp_offset = agp->offset;
216 mutex_unlock(&dev->struct_mutex); 216 mutex_unlock(&dev->struct_mutex);
217 217
218 DRM_DEBUG("offset = %u, size = %u\n", agp->offset, agp->size); 218 DRM_DEBUG("offset = %lu, size = %lu\n", agp->offset, agp->size);
219 return 0; 219 return 0;
220} 220}
221 221