i2c: rk3x: Fix the smatch warning
This patch fixes the following warning:
drivers/i2c/busses/i2c-rk3x.c:1136 rk3x_i2c_xfer() error: uninitialized symbol 'timeout'.
Fixes: d5635ca05b ("i2c: rk3x: Disable irq after i2c transfer finished")
Change-Id: I7618ae660a62e8e3fc5b7b5d00cff1264bd18663
Signed-off-by: David Wu <david.wu@rock-chips.com>
This commit is contained in:
parent
165fb1619b
commit
574de13fac
1 changed files with 1 additions and 4 deletions
|
|
@ -1132,10 +1132,7 @@ static int rk3x_i2c_xfer(struct i2c_adapter *adap,
|
|||
}
|
||||
}
|
||||
|
||||
/* Interrupt is disabled when i2c transfer is timeout */
|
||||
if (timeout != 0)
|
||||
rk3x_i2c_disable_irq(i2c);
|
||||
|
||||
rk3x_i2c_disable_irq(i2c);
|
||||
rk3x_i2c_disable(i2c);
|
||||
|
||||
clk_disable(i2c->pclk);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue