| From fd6061fe68997261f6d1b2cb6a1a349c0c91248b Mon Sep 17 00:00:00 2001 |
| From: Sebastian Andrzej Siewior <bigeasy@linutronix.de> |
| Date: Tue, 14 Jul 2015 14:26:34 +0200 |
| Subject: [PATCH] gpu/i915: don't open code these things |
| |
| The opencode part is gone in 1f83fee0 ("drm/i915: clear up wedged transitions") |
| the owner check is still there. |
| |
| Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> |
| |
| diff --git a/drivers/gpu/drm/i915/i915_gem_shrinker.c b/drivers/gpu/drm/i915/i915_gem_shrinker.c |
| index 66571466e9a8..fe54dc641525 100644 |
| --- a/drivers/gpu/drm/i915/i915_gem_shrinker.c |
| +++ b/drivers/gpu/drm/i915/i915_gem_shrinker.c |
| @@ -40,7 +40,7 @@ static bool mutex_is_locked_by(struct mutex *mutex, struct task_struct *task) |
| if (!mutex_is_locked(mutex)) |
| return false; |
| |
| -#if defined(CONFIG_DEBUG_MUTEXES) || defined(CONFIG_MUTEX_SPIN_ON_OWNER) |
| +#if (defined(CONFIG_DEBUG_MUTEXES) || defined(CONFIG_MUTEX_SPIN_ON_OWNER)) && !defined(CONFIG_PREEMPT_RT_BASE) |
| return mutex->owner == task; |
| #else |
| /* Since UP may be pre-empted, we cannot assume that we own the lock */ |
| -- |
| 2.5.0 |
| |