diff options
author | Eric Anholt <eric@anholt.net> | 2007-07-20 06:39:25 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2007-07-20 13:39:45 -0700 |
commit | c1119b1b092527fbb6950d0b5e51e076ddb00f29 (patch) | |
tree | 1d4b0f26e40d572e4c92eb4ebde88e60b9b137e5 /bsd-core/drm_lock.c | |
parent | 35de4868361ce1fb515cf33f27e6be4c59b07f89 (diff) |
Replace filp in ioctl arguments with drm_file *file_priv.
As a fallout, replace filp storage with file_priv storage for "unique
identifier of a client" all over the DRM. There is a 1:1 mapping, so this
should be a noop. This could be a minor performance improvement, as everything
on Linux dereferenced filp to get file_priv anyway, while only the mmap ioctls
went the other direction.
Diffstat (limited to 'bsd-core/drm_lock.c')
-rw-r--r-- | bsd-core/drm_lock.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bsd-core/drm_lock.c b/bsd-core/drm_lock.c index d0e61d3a..54b64806 100644 --- a/bsd-core/drm_lock.c +++ b/bsd-core/drm_lock.c @@ -66,7 +66,7 @@ int drm_lock_transfer(drm_device_t *dev, { unsigned int old, new; - dev->lock.filp = NULL; + dev->lock.file_priv = NULL; do { old = *lock; new = context | _DRM_LOCK_HELD; @@ -80,7 +80,7 @@ int drm_lock_free(drm_device_t *dev, { unsigned int old, new; - dev->lock.filp = NULL; + dev->lock.file_priv = NULL; do { old = *lock; new = 0; @@ -118,7 +118,7 @@ int drm_lock(DRM_IOCTL_ARGS) DRM_LOCK(); for (;;) { if (drm_lock_take(&dev->lock.hw_lock->lock, lock.context)) { - dev->lock.filp = (void *)(uintptr_t)DRM_CURRENTPID; + dev->lock.file_priv = file_priv; dev->lock.lock_time = jiffies; atomic_inc(&dev->counts[_DRM_STAT_LOCKS]); break; /* Got lock */ |