]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] ARM: OMAP: i2c-omap: Fix i2c_xfer for 1 msg
authorLadislav Michl <ladis@linux-mips.org>
Tue, 7 Feb 2006 03:45:38 +0000 (19:45 -0800)
committerTony Lindgren <tony@atomide.com>
Tue, 7 Feb 2006 03:45:38 +0000 (19:45 -0800)
omap_i2c_xfer is supposed to return number of messages successfuly
transfered. Remove bogus condition which causes it to fail when
transfering one message.

Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
drivers/i2c/busses/i2c-omap.c

index fb412559b8a1bf7c03e497d58b4daaa80ace19cd..5572e5d467b5474a3903ae5202d2a57991133c71 100644 (file)
@@ -403,7 +403,7 @@ omap_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msgs[], int num)
                        break;
        }
 
-       if (r == 0 && num > 1)
+       if (r == 0)
                r = num;
 out:
        omap_i2c_disable_clocks(dev);