diff options
Diffstat (limited to 'drivers/gpu/drm/r128')
-rw-r--r-- | drivers/gpu/drm/r128/r128_cce.c | 1 | ||||
-rw-r--r-- | drivers/gpu/drm/r128/r128_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/r128/r128_ioc32.c | 16 |
3 files changed, 7 insertions, 12 deletions
diff --git a/drivers/gpu/drm/r128/r128_cce.c b/drivers/gpu/drm/r128/r128_cce.c index 4c39a407aa4a..e671d0e74d4c 100644 --- a/drivers/gpu/drm/r128/r128_cce.c +++ b/drivers/gpu/drm/r128/r128_cce.c | |||
@@ -31,6 +31,7 @@ | |||
31 | 31 | ||
32 | #include <linux/firmware.h> | 32 | #include <linux/firmware.h> |
33 | #include <linux/platform_device.h> | 33 | #include <linux/platform_device.h> |
34 | #include <linux/slab.h> | ||
34 | 35 | ||
35 | #include "drmP.h" | 36 | #include "drmP.h" |
36 | #include "drm.h" | 37 | #include "drm.h" |
diff --git a/drivers/gpu/drm/r128/r128_drv.c b/drivers/gpu/drm/r128/r128_drv.c index 601f4c0e5da5..b806fdcc7170 100644 --- a/drivers/gpu/drm/r128/r128_drv.c +++ b/drivers/gpu/drm/r128/r128_drv.c | |||
@@ -64,7 +64,7 @@ static struct drm_driver driver = { | |||
64 | .owner = THIS_MODULE, | 64 | .owner = THIS_MODULE, |
65 | .open = drm_open, | 65 | .open = drm_open, |
66 | .release = drm_release, | 66 | .release = drm_release, |
67 | .ioctl = drm_ioctl, | 67 | .unlocked_ioctl = drm_ioctl, |
68 | .mmap = drm_mmap, | 68 | .mmap = drm_mmap, |
69 | .poll = drm_poll, | 69 | .poll = drm_poll, |
70 | .fasync = drm_fasync, | 70 | .fasync = drm_fasync, |
diff --git a/drivers/gpu/drm/r128/r128_ioc32.c b/drivers/gpu/drm/r128/r128_ioc32.c index d3cb676eee84..51c99fc4dd38 100644 --- a/drivers/gpu/drm/r128/r128_ioc32.c +++ b/drivers/gpu/drm/r128/r128_ioc32.c | |||
@@ -95,8 +95,7 @@ static int compat_r128_init(struct file *file, unsigned int cmd, | |||
95 | &init->agp_textures_offset)) | 95 | &init->agp_textures_offset)) |
96 | return -EFAULT; | 96 | return -EFAULT; |
97 | 97 | ||
98 | return drm_ioctl(file->f_path.dentry->d_inode, file, | 98 | return drm_ioctl(file, DRM_IOCTL_R128_INIT, (unsigned long)init); |
99 | DRM_IOCTL_R128_INIT, (unsigned long)init); | ||
100 | } | 99 | } |
101 | 100 | ||
102 | typedef struct drm_r128_depth32 { | 101 | typedef struct drm_r128_depth32 { |
@@ -129,8 +128,7 @@ static int compat_r128_depth(struct file *file, unsigned int cmd, | |||
129 | &depth->mask)) | 128 | &depth->mask)) |
130 | return -EFAULT; | 129 | return -EFAULT; |
131 | 130 | ||
132 | return drm_ioctl(file->f_path.dentry->d_inode, file, | 131 | return drm_ioctl(file, DRM_IOCTL_R128_DEPTH, (unsigned long)depth); |
133 | DRM_IOCTL_R128_DEPTH, (unsigned long)depth); | ||
134 | 132 | ||
135 | } | 133 | } |
136 | 134 | ||
@@ -153,8 +151,7 @@ static int compat_r128_stipple(struct file *file, unsigned int cmd, | |||
153 | &stipple->mask)) | 151 | &stipple->mask)) |
154 | return -EFAULT; | 152 | return -EFAULT; |
155 | 153 | ||
156 | return drm_ioctl(file->f_path.dentry->d_inode, file, | 154 | return drm_ioctl(file, DRM_IOCTL_R128_STIPPLE, (unsigned long)stipple); |
157 | DRM_IOCTL_R128_STIPPLE, (unsigned long)stipple); | ||
158 | } | 155 | } |
159 | 156 | ||
160 | typedef struct drm_r128_getparam32 { | 157 | typedef struct drm_r128_getparam32 { |
@@ -178,8 +175,7 @@ static int compat_r128_getparam(struct file *file, unsigned int cmd, | |||
178 | &getparam->value)) | 175 | &getparam->value)) |
179 | return -EFAULT; | 176 | return -EFAULT; |
180 | 177 | ||
181 | return drm_ioctl(file->f_path.dentry->d_inode, file, | 178 | return drm_ioctl(file, DRM_IOCTL_R128_GETPARAM, (unsigned long)getparam); |
182 | DRM_IOCTL_R128_GETPARAM, (unsigned long)getparam); | ||
183 | } | 179 | } |
184 | 180 | ||
185 | drm_ioctl_compat_t *r128_compat_ioctls[] = { | 181 | drm_ioctl_compat_t *r128_compat_ioctls[] = { |
@@ -210,12 +206,10 @@ long r128_compat_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) | |||
210 | if (nr < DRM_COMMAND_BASE + DRM_ARRAY_SIZE(r128_compat_ioctls)) | 206 | if (nr < DRM_COMMAND_BASE + DRM_ARRAY_SIZE(r128_compat_ioctls)) |
211 | fn = r128_compat_ioctls[nr - DRM_COMMAND_BASE]; | 207 | fn = r128_compat_ioctls[nr - DRM_COMMAND_BASE]; |
212 | 208 | ||
213 | lock_kernel(); /* XXX for now */ | ||
214 | if (fn != NULL) | 209 | if (fn != NULL) |
215 | ret = (*fn) (filp, cmd, arg); | 210 | ret = (*fn) (filp, cmd, arg); |
216 | else | 211 | else |
217 | ret = drm_ioctl(filp->f_path.dentry->d_inode, filp, cmd, arg); | 212 | ret = drm_ioctl(filp, cmd, arg); |
218 | unlock_kernel(); | ||
219 | 213 | ||
220 | return ret; | 214 | return ret; |
221 | } | 215 | } |