-------- Original Message -------- Subject: Re: Almost working CX88 I2C patch Date: Fri, 18 Aug 2006 09:54:56 -0300 From: Mauro Carvalho Chehab To: Manu Abraham CC: Michael Krufky References: <1155902362.6720.34.camel@praia> <44E5AD2D.3040303@gmail.com> <44E5ADF3.2000604@m1k.net> <44E5B0CE.8000207@gmail.com> <1155904420.6720.42.camel@praia> <44E5B684.6090803@gmail.com> Em Sex, 2006-08-18 às 16:45 +0400, Manu Abraham escreveu: > Mauro Carvalho Chehab wrote: > > > > > Anyway, this is not the final patch yet. There's something wrong with > > error returning to I2C core, since I2C core is not correctly > > understanding when a device is not present at the i2c bus. > > It won't get fixed the way as you might think as there are other issues, > because you depend on kernel i2c alone. Hardware I2C as it is will work > only for DVB devices. ie, i2c scanning won't work with HW I2C. > > I have an updated patch as well, which fixes some more issues. (Well, > those suggestions were from Christoph) So, as I said on my previous email, better to go to (2), creating a common code, saying that you've got contributions from Christoph and me. Let's try to merge all into just one patch. The one I sent is cleaner, in the sense that it avoids duplicating hardware init code at all 3 modules. It also keep i2c de-registering inside cx88-i2c, and provide a code that will un-register both i2c modes (bitbanging and hardware). > But in that case also, scanning > will not work as explained by Johannes in a thread on v4l-dvb-maintainer > some time back, which was reminded to me by Ralph as well. I'm sorry to inform that both Johannes and Ralph are wrong on this subject. Several drivers use hardware I2C and scan works fine (for example, em28xx and saa7134). I saw some codes inside drivers/i2c/* that uses an hybrid approach on some broken hardware: they use bitbang for i2c scan and hardware I2C for all the rest. This would be a last resort for this. > > Regards, > Manu Cheers, Mauro.