rcar_i2c_irq_recv() always returns 0, so we can make this function return *void* and also remove rcar_i2c_flags_set() invocation in rcar_i2c_irq(). Signed-off-by: Sergei Shtylyov <sergei.shtylyov@xxxxxxxxxxxxxxxxxx> --- drivers/i2c/busses/i2c-rcar.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) Index: linux/drivers/i2c/busses/i2c-rcar.c =================================================================== --- linux.orig/drivers/i2c/busses/i2c-rcar.c +++ linux/drivers/i2c/busses/i2c-rcar.c @@ -317,7 +317,7 @@ static int rcar_i2c_irq_send(struct rcar return 0; } -static int rcar_i2c_irq_recv(struct rcar_i2c_priv *priv, u32 msr) +static void rcar_i2c_irq_recv(struct rcar_i2c_priv *priv, u32 msr) { struct i2c_msg *msg = priv->msg; @@ -327,7 +327,7 @@ static int rcar_i2c_irq_recv(struct rcar * Do nothing */ if (!(msr & MDR)) - return 0; + return; if (msr & MAT) { /* @@ -354,8 +354,6 @@ static int rcar_i2c_irq_recv(struct rcar rcar_i2c_write(priv, ICMCR, RCAR_BUS_PHASE_DATA); rcar_i2c_write(priv, ICMSR, RCAR_IRQ_ACK_RECV); - - return 0; } static irqreturn_t rcar_i2c_irq(int irq, void *ptr) @@ -387,7 +385,7 @@ static irqreturn_t rcar_i2c_irq(int irq, } if (rcar_i2c_is_recv(priv)) - rcar_i2c_flags_set(priv, rcar_i2c_irq_recv(priv, msr)); + rcar_i2c_irq_recv(priv, msr); else rcar_i2c_flags_set(priv, rcar_i2c_irq_send(priv, msr)); -- To unsubscribe from this list: send the line "unsubscribe linux-i2c" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html