Lines Matching defs:context

47 static int drm_lock_take(struct drm_lock_data *lock_data, unsigned int context);
53 * \param context locking context.
56 * Attempt to mark the lock as held by the given context, via the \p cmpxchg instruction.
60 unsigned int context)
71 new = context | _DRM_LOCK_HELD |
79 if (_DRM_LOCKING_CONTEXT(old) == context) {
81 if (context != DRM_KERNEL_CONTEXT) {
83 context);
89 if ((_DRM_LOCKING_CONTEXT(new)) == context && (new & _DRM_LOCK_HELD)) {
97 * This takes a lock forcibly and hands it to context. Should ONLY be used
102 * \param context locking context.
106 * Marks the lock as held by the given context, via the \p cmpxchg instruction.
109 unsigned int context)
117 new = context | _DRM_LOCK_HELD;
124 unsigned int context)
144 if (_DRM_LOCK_IS_HELD(old) && _DRM_LOCKING_CONTEXT(old) != context) {
146 context, _DRM_LOCKING_CONTEXT(old));
177 if (lock->context == DRM_KERNEL_CONTEXT) {
178 DRM_ERROR("Process %d using kernel context %d\n",
179 task_pid_nr(current), lock->context);
184 lock->context, task_pid_nr(current),
201 if (drm_lock_take(&master->lock, lock->context)) {
222 DRM_DEBUG("%d %s\n", lock->context,
230 dev->sigdata.context = lock->context;
238 lock->context);
265 if (lock->context == DRM_KERNEL_CONTEXT) {
266 DRM_ERROR("Process %d using kernel context %d\n",
267 task_pid_nr(current), lock->context);
271 if (drm_legacy_lock_free(&master->lock, lock->context)) {
280 * with the kernel context if it is free, otherwise it gets the highest priority when and if
348 DRM_DEBUG("File %p released, freeing lock for context %d\n",