diff options
author | Alan Hourihane <alanh@fairlite.demon.co.uk> | 2002-03-11 11:26:13 +0000 |
---|---|---|
committer | Alan Hourihane <alanh@fairlite.demon.co.uk> | 2002-03-11 11:26:13 +0000 |
commit | 2ab6ff71900ad068f6d5b8ee42743e13c928cedf (patch) | |
tree | 6336f7936e4c1d4036a61a28664c070531b82439 /bsd-core/drm_dma.c | |
parent | baef086c324769010f0d164c0fe03105d9e474e1 (diff) |
fixups for *BSD
Diffstat (limited to 'bsd-core/drm_dma.c')
-rw-r--r-- | bsd-core/drm_dma.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/bsd-core/drm_dma.c b/bsd-core/drm_dma.c index 3fd1bfe6..7c31a6e2 100644 --- a/bsd-core/drm_dma.c +++ b/bsd-core/drm_dma.c @@ -602,20 +602,19 @@ int DRM(control)( DRM_OS_IOCTL ) #else -int DRM(control)( struct inode *inode, struct file *filp, - unsigned int cmd, unsigned long arg ) +int DRM(control)( DRM_OS_IOCTL ) { + DRM_OS_DEVICE; drm_control_t ctl; - if ( copy_from_user( &ctl, (drm_control_t *)arg, sizeof(ctl) ) ) - return -EFAULT; + DRM_OS_KRNFROMUSR( ctl, (drm_control_t *) data, sizeof(ctl) ); switch ( ctl.func ) { case DRM_INST_HANDLER: case DRM_UNINST_HANDLER: return 0; default: - return -EINVAL; + DRM_OS_RETURN(EINVAL); } } |