summaryrefslogtreecommitdiff
path: root/linux/drivers/media/common
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/common')
-rw-r--r--linux/drivers/media/common/tuners/tea5767.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/linux/drivers/media/common/tuners/tea5767.c b/linux/drivers/media/common/tuners/tea5767.c
index e5bfc72a4..5990a63ef 100644
--- a/linux/drivers/media/common/tuners/tea5767.c
+++ b/linux/drivers/media/common/tuners/tea5767.c
@@ -380,14 +380,14 @@ int tea5767_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr)
if ((rc = tuner_i2c_xfer_recv(&i2c, buffer, 7))< 5) {
printk(KERN_WARNING "It is not a TEA5767. Received %i bytes.\n", rc);
- return EINVAL;
+ return -EINVAL;
}
/* If all bytes are the same then it's a TV tuner and not a tea5767 */
if (buffer[0] == buffer[1] && buffer[0] == buffer[2] &&
buffer[0] == buffer[3] && buffer[0] == buffer[4]) {
printk(KERN_WARNING "All bytes are equal. It is not a TEA5767\n");
- return EINVAL;
+ return -EINVAL;
}
/* Status bytes:
@@ -397,14 +397,14 @@ int tea5767_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr)
*/
if (((buffer[3] & 0x0f) != 0x00) || (buffer[4] != 0x00)) {
printk(KERN_WARNING "Chip ID is not zero. It is not a TEA5767\n");
- return EINVAL;
+ return -EINVAL;
}
#if 0 /* Not working for TEA5767 in Beholder Columbus card */
/* It seems that tea5767 returns 0xff after the 5th byte */
if ((buffer[5] != 0xff) || (buffer[6] != 0xff)) {
printk(KERN_WARNING "Returned more than 5 bytes. It is not a TEA5767\n");
- return EINVAL;
+ return -EINVAL;
}
#endif
@@ -425,7 +425,7 @@ int tea5767_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr)
if (5 != (rc = tuner_i2c_xfer_recv(&i2c, buffer, 5))) {
printk(KERN_WARNING "It is not a TEA5767. Received %i bytes.\n", rc);
- return EINVAL;
+ return -EINVAL;
}
/* Initial freq for 32.768KHz clock */
@@ -433,7 +433,7 @@ int tea5767_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr)
printk(KERN_WARNING "It is not a TEA5767. div=%d, Return: %02x %02x %02x %02x %02x\n",
div,buffer[0],buffer[1],buffer[2],buffer[3],buffer[4]);
tea5767_status_dump(buffer);
- return EINVAL;
+ return -EINVAL;
}
#endif
return 0;
@@ -490,8 +490,8 @@ struct dvb_frontend *tea5767_attach(struct dvb_frontend *fe,
struct tea5767_priv *priv = NULL;
#if 0 /* By removing autodetection allows forcing TEA chip */
- if (tea5767_autodetection(i2c_adap, i2c_addr) == EINVAL)
- return EINVAL;
+ if (tea5767_autodetection(i2c_adap, i2c_addr) == -EINVAL)
+ return -EINVAL;
#endif
priv = kzalloc(sizeof(struct tea5767_priv), GFP_KERNEL);
if (priv == NULL)