Nova-T 500 Dual DVB-T Oops

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I am looking into the kernel oops I was getting. It is the same problem I posted here:

http://www.linuxtv.org/pipermail/linux-dvb/2006-December/015009.html

Upgraded to the latest FC5 kernel and have switched to a single processor kernel to simplify debugging.

I attach a cleaner couple of oops. It starts with the USB disconnects then a couple of I2C writes which fail as they are not I2C but USB writes then the oops. The first is in 'dvb_dmxdev_buffer_read'. The second oops is in 'dvb_demux_release'. Looking in the specifics of the code the mutex is claimed in release but no in the read. I attach a patch that uncomments the mutex code in the read and also adds the same to the poll function. With this change I have not seen any driver problems for the last couple of days and the USB does not disconnect.

I have had a quick look over the code and it may need further reviews. Someone with a bit more kernel knowledge should review this patch.

Regards
Chris
usb 2-1: USB disconnect, address 2
mt2060 I2C write failed
mt2060 I2C write failed
dvb-usb: Hauppauge Nova-T 500 Dual DVB-T successfully deinitialized and disconnected.
usb 2-1: new high speed USB device using ehci_hcd and address 3
usb 2-1: configuration #1 chosen from 1 choice
dvb-usb: found a 'Hauppauge Nova-T 500 Dual DVB-T' in warm state.
dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer.
DVB: registering new adapter (Hauppauge Nova-T 500 Dual DVB-T).
BUG: unable to handle kernel NULL pointer dereference at virtual address 0000001b
 printing eip:
f8aaaa59
*pde = 39f91067
Oops: 0000 [#1]
last sysfs file: /devices/pci0000:00/0000:00:1e.0/0000:02:02.2/usb2/idVendor
Modules linked in: mt2060(U) dvb_usb_dib0700(U) dib7000m(U) dib7000p(U) dvb_usb(U) dvb_core(U) dvb_pll(U) dib3000mc(U) dibx000_common(U) nfs fscache nfsd exportfs lockd nfs_acl autofs4 it87 hwmon_vid hwmon i2c_isa sunrpc video sbs i2c_ec container button battery asus_acpi ac ipv6 lp parport_pc parport usb_storage snd_emu10k1 snd_rawmidi snd_ac97_codec snd_ac97_bus snd_seq_dummy snd_seq_oss snd_seq_midi_event snd_seq snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_device snd_timer snd_page_alloc snd_util_mem snd_hwdep snd sg skge soundcore serio_raw emu10k1_gp gameport i2c_i801 i2c_core uhci_hcd ide_cd ehci_hcd cdrom pcspkr dm_snapshot dm_zero dm_mirror dm_mod ext3 jbd ata_piix libata sd_mod scsi_mod
CPU:    0
EIP:    0060:[<f8aaaa59>]    Not tainted VLI
EFLAGS: 00010282   (2.6.18-1.2257.fc5 #1) 
EIP is at dvb_dmxdev_buffer_read+0x11/0x14d [dvb_core]
eax: 0000001b   ebx: 0000001b   ecx: ab4b1aac   edx: 00000800
esi: ab4b1aac   edi: 00000000   ebp: ab4b1aac   esp: c2412f40
ds: 007b   es: 007b   ss: 0068
Process mythbackend (pid: 25577, ti=c2412000 task=d04e57b0 task.ti=c2412000)
Stack: c042d6f9 00000800 c05f7c9e c2412e4c c2412e50 d5ccb800 00000000 c2412fa4 
       ab4b1aac ab4b1aac 04f45cfc f8aaabc3 04f45cfc c2412fa4 da00c6c0 f8aaab95 
       c045dfe0 c2412fa4 ab4b1aac da00c6c0 fffffff7 ffffffff c2412000 c045e368 
Call Trace:
 [<f8aaabc3>] dvb_dvr_read+0x2e/0x33 [dvb_core]
 [<c045dfe0>] vfs_read+0xa6/0x157
 [<c045e368>] sys_read+0x41/0x67
 [<c0402da7>] syscall_call+0x7/0xb
DWARF2 unwinder stuck at syscall_call+0x7/0xb
Leftover inexact backtrace:
 =======================
Code: 7a 00 00 f7 d3 83 e3 4b 89 da 83 ca 43 85 c0 0f 44 da 59 89 d8 5b 5b 5e 5f c3 55 89 cd 57 31 ff 56 53 89 c3 83 ec 1c 89 54 24 04 <83> 38 00 0f 84 29 01 00 00 8b 40 10 8b 74 24 30 85 c0 0f 84 f2 
EIP: [<f8aaaa59>] dvb_dmxdev_buffer_read+0x11/0x14d [dvb_core] SS:ESP 0068:c2412f40
 DVB: registering frontend 0 (DiBcom 3000MC/P)...
MT2060: successfully identified (IF1 = 1220)
dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer.
DVB: registering new adapter (Hauppauge Nova-T 500 Dual DVB-T).
DVB: registering frontend 1 (DiBcom 3000MC/P)...
MT2060: successfully identified (IF1 = 1220)
dvb-usb: Hauppauge Nova-T 500 Dual DVB-T successfully initialized and connected.
BUG: unable to handle kernel NULL pointer dereference at virtual address 00000000
 printing eip:
00000000
*pde = 39f91067
Oops: 0000 [#2]
last sysfs file: /devices/platform/i2c-9191/9191-0290/temp3_input
Modules linked in: mt2060(U) dvb_usb_dib0700(U) dib7000m(U) dib7000p(U) dvb_usb(U) dvb_core(U) dvb_pll(U) dib3000mc(U) dibx000_common(U) nfs fscache nfsd exportfs lockd nfs_acl autofs4 it87 hwmon_vid hwmon i2c_isa sunrpc video sbs i2c_ec container button battery asus_acpi ac ipv6 lp parport_pc parport usb_storage snd_emu10k1 snd_rawmidi snd_ac97_codec snd_ac97_bus snd_seq_dummy snd_seq_oss snd_seq_midi_event snd_seq snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_device snd_timer snd_page_alloc snd_util_mem snd_hwdep snd sg skge soundcore serio_raw emu10k1_gp gameport i2c_i801 i2c_core uhci_hcd ide_cd ehci_hcd cdrom pcspkr dm_snapshot dm_zero dm_mirror dm_mod ext3 jbd ata_piix libata sd_mod scsi_mod
CPU:    0
EIP:    0060:[<00000000>]    Not tainted VLI
EFLAGS: 00010017   (2.6.18-1.2257.fc5 #1) 
EIP is at _stext+0x3fbffde0/0x3c
eax: 08d00ea4   ebx: 08d00ea4   ecx: 00000000   edx: 00000003
esi: 00000000   edi: 00000001   ebp: cdb05f3c   esp: cdb05f1c
ds: 007b   es: 007b   ss: 0068
Process mythbackend (pid: 25555, ti=cdb05000 task=e5014f10 task.ti=cdb05000)
Stack: c0416edb 00000000 00000003 f8ccf064 27290000 f8ccf064 00000000 00000001 
       cdb05f60 c0417300 00000000 00000000 00000003 00000292 e00a2d44 f8ccf000 
       00000000 e00a2d9c f8aaadb4 00000000 f8ccf08c 00000008 d73e3124 d73e3124 
Call Trace:
Inexact backtrace:
 [<c0416edb>] __wake_up_common+0x2f/0x53
 [<c0417300>] __wake_up+0x2a/0x3d
 [<f8aaadb4>] dvb_demux_release+0xd8/0xf3 [dvb_core]
 [<c045e726>] __fput+0xba/0x178
 [<c045c062>] filp_close+0x52/0x59
 [<c0402da7>] syscall_call+0x7/0xb
 =======================
Code:  Bad EIP value.
EIP: [<00000000>] _stext+0x3fbffde0/0x3c SS:ESP 0068:cdb05f1c
 <3>BUG: sleeping function called from invalid context at kernel/rwsem.c:20
in_atomic():0, irqs_disabled():1
 [<c0403f28>] dump_trace+0x69/0x1af
 [<c0404086>] show_trace_log_lvl+0x18/0x2c
 [<c0404601>] show_trace+0xf/0x11
 [<c040468b>] dump_stack+0x15/0x17
 [<c042da0c>] down_read+0x12/0x1f
 [<c042635f>] blocking_notifier_call_chain+0xe/0x29
 [<c041d522>] do_exit+0x1b/0x795
 [<c04045a2>] die+0x26b/0x290
 [<c05f99c2>] do_page_fault+0x408/0x4db
 [<c04038b9>] error_code+0x39/0x40
DWARF2 unwinder stuck at error_code+0x39/0x40
Leftover inexact backtrace:
 [<c05f007b>] dump_one_state+0x195/0x364
 [<c0416edb>] __wake_up_common+0x2f/0x53
 [<c0417300>] __wake_up+0x2a/0x3d
 [<f8aaadb4>] dvb_demux_release+0xd8/0xf3 [dvb_core]
 [<c045e726>] __fput+0xba/0x178
 [<c045c062>] filp_close+0x52/0x59
 [<c0402da7>] syscall_call+0x7/0xb
 =======================
invalid opcode: 0000 [#3]
last sysfs file: /devices/platform/i2c-9191/9191-0290/temp3_input
Modules linked in: mt2060(U) dvb_usb_dib0700(U) dib7000m(U) dib7000p(U) dvb_usb(U) dvb_core(U) dvb_pll(U) dib3000mc(U) dibx000_common(U) nfs fscache nfsd exportfs lockd nfs_acl autofs4 it87 hwmon_vid hwmon i2c_isa sunrpc video sbs i2c_ec container button battery asus_acpi ac ipv6 lp parport_pc parport usb_storage snd_emu10k1 snd_rawmidi snd_ac97_codec snd_ac97_bus snd_seq_dummy snd_seq_oss snd_seq_midi_event snd_seq snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_device snd_timer snd_page_alloc snd_util_mem snd_hwdep snd sg skge soundcore serio_raw emu10k1_gp gameport i2c_i801 i2c_core uhci_hcd ide_cd ehci_hcd cdrom pcspkr dm_snapshot dm_zero dm_mirror dm_mod ext3 jbd ata_piix libata sd_mod scsi_mod
CPU:    0
EIP:    0060:[<c11d8868>]    Not tainted VLI
EFLAGS: 00010282   (2.6.18-1.2257.fc5 #1) 
EIP is at 0xc11d8868
eax: d2a764bc   ebx: 00000028   ecx: 80286f4e   edx: d81ef200
esi: 80286f4e   edi: 058447c8   ebp: efd94ecc   esp: efd94eb4
ds: 007b   es: 007b   ss: 0068
Process mythbackend (pid: 22225, ti=efd94000 task=e9342b50 task.ti=efd94000)
Stack: f8aaa10b efd94ecc d81ef200 d2a764bc 00000002 00000000 08c10b38 031145d4 
       08bf9000 05844ae8 058447e8 031145d4 08bf9000 05844ae8 058447f8 030e36c1 
       c059baef e8a29a80 00000000 e8a29a80 c05f890b c059c0ef d81efb00 00000000 
Call Trace:
Inexact backtrace:
 [<f8aaa10b>] dvb_usercopy+0xa9/0x100 [dvb_core]
 [<c059baef>] sock_set_timeout+0x21/0x6d
 [<c05f890b>] _spin_unlock_bh+0x5/0xd
 [<c059c0ef>] sock_setsockopt+0x499/0x4a3
 [<c042b25c>] autoremove_wake_function+0x0/0x35
 [<c059954e>] sockfd_lookup_light+0x24/0x3e
 [<f8aaa197>] dvb_generic_ioctl+0x35/0x3e [dvb_core]
 [<f8aaa162>] dvb_generic_ioctl+0x0/0x3e [dvb_core]
 [<c046cf5e>] do_ioctl+0x3e/0x4d
 [<c046d16c>] vfs_ioctl+0x1ff/0x216
 [<c046d1cf>] sys_ioctl+0x4c/0x65
 [<c0402da7>] syscall_call+0x7/0xb
 =======================
Code: 87 6e c1 00 00 00 80 01 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 02 00 00 00 00 01 10 00 00 02 20 00 00 00 00 80 01 00 00 00 <ff> ff ff ff 00 00 00 00 00 00 00 00 13 f9 0b 00 00 01 10 00 00 
EIP: [<c11d8868>] 0xc11d8868 SS:ESP 0068:efd94eb4
 
--- v4l-dvb-3beb62e206ef/linux/drivers/media/dvb/dvb-core/dmxdev.c~	2007-01-04 22:29:55.000000000 +1100
+++ v4l-dvb-3beb62e206ef/linux/drivers/media/dvb/dvb-core/dmxdev.c	2007-01-02 15:28:37.000000000 +1100
@@ -229,11 +229,11 @@
 	struct dmxdev *dmxdev = dvbdev->priv;
 	int ret;
 
-	//mutex_lock(&dmxdev->mutex);
+	mutex_lock(&dmxdev->mutex);
 	ret = dvb_dmxdev_buffer_read(&dmxdev->dvr_buffer,
 				     file->f_flags & O_NONBLOCK,
 				     buf, count, ppos);
-	//mutex_unlock(&dmxdev->mutex);
+	mutex_unlock(&dmxdev->mutex);
 	return ret;
 }
 
@@ -1007,6 +1007,8 @@
 
 	dprintk("function : %s\n", __FUNCTION__);
 
+	mutex_lock(&dmxdev->mutex);
+
 	poll_wait(file, &dmxdev->dvr_buffer.queue, wait);
 
 	if ((file->f_flags & O_ACCMODE) == O_RDONLY) {
@@ -1018,6 +1020,8 @@
 	} else
 		mask |= (POLLOUT | POLLWRNORM | POLLPRI);
 
+	mutex_unlock(&dmxdev->mutex);
+
 	return mask;
 }
 
_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

[Index of Archives]     [Linux Media]     [Video 4 Linux]     [Asterisk]     [Samba]     [Xorg]     [Xfree86]     [Linux USB]

  Powered by Linux