summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2013-11-18 17:03:08 +0400
committerWolfram Sang <wsa@the-dreams.de>2013-11-18 23:26:23 +0400
commitcfff1f4a9367bfe0d88413e8807f8369e9564729 (patch)
treeebdf2e781f5daffa767ae92a7848024e84b2f8fd
parent5e47eec00425830bfaf30f80a1a4f603dc60ae93 (diff)
downloadlinux-cfff1f4a9367bfe0d88413e8807f8369e9564729.tar.xz
i2c: bcm-kona: fix error return code in bcm_kona_i2c_probe()
Fix to return a negative error code from the bus speed parse error handling case instead of 0. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Reviewed-by: Tim Kryger <tim.kryger@linaro.org> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
-rw-r--r--drivers/i2c/busses/i2c-bcm-kona.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-bcm-kona.c b/drivers/i2c/busses/i2c-bcm-kona.c
index 7b7b7622b0d1..eb1ce6e4523a 100644
--- a/drivers/i2c/busses/i2c-bcm-kona.c
+++ b/drivers/i2c/busses/i2c-bcm-kona.c
@@ -792,7 +792,8 @@ static int bcm_kona_i2c_probe(struct platform_device *pdev)
}
/* Parse bus speed */
- if (bcm_kona_i2c_assign_bus_speed(dev))
+ rc = bcm_kona_i2c_assign_bus_speed(dev);
+ if (rc)
goto probe_disable_clk;
/* Enable internal clocks */