diff options
author | addy ke <addy.ke@rock-chips.com> | 2014-08-08 17:41:40 +0800 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2014-08-08 18:33:57 +0200 |
commit | 9c5f7cad3acc69ce623d04d646950183a759949e (patch) | |
tree | a7b296ddeba2a4d4f0d37a4e3194900df9f49868 /drivers/i2c | |
parent | 64bdfbfc76999ab0dd7da0db7b2edea4f73ed228 (diff) | |
download | linux-stable-9c5f7cad3acc69ce623d04d646950183a759949e.tar.gz linux-stable-9c5f7cad3acc69ce623d04d646950183a759949e.tar.bz2 linux-stable-9c5f7cad3acc69ce623d04d646950183a759949e.zip |
i2c: rk3x: fix interrupt handling issue
If slave holds scl, I2C_IPD[7] will be set 1 by controller
for debugging. Driver must ignore it.
[ 5.752391] rk3x-i2c ff160000.i2c: unexpected irq in WRITE: 0x80
[ 5.939027] rk3x-i2c ff160000.i2c: timeout, ipd: 0x80, state: 4
Signed-off-by: Addy Ke <addy.ke@rock-chips.com>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Cc: stable@kernel.org
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-rk3x.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-rk3x.c b/drivers/i2c/busses/i2c-rk3x.c index a9791509966a..69e11853e8bf 100644 --- a/drivers/i2c/busses/i2c-rk3x.c +++ b/drivers/i2c/busses/i2c-rk3x.c @@ -399,7 +399,7 @@ static irqreturn_t rk3x_i2c_irq(int irqno, void *dev_id) } /* is there anything left to handle? */ - if (unlikely(ipd == 0)) + if (unlikely((ipd & REG_INT_ALL) == 0)) goto out; switch (i2c->state) { |