diff options
author | Tushar Behera <tushar.behera@linaro.org> | 2011-12-09 11:03:55 +0100 |
---|---|---|
committer | Ben Dooks <ben-linux@fluff.org> | 2011-12-18 12:44:49 +0100 |
commit | 8ebe661dd2ab16e2e9c272ed5c86019c7407b9a1 (patch) | |
tree | 1564c871fa735b1c16713a08d2df95e3cf1f01f2 /drivers/i2c | |
parent | i2c: i2c-s3c2410: Add a cpu_relax() to busy wait for bus idle (diff) | |
download | linux-8ebe661dd2ab16e2e9c272ed5c86019c7407b9a1.tar.xz linux-8ebe661dd2ab16e2e9c272ed5c86019c7407b9a1.zip |
i2c-s3c2410: Fix return code of s3c24xx_i2c_parse_dt_gpio
s3c24xx_i2c_parse_dt_gpio is called when cfg_gpio is not defined
in the platform data of the i2c device. When DT is not enabled,
the above function always returns -EINVAL. Since there can be
some i2c devices which don't need to configure any gpio lines,
the probe of such devices would fail here. Changing the default
return value to success would fix this issue.
Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-s3c2410.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c index 37b2de106808..4c1718081685 100644 --- a/drivers/i2c/busses/i2c-s3c2410.c +++ b/drivers/i2c/busses/i2c-s3c2410.c @@ -787,7 +787,7 @@ static void s3c24xx_i2c_dt_gpio_free(struct s3c24xx_i2c *i2c) #else static int s3c24xx_i2c_parse_dt_gpio(struct s3c24xx_i2c *i2c) { - return -EINVAL; + return 0; } static void s3c24xx_i2c_dt_gpio_free(struct s3c24xx_i2c *i2c) |