diff options
author | Robert Noland <rnoland@2hip.net> | 2009-02-26 23:51:57 -0600 |
---|---|---|
committer | Robert Noland <rnoland@2hip.net> | 2009-02-26 23:51:57 -0600 |
commit | ab582f64fd54565f66eba866972f0fe2c313f000 (patch) | |
tree | f7e594a751bccc408c0440f21f381da667a31ebe /bsd-core | |
parent | 948af0bd9b9eade489599d7ec160d42706331779 (diff) |
FreeBSD: Fix up some ioctl permissions issues missed many times over.
This was somehow hit with r600 demo.
Submitted by: Jung-uk Kim <jkim@FreeBSD.org>
Diffstat (limited to 'bsd-core')
-rw-r--r-- | bsd-core/drmP.h | 4 | ||||
-rw-r--r-- | bsd-core/drm_bufs.c | 3 | ||||
-rw-r--r-- | bsd-core/drm_drv.c | 8 |
3 files changed, 7 insertions, 8 deletions
diff --git a/bsd-core/drmP.h b/bsd-core/drmP.h index f450d69f..573c2b19 100644 --- a/bsd-core/drmP.h +++ b/bsd-core/drmP.h @@ -904,8 +904,8 @@ int drm_addmap_ioctl(struct drm_device *dev, void *data, struct drm_file *file_priv); int drm_rmmap_ioctl(struct drm_device *dev, void *data, struct drm_file *file_priv); -int drm_addbufs_ioctl(struct drm_device *dev, void *data, - struct drm_file *file_priv); +int drm_addbufs(struct drm_device *dev, void *data, + struct drm_file *file_priv); int drm_infobufs(struct drm_device *dev, void *data, struct drm_file *file_priv); int drm_markbufs(struct drm_device *dev, void *data, diff --git a/bsd-core/drm_bufs.c b/bsd-core/drm_bufs.c index ebc46b5b..1f83ba38 100644 --- a/bsd-core/drm_bufs.c +++ b/bsd-core/drm_bufs.c @@ -877,8 +877,7 @@ int drm_addbufs_pci(struct drm_device *dev, struct drm_buf_desc *request) return ret; } -int drm_addbufs_ioctl(struct drm_device *dev, void *data, - struct drm_file *file_priv) +int drm_addbufs(struct drm_device *dev, void *data, struct drm_file *file_priv) { struct drm_buf_desc *request = data; int err; diff --git a/bsd-core/drm_drv.c b/bsd-core/drm_drv.c index 2601e558..c45a4427 100644 --- a/bsd-core/drm_drv.c +++ b/bsd-core/drm_drv.c @@ -79,7 +79,7 @@ static drm_ioctl_desc_t drm_ioctls[256] = { DRM_IOCTL_DEF(DRM_IOCTL_SET_SAREA_CTX, drm_setsareactx, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_GET_SAREA_CTX, drm_getsareactx, DRM_AUTH), - DRM_IOCTL_DEF(DRM_IOCTL_ADD_CTX, drm_addctx, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), + DRM_IOCTL_DEF(DRM_IOCTL_ADD_CTX, drm_addctx, DRM_AUTH|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_RM_CTX, drm_rmctx, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_MOD_CTX, drm_modctx, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_GET_CTX, drm_getctx, DRM_AUTH), @@ -92,10 +92,11 @@ static drm_ioctl_desc_t drm_ioctls[256] = { DRM_IOCTL_DEF(DRM_IOCTL_LOCK, drm_lock, DRM_AUTH), DRM_IOCTL_DEF(DRM_IOCTL_UNLOCK, drm_unlock, DRM_AUTH), + DRM_IOCTL_DEF(DRM_IOCTL_FINISH, drm_noop, DRM_AUTH), - DRM_IOCTL_DEF(DRM_IOCTL_ADD_BUFS, drm_addbufs_ioctl, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), - DRM_IOCTL_DEF(DRM_IOCTL_MARK_BUFS, drm_markbufs, DRM_AUTH|DRM_MASTER), + DRM_IOCTL_DEF(DRM_IOCTL_ADD_BUFS, drm_addbufs, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), + DRM_IOCTL_DEF(DRM_IOCTL_MARK_BUFS, drm_markbufs, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_INFO_BUFS, drm_infobufs, DRM_AUTH), DRM_IOCTL_DEF(DRM_IOCTL_MAP_BUFS, drm_mapbufs, DRM_AUTH), DRM_IOCTL_DEF(DRM_IOCTL_FREE_BUFS, drm_freebufs, DRM_AUTH), @@ -114,7 +115,6 @@ static drm_ioctl_desc_t drm_ioctls[256] = { DRM_IOCTL_DEF(DRM_IOCTL_SG_ALLOC, drm_sg_alloc_ioctl, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), DRM_IOCTL_DEF(DRM_IOCTL_SG_FREE, drm_sg_free, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), - DRM_IOCTL_DEF(DRM_IOCTL_WAIT_VBLANK, drm_wait_vblank, 0), DRM_IOCTL_DEF(DRM_IOCTL_MODESET_CTL, drm_modeset_ctl, 0), DRM_IOCTL_DEF(DRM_IOCTL_UPDATE_DRAW, drm_update_draw, DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY), |