lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 24 May 2019 23:32:36 -0400
From:   Steven Rostedt <>
        linux-rt-users <>
Cc:     Thomas Gleixner <>,
        Carsten Emde <>,
        Sebastian Andrzej Siewior <>,
        John Kacur <>,
        Paul Gortmaker <>,
        Julia Cartwright <>,
        Daniel Wagner <>,
Subject: [PATCH RT 4/6] drm/i915: Dont disable interrupts independently of the lock

4.19.37-rt20-rc1 stable review patch.
If anyone has any objections, please let me know.


From: Sebastian Andrzej Siewior <>

The locks (timeline->lock and rq->lock) need to be taken with disabled
interrupts. This is done in __retire_engine_request() by disabling the
interrupts independently of the locks itself.
While local_irq_disable()+spin_lock() equals spin_lock_irq() on vanilla
it does not on RT. Also, it is not obvious if there is a special reason
to why the interrupts are disabled independently of the lock.

Enable/disable interrupts as part of the locking instruction.

Signed-off-by: Sebastian Andrzej Siewior <>
Signed-off-by: Steven Rostedt (VMware) <>
 drivers/gpu/drm/i915/i915_request.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_request.c b/drivers/gpu/drm/i915/i915_request.c
index 5c2c93cbab12..7124510b9131 100644
--- a/drivers/gpu/drm/i915/i915_request.c
+++ b/drivers/gpu/drm/i915/i915_request.c
@@ -356,9 +356,7 @@ static void __retire_engine_request(struct intel_engine_cs *engine,
-	local_irq_disable();
-	spin_lock(&engine->timeline.lock);
+	spin_lock_irq(&engine->timeline.lock);
 	GEM_BUG_ON(!list_is_first(&rq->link, &engine->timeline.requests));
@@ -372,9 +370,7 @@ static void __retire_engine_request(struct intel_engine_cs *engine,
-	spin_unlock(&rq->lock);
-	local_irq_enable();
+	spin_unlock_irq(&rq->lock);
 	 * The backing object for the context is done after switching to the

Powered by blists - more mailing lists