]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
i2c: designware-baytrail: fix typo in error path
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 10 Feb 2015 17:06:07 +0000 (19:06 +0200)
committerWolfram Sang <wsa@the-dreams.de>
Sat, 7 Mar 2015 00:07:27 +0000 (01:07 +0100)
It seems we have same message for different return values in get_sem() and
baytrail_i2c_acquire(). I suspect this is just a typo, so this patch fixes it.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: David E. Box <david.e.box@linux.intel.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-designware-baytrail.c

index e9cb3555dc79194f51e0342bd227bb6796007601..9b6765554c70480fcbbec1ac876c290134d93209 100644 (file)
@@ -99,8 +99,8 @@ int baytrail_i2c_acquire(struct dw_i2c_dev *dev)
        reset_semaphore(dev->dev);
 
        ret = iosf_mbi_read(BT_MBI_UNIT_PMC, BT_MBI_BUNIT_READ,
-               PUNIT_SEMAPHORE, &sem);
-       if (!ret)
+                               PUNIT_SEMAPHORE, &sem);
+       if (ret)
                dev_err(dev->dev, "iosf failed to read punit semaphore\n");
        else
                dev_err(dev->dev, "PUNIT SEM: %d\n", sem);