All of lore.kernel.org
 help / color / mirror / Atom feed
* bttv, tvaudio and ir-kbd-i2c probing conflict
@ 2009-03-15 12:44 Hans Verkuil
  2009-03-15 17:12 ` Jean Delvare
  2009-03-16 11:35 ` Andy Walls
  0 siblings, 2 replies; 27+ messages in thread
From: Hans Verkuil @ 2009-03-15 12:44 UTC (permalink / raw)
  To: linux-media; +Cc: Mauro Carvalho Chehab, Jean Delvare

Hi Mauro, Jean,

When converting the bttv driver to v4l2_subdev I found one probing conflict 
between tvaudio and ir-kbd-i2c: address 0x96 (or 0x4b in 7-bit notation).

It turns out that this is one and the same PIC16C54 device used on the 
ProVideo PV951 board. This chip is used for both audio input selection and 
for IR handling.

But the tvaudio module does the audio part and the ir-kbd-i2c module does 
the IR part. I have truly no idea how this should be handled in the new 
situation. For that matter, I wonder whether it ever worked at all since my 
understanding is that once you called i2c_attach_client for a particular 
address, you cannot do that a second time. So depending on which module 
happens to register itself first, you either have working audio or working 
IR, but not both.

It might work if you use lirc, since that uses low-level i2c access 
(right?). But I can't see how it can work with ir-kbd-i2c and tvaudio at 
the same time.

Did some googling and this seems to confirm my analysis:

http://lists.zerezo.com/video4linux/msg21328.html

Ideas on a postcard, please... :-)

Regards,

	Hans

-- 
Hans Verkuil - video4linux developer - sponsored by TANDBERG

^ permalink raw reply	[flat|nested] 27+ messages in thread
* Re: bttv, tvaudio and ir-kbd-i2c probing conflict
@ 2009-03-16 11:56 Hans Verkuil
  0 siblings, 0 replies; 27+ messages in thread
From: Hans Verkuil @ 2009-03-16 11:56 UTC (permalink / raw)
  To: Andy Walls; +Cc: linux-media, Mauro Carvalho Chehab, Jean Delvare


> On Sun, 2009-03-15 at 13:44 +0100, Hans Verkuil wrote:
>> Hi Mauro, Jean,
>>
>> When converting the bttv driver to v4l2_subdev I found one probing
>> conflict
>> between tvaudio and ir-kbd-i2c: address 0x96 (or 0x4b in 7-bit
>> notation).
>>
>> It turns out that this is one and the same PIC16C54 device used on the
>> ProVideo PV951 board. This chip is used for both audio input selection
>> and
>> for IR handling.
>
>
> Hans,
>
> Just a thought: have you confirmed with i2cdetect that the PIC16C54
> microcontroller code only responds at one I2C address?

I don't have this board, so I can't test it. Everything points to this
being a multifunction device responding to one i2c address. It's one of
those programmable devices, so that seems perfectly reasonably to me.

In general I'm not inclined to worry about this case. As Jean said, the
core problem is not so much the perceived lack of i2c support for such
devices, but that the IR and (to a lesser extent) tvaudio modules are
badly designed. The IR module should really become a v4l2_subdev as well,
loaded on command by the adapter driver, and v4l2_subdev should acquire
one or more ops to handle IR stuff. With that in place it is easy to move
the pic support from tvaudio and the IR module into a module of its own.

Simple and effective it solves this whole issue elegantly.

Regards,

       Hans

-- 
Hans Verkuil - video4linux developer - sponsored by TANDBERG


^ permalink raw reply	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2009-03-17 20:23 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-15 12:44 bttv, tvaudio and ir-kbd-i2c probing conflict Hans Verkuil
2009-03-15 17:12 ` Jean Delvare
2009-03-15 17:42   ` Trent Piepho
2009-03-15 17:53     ` Jean Delvare
2009-03-16  9:08       ` Mauro Carvalho Chehab
2009-03-16  9:34       ` Mauro Carvalho Chehab
2009-03-16 11:18         ` Jean Delvare
2009-03-16 12:52           ` Mauro Carvalho Chehab
2009-03-16 14:28             ` Jean Delvare
2009-03-16 15:31               ` Mauro Carvalho Chehab
2009-03-16 19:43               ` Trent Piepho
2009-03-16 21:40                 ` Jean Delvare
2009-03-16 21:58                   ` Hans Verkuil
2009-03-16 22:47                   ` Trent Piepho
2009-03-17  9:31                     ` Jean Delvare
2009-03-17 20:23                       ` Trent Piepho
2009-03-15 19:34   ` Andy Walls
2009-03-15 22:09     ` Hans Verkuil
2009-03-15 22:28       ` Jean Delvare
2009-03-15 22:26     ` Jean Delvare
2009-03-16  0:52       ` Andy Walls
2009-03-16  4:26         ` hermann pitton
2009-03-16 12:58         ` Jean Delvare
2009-03-15 23:46     ` Trent Piepho
2009-03-16  8:35       ` Jean Delvare
2009-03-16 11:35 ` Andy Walls
  -- strict thread matches above, loose matches on Subject: below --
2009-03-16 11:56 Hans Verkuil

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.