mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user