diff mbox

[v3,1/2] em28xx: Ignore errors while reading from eeprom

Message ID 15f3ba8371344a8dac830797216c06e9c5524a81.1493776983.git.mchehab@s-opensource.com (mailing list archive)
State New, archived
Headers show

Commit Message

Mauro Carvalho Chehab May 3, 2017, 2:12 a.m. UTC
While testing support for Terratec H6 rev. 2, it was noticed
that reading from eeprom there causes a timeout error.

Apparently, this is due to the need of properly setting GPIOs.

In any case, the driver doesn't really require eeprom reading
to succeed, as this is currently used only for debug.

So, Ignore such errors.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/usb/em28xx/em28xx-i2c.c | 2 --
 1 file changed, 2 deletions(-)

Comments

Frank Schäfer May 7, 2017, 5:55 p.m. UTC | #1
Am 03.05.2017 um 04:12 schrieb Mauro Carvalho Chehab:
> While testing support for Terratec H6 rev. 2, it was noticed
> that reading from eeprom there causes a timeout error.
>
> Apparently, this is due to the need of properly setting GPIOs.
>
> In any case, the driver doesn't really require eeprom reading
> to succeed, as this is currently used only for debug.
>
> So, Ignore such errors.
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
> ---
>  drivers/media/usb/em28xx/em28xx-i2c.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/media/usb/em28xx/em28xx-i2c.c b/drivers/media/usb/em28xx/em28xx-i2c.c
> index 8c472d5adb50..60b195c157b8 100644
> --- a/drivers/media/usb/em28xx/em28xx-i2c.c
> +++ b/drivers/media/usb/em28xx/em28xx-i2c.c
> @@ -982,8 +982,6 @@ int em28xx_i2c_register(struct em28xx *dev, unsigned bus,
>  			dev_err(&dev->intf->dev,
>  				"%s: em28xx_i2_eeprom failed! retval [%d]\n",
>  				__func__, retval);
> -
> -			return retval;
>  		}
>  	}
>  
Makes sense.

Acked-by: Frank Schäfer <fschaefer.oss@googlemail.com>
diff mbox

Patch

diff --git a/drivers/media/usb/em28xx/em28xx-i2c.c b/drivers/media/usb/em28xx/em28xx-i2c.c
index 8c472d5adb50..60b195c157b8 100644
--- a/drivers/media/usb/em28xx/em28xx-i2c.c
+++ b/drivers/media/usb/em28xx/em28xx-i2c.c
@@ -982,8 +982,6 @@  int em28xx_i2c_register(struct em28xx *dev, unsigned bus,
 			dev_err(&dev->intf->dev,
 				"%s: em28xx_i2_eeprom failed! retval [%d]\n",
 				__func__, retval);
-
-			return retval;
 		}
 	}