diff options
| author | Robert Watson <rwatson@FreeBSD.org> | 2006-11-06 13:42:10 +0000 |
|---|---|---|
| committer | Robert Watson <rwatson@FreeBSD.org> | 2006-11-06 13:42:10 +0000 |
| commit | acd3428b7d3e94cef0e1881c868cb4b131d4ff41 (patch) | |
| tree | b9dd284620eeaddbff089cef10e4b1afb7918279 /sys/dev/drm | |
| parent | 800c94083290dc4b38138b28cfc03ee77de4ff79 (diff) | |
Notes
Diffstat (limited to 'sys/dev/drm')
| -rw-r--r-- | sys/dev/drm/drmP.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/dev/drm/drmP.h b/sys/dev/drm/drmP.h index 11714254dac5a..8e2855ad6a799 100644 --- a/sys/dev/drm/drmP.h +++ b/sys/dev/drm/drmP.h @@ -50,6 +50,9 @@ typedef struct drm_file drm_file_t; #include <sys/systm.h> #include <sys/conf.h> #include <sys/stat.h> +#if __FreeBSD_version >= 700000 +#include <sys/priv.h> +#endif #include <sys/proc.h> #include <sys/lock.h> #include <sys/fcntl.h> @@ -233,7 +236,11 @@ enum { #define PAGE_ALIGN(addr) round_page(addr) /* DRM_SUSER returns true if the user is superuser */ +#if __FreeBSD_version >= 700000 +#define DRM_SUSER(p) (priv_check(p, PRIV_DRIVER) == 0) +#else #define DRM_SUSER(p) (suser(p) == 0) +#endif #define DRM_AGP_FIND_DEVICE() agp_find_device() #define DRM_MTRR_WC MDF_WRITECOMBINE #define jiffies ticks |
