diff options
Diffstat (limited to 'drivers/char/drm/drm_os_linux.h')
-rw-r--r-- | drivers/char/drm/drm_os_linux.h | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/char/drm/drm_os_linux.h b/drivers/char/drm/drm_os_linux.h index 132c5580358b..e87dc34a6fbf 100644 --- a/drivers/char/drm/drm_os_linux.h +++ b/drivers/char/drm/drm_os_linux.h | |||
@@ -6,10 +6,8 @@ | |||
6 | #include <linux/interrupt.h> /* For task queue support */ | 6 | #include <linux/interrupt.h> /* For task queue support */ |
7 | #include <linux/delay.h> | 7 | #include <linux/delay.h> |
8 | 8 | ||
9 | /** File pointer type */ | ||
10 | #define DRMFILE struct file * | ||
11 | /** Ioctl arguments */ | 9 | /** Ioctl arguments */ |
12 | #define DRM_IOCTL_ARGS struct inode *inode, struct file *filp, unsigned int cmd, unsigned long data | 10 | #define DRM_IOCTL_ARGS struct inode *inode, struct drm_file *file_priv, unsigned int cmd, unsigned long data |
13 | /** Current process ID */ | 11 | /** Current process ID */ |
14 | #define DRM_CURRENTPID current->pid | 12 | #define DRM_CURRENTPID current->pid |
15 | #define DRM_SUSER(p) capable(CAP_SYS_ADMIN) | 13 | #define DRM_SUSER(p) capable(CAP_SYS_ADMIN) |
@@ -33,8 +31,7 @@ | |||
33 | /** Read/write memory barrier */ | 31 | /** Read/write memory barrier */ |
34 | #define DRM_MEMORYBARRIER() mb() | 32 | #define DRM_MEMORYBARRIER() mb() |
35 | /** DRM device local declaration */ | 33 | /** DRM device local declaration */ |
36 | #define DRM_DEVICE struct drm_file *priv = filp->private_data; \ | 34 | #define DRM_DEVICE struct drm_device *dev = file_priv->head->dev |
37 | struct drm_device *dev = priv->head->dev | ||
38 | 35 | ||
39 | /** IRQ handler arguments and return type and values */ | 36 | /** IRQ handler arguments and return type and values */ |
40 | #define DRM_IRQ_ARGS int irq, void *arg | 37 | #define DRM_IRQ_ARGS int irq, void *arg |
@@ -93,8 +90,6 @@ static __inline__ int mtrr_del(int reg, unsigned long base, unsigned long size) | |||
93 | #define DRM_GET_USER_UNCHECKED(val, uaddr) \ | 90 | #define DRM_GET_USER_UNCHECKED(val, uaddr) \ |
94 | __get_user(val, uaddr) | 91 | __get_user(val, uaddr) |
95 | 92 | ||
96 | #define DRM_GET_PRIV_WITH_RETURN(_priv, _filp) _priv = _filp->private_data | ||
97 | |||
98 | #define DRM_HZ HZ | 93 | #define DRM_HZ HZ |
99 | 94 | ||
100 | #define DRM_WAIT_ON( ret, queue, timeout, condition ) \ | 95 | #define DRM_WAIT_ON( ret, queue, timeout, condition ) \ |