On Tue, May 08, 2007 at 12:37:22PM +1000, Jeremy Nysen wrote: > The following modifications to the m920x_probe() function in m920x.c > should fix the problem with the second tuner on the TVWalker Twin USB > tuner. Please feel free to refactor and integrate these changes into the > main source tree. > > I have the TVWalker Twin USB working with both adapters on MythTV and > mplayer. There are no spurious adapters in the /dev/dvb/, and Nice work. So it's just a matter of falling through when probing interface #1 ? > // Initialize the remote control, but only once per adapter > if ( (bInterfaceNumber == 0) && ((ret = m920x_init(d, rc_init_seq)) > != 0) ) > return ret; This could also be done by testing rc_init_seq ... if (rc_init_seq) { ret = m920x_init(d, rc_init_seq); } return ret; I'll test this tonight. Actually no, I'll test it now. > /proc/bus/usb/devices shows all four interfaces as handled by dev_usb_m920x. Ah, if I'd known more about usb I might have figured that out. Mine currently shows: T: Bus=01 Lev=01 Prnt=01 Port=06 Cnt=01 Dev#= 3 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1 P: Vendor=10fd ProdID=0513 Rev= 0.95 S: Manufacturer=LifeView S: Product=DVB-T C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=100mA I: If#= 0 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=dvb_usb_m920x E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 0 Alt= 1 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=dvb_usb_m920x E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 1 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 1 Alt= 1 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms T: Bus=01 Lev=01 Prnt=01 Port=09 Cnt=02 Dev#= 5 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1 P: Vendor=10fd ProdID=0513 Rev= 0.95 S: Manufacturer=LifeView S: Product=DVB-T C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=100mA I: If#= 0 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=dvb_usb_m920x E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 0 Alt= 1 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=dvb_usb_m920x E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 1 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 1 Alt= 1 #EPs= 1 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms ... endpoint address 0x82 doesn't have a driver assigned ... Testing ... nope, I get an oops on the insmod. This is with 2.6.20 ... May 8 15:05:29 omega kernel: Probing for m920x device at interface 0 May 8 15:05:29 omega kernel: dvb-usb: found a 'LifeView TV Walker Twin DVB-T USB2.0' in warm state. May 8 15:05:29 omega kernel: dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer. May 8 15:05:29 omega kernel: DVB: registering new adapter (LifeView TV Walker Twin DVB-T USB2.0). May 8 15:05:29 omega kernel: m920x_tda10046_08_frontend_attach May 8 15:05:29 omega kernel: DVB: registering frontend 0 (Philips TDA10046H DVB-T)... May 8 15:05:29 omega kernel: m920x_tda8275_60_tuner_attach May 8 15:05:29 omega kernel: input: IR-receiver inside an USB DVB receiver as /class/input/input16 May 8 15:05:29 omega kernel: dvb-usb: schedule remote query interval to 100 msecs. May 8 15:05:29 omega kernel: dvb-usb: LifeView TV Walker Twin DVB-T USB2.0 successfully initialized and connected. May 8 15:05:29 omega kernel: Initialising remote control May 8 15:05:29 omega kernel: Initialising remote control success May 8 15:05:29 omega kernel: Probing for m920x device at interface 1 May 8 15:05:29 omega kernel: BUG: unable to handle kernel paging request at virtual address 08357282 May 8 15:05:29 omega kernel: printing eip: May 8 15:05:29 omega kernel: c02e3f7d May 8 15:05:29 omega kernel: *pde = 6760f067 May 8 15:05:29 omega kernel: Oops: 0000 [#1] May 8 15:05:29 omega kernel: PREEMPT SMP May 8 15:05:29 omega kernel: Modules linked in: dvb_usb_m920x fuse tda827x tda1004x dvb_usb dvb_pll firmware_class nvidia(P) vmnet(P) vmmon(P) ipv6 snd_pcm_oss snd_mixer_oss snd_hda_intel snd_hda_codec snd_pcm snd_seq_dummy snd_seq_oss snd_seq_midi_event snd_seq snd_timer snd_seq_device ohci1394 ieee1394 snd parport_pc parport ohci_hcd ehci_hcd snd_page_alloc sr_mod forcedeth dm_mirror dm_crypt dm_mod cbc blkcipher aes sha256 May 8 15:05:29 omega kernel: CPU: 0 May 8 15:05:29 omega kernel: EIP: 0060:[<c02e3f7d>] Tainted: P VLI May 8 15:05:29 omega kernel: EFLAGS: 00010286 (2.6.20-nick3 #10) May 8 15:05:29 omega kernel: EIP is at usb_set_interface+0xd/0x1c0 May 8 15:05:29 omega kernel: eax: 0835726e ebx: 00000001 ecx: 00000001 edx: 00000001 May 8 15:05:29 omega kernel: esi: 0835726e edi: f7ae4400 ebp: f8a5c414 esp: f3469db4 May 8 15:05:29 omega kernel: ds: 007b es: 007b ss: 0068 May 8 15:05:29 omega kernel: Process insmod (pid: 27780, ti=f3468000 task=f747f560 task.ti=f3468000) May 8 15:05:29 omega kernel: Stack: c040cceb 00000000 0000a1ff f7b24954 c019dcdc 00000001 f8a5c3e0 f7ae4400 May 8 15:05:29 omega kernel: f8a5c414 00000001 00000000 00000000 f7ae4400 f8a5a284 f8a5b2b8 00000001 May 8 15:05:29 omega kernel: 00000000 e84f6ae0 f8a5da9c f7ae4400 c8ec5d00 f7ae4400 f8a5c3e0 c8ec5d00 May 8 15:05:29 omega kernel: Call Trace: May 8 15:05:29 omega kernel: [<c019dcdc>] sysfs_make_dirent+0x1c/0x90 May 8 15:05:29 omega kernel: [<f8a5a284>] m920x_probe+0x74/0x200 [dvb_usb_m920x] May 8 15:05:29 omega kernel: [<c02e525b>] usb_probe_interface+0x6b/0xb0 May 8 15:05:29 omega kernel: [<c0287074>] really_probe+0x54/0x140 May 8 15:05:29 omega kernel: [<c02871a9>] driver_probe_device+0x49/0xc0 May 8 15:05:29 omega kernel: [<c03935fd>] klist_next+0x5d/0xa0 May 8 15:05:29 omega kernel: [<c0287330>] __driver_attach+0x80/0x90 May 8 15:05:29 omega kernel: [<c028657a>] bus_for_each_dev+0x3a/0x60 May 8 15:05:29 omega kernel: [<c0286f16>] driver_attach+0x16/0x20 May 8 15:05:29 omega kernel: [<c02872b0>] __driver_attach+0x0/0x90 May 8 15:05:29 omega kernel: [<c02868eb>] bus_add_driver+0x7b/0x190 May 8 15:05:29 omega kernel: [<c02e4d32>] usb_register_driver+0x82/0x100 May 8 15:05:29 omega kernel: [<c03945d7>] wait_for_completion+0xb7/0xc0 May 8 15:05:29 omega kernel: [<c013a1c0>] __link_module+0x0/0x20 May 8 15:05:29 omega kernel: [<f8a7a013>] m920x_module_init+0x13/0x30 [dvb_usb_m920x] May 8 15:05:29 omega kernel: [<c013b10d>] sys_init_module+0x15d/0x1b50 May 8 15:05:29 omega kernel: [<c0143c5d>] filemap_nopage+0x2fd/0x400 May 8 15:05:29 omega kernel: [<c02170cb>] _atomic_dec_and_lock+0x3b/0x70 May 8 15:05:29 omega kernel: [<c010318c>] syscall_call+0x7/0xb May 8 15:05:29 omega kernel: ======================= May 8 15:05:29 omega kernel: Code: 45 e8 08 35 00 00 8b 4c 24 18 0f b6 41 04 39 e8 7f bb 31 c0 83 c4 1c 5b 5e 5f 5d c3 89 f6 83 ec 34 89 74 24 28 89 c6 89 5c 24 24 <83> 7e 14 08 89 7c 24 2c 89 cb 89 6c 24 30 89 d7 b8 8f ff ff ff May 8 15:05:29 omega kernel: EIP: [<c02e3f7d>] usb_set_interface+0xd/0x1c0 SS:ESP 0068:f3469db4 Nick. _______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb