1 From 3d3633b39814f19a0c8a16b315a31f4b98782c83 Mon Sep 17 00:00:00 2001
2 From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
3 Date: Thu, 21 Mar 2013 11:35:49 +0100
4 Subject: [PATCH 243/366] i2c/omap: drop the lock hard irq context
6 The lock is taken while reading two registers. On RT the first lock is
7 taken in hard irq where it might sleep and in the threaded irq.
8 The threaded irq runs in oneshot mode so the hard irq does not run until
9 the thread the completes so there is no reason to grab the lock.
11 Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
13 drivers/i2c/busses/i2c-omap.c | 5 +----
14 1 file changed, 1 insertion(+), 4 deletions(-)
16 diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
17 index 08d26ba..46b89dd 100644
18 --- a/drivers/i2c/busses/i2c-omap.c
19 +++ b/drivers/i2c/busses/i2c-omap.c
20 @@ -995,15 +995,12 @@ omap_i2c_isr(int irq, void *dev_id)
24 - spin_lock(&omap->lock);
25 - mask = omap_i2c_read_reg(omap, OMAP_I2C_IE_REG);
26 stat = omap_i2c_read_reg(omap, OMAP_I2C_STAT_REG);
27 + mask = omap_i2c_read_reg(omap, OMAP_I2C_IE_REG);
30 ret = IRQ_WAKE_THREAD;
32 - spin_unlock(&omap->lock);