[patch 23/37] V4L: msp_attach must return 0 if no msp3400 was found.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Greg KH
Date: Friday, March 30, 2007 - 2:06 pm

-stable review patch.  If anyone has any objections, please let us know.

------------------
From: Hans Verkuil <hverkuil@xs4all.nl>

V4L: msp_attach must return 0 if no msp3400 was found.

Returning -1 causes the probe to stop, but it should just continue
instead. This patch fixes an annoying 'i2c_adapter i2c-7: Client
creation failed at 0x44 (-1)' kernel message that appeared in 2.6.20

(cherry picked from commit 3284b4e077cb2322754ea7455b8f8af7ce3777b8)

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

---
 drivers/media/video/msp3400-driver.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/drivers/media/video/msp3400-driver.c
+++ b/drivers/media/video/msp3400-driver.c
@@ -825,7 +825,7 @@ static int msp_attach(struct i2c_adapter
 	if (msp_reset(client) == -1) {
 		v4l_dbg(1, msp_debug, client, "msp3400 not found\n");
 		kfree(client);
-		return -1;
+		return 0;
 	}
 
 	state = kmalloc(sizeof(*state), GFP_KERNEL);
@@ -859,7 +859,7 @@ static int msp_attach(struct i2c_adapter
 		v4l_dbg(1, msp_debug, client, "not an msp3400 (cannot read chip version)\n");
 		kfree(state);
 		kfree(client);
-		return -1;
+		return 0;
 	}
 
 	msp_set_audio(client);

-- 
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch 00/37] 2.6.20-stable review, Greg KH, (Fri Mar 30, 2:03 pm)
[patch 04/37] UML - fix epoll, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 05/37] UML - host VDSO fix, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 06/37] UML - Fix static linking, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 06/37] UML - Fix static linking, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 08/37] uml: fix unreasonably long udelay, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 13/37] PPP: Fix PPP skb leak, Greg KH, (Fri Mar 30, 2:04 pm)
[patch 18/37] Fix decnet endianness, Greg KH, (Fri Mar 30, 2:05 pm)
[patch 19/37] NET: Fix FIB rules compatability, Greg KH, (Fri Mar 30, 2:05 pm)
[patch 22/37] V4L: Fix SECAM handling on saa7115, Greg KH, (Fri Mar 30, 2:05 pm)
[patch 23/37] V4L: msp_attach must return 0 if no msp3400 ..., Greg KH, (Fri Mar 30, 2:06 pm)
[patch 28/37] i2o: block IO errors on i2o disk, Greg KH, (Fri Mar 30, 2:06 pm)
[patch 34/37] libata bugfix: HDIO_DRIVE_TASK, Greg KH, (Fri Mar 30, 2:06 pm)
[patch 36/37] libata: sata_mv: Fix 50xx irq mask, Greg KH, (Fri Mar 30, 2:07 pm)
Re: [patch 00/37] 2.6.20-stable review, Greg KH, (Fri Mar 30, 2:10 pm)
Re: [patch 34/37] libata bugfix: HDIO_DRIVE_TASK, Mark Lord, (Fri Mar 30, 2:42 pm)
libata bugfix: preserve LBA bit for HDIO_DRIVE_TASK, Mark Lord, (Fri Mar 30, 2:45 pm)
Re: [uml-devel] [patch 06/37] UML - Fix static linking, Blaisorblade, (Fri Mar 30, 6:21 pm)
Re: [patch 00/37] 2.6.20-stable review, Chuck Ebbert, (Wed Apr 4, 7:28 am)