summaryrefslogtreecommitdiff
path: root/drivers/i2c
diff options
context:
space:
mode:
authorWenyou Yang <wenyou.yang@atmel.com>2016-09-27 11:00:32 +0800
committerAndreas Bießmann <andreas@biessmann.org>2016-10-28 18:37:14 +0200
commit52f37333bc3277cf182e4afb9d59ef2c6f09816e (patch)
treea806e5a6232fbfcc10877772e361cfc2a29b4133 /drivers/i2c
parent2ccc07bbdcd85878aa02cf4afb8aa5ed7ef1b446 (diff)
downloadu-boot-imx-52f37333bc3277cf182e4afb9d59ef2c6f09816e.zip
u-boot-imx-52f37333bc3277cf182e4afb9d59ef2c6f09816e.tar.gz
u-boot-imx-52f37333bc3277cf182e4afb9d59ef2c6f09816e.tar.bz2
i2c: at91_i2c: Change error return -ENODEV to -EINVAL
Change the error return value -ENODEV from to -EINVAL for more reasonable. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Heiko Schocher <hs@denx.de>
Diffstat (limited to 'drivers/i2c')
-rw-r--r--drivers/i2c/at91_i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/at91_i2c.c b/drivers/i2c/at91_i2c.c
index dcd3ce8..4bc54ee 100644
--- a/drivers/i2c/at91_i2c.c
+++ b/drivers/i2c/at91_i2c.c
@@ -190,7 +190,7 @@ static int at91_i2c_enable_clk(struct udevice *dev)
clk_rate = clk_get_rate(&clk);
if (!clk_rate)
- return -ENODEV;
+ return -EINVAL;
bus->bus_clk_rate = clk_rate;