bttv driver sometimes oopses

From: Koos Vriezen (j.jvriezen@freeler.nl)
Date: Sat Oct 07 2000 - 16:00:52 EST


Hi,

Since i2c was added to the kernel, I have sometimes trouble with my bttv
card. Before that, I never had any trouble with bttv since kernel 2.2.0.
The modules are loaded when I start X with vidmode extension turned on. When
everything goes well I see the following in my syslog:

 kernel: Linux video capture interface: v1.00
 kernel: i2c-core.o: i2c core module
 kernel: i2c-algo-bit.o: i2c bit algorithm module
 kernel: bttv: driver version 0.7.38 loaded
 kernel: bttv: using 2 buffers with 1040k (2080k total) for capture
 kernel: bttv: Bt8xx card found (0).
 kernel: bttv0: Brooktree Bt878 (rev 2) bus: 0, devfn: 80, irq: 9, memory:
0xe7000000.
 kernel: i2c-algo-bit.o: Adapter: bt848 #0 scl: 1 sda: 1 -- testing...
 kernel: i2c-algo-bit.o:1 scl: 1 sda: 0
 kernel: i2c-algo-bit.o:2 scl: 1 sda: 1
 kernel: i2c-algo-bit.o:3 scl: 0 sda: 1
 kernel: i2c-algo-bit.o:4 scl: 1 sda: 1
 kernel: i2c-algo-bit.o: bt848 #0 passed test.
 kernel: bttv0: i2c: checking for eeprom @ 0xa0... found
 kernel: bttv0: card id: Hauppauge WinTV (0x13eb0070) => card=10
 kernel: bttv0: model: BT878(Hauppauge new (bt878)) [insmod option]
 kernel: bttv0: Hauppauge eeprom: tuner=Philips FM1216 (5)
 kernel: bttv0: Hauppauge msp34xx: reset line init
 kernel: bttv0: i2c: checking for MSP34xx @ 0x80... found
 kernel: i2c-algo-bit.o: Adapter: bt848 #0 scl: 1 sda: 1 -- testing...
 kernel: i2c-algo-bit.o:1 scl: 1 sda: 0
 kernel: i2c-algo-bit.o:2 scl: 1 sda: 1
 kernel: i2c-algo-bit.o:3 scl: 0 sda: 1
 kernel: i2c-algo-bit.o:4 scl: 1 sda: 1
 kernel: i2c-algo-bit.o: bt848 #0 passed test.
 kernel: bttv0: i2c: checking for MSP34xx @ 0x80... found
 kernel: msp3400: init: chip=MSP3410D-B4, has NICAM support
 kernel: msp3410: daemon started
 kernel: bttv0: i2c attach [MSP3410D-B4]
 kernel: bttv0: i2c: checking for TDA8425 @ 0x82... not found
 kernel: bttv0: i2c: checking for TDA985x @ 0xb6... not found
 kernel: bttv0: i2c: checking for TDA9875 @ 0xb0... not found
 kernel: tuner: chip found @ 0x61
 kernel: bttv0: i2c attach [Philips PAL]
 modprobe: modprobe: Can't locate module char-major-81-1
 modprobe: modprobe: Can't locate module sound-slot-1
 modprobe: modprobe: Can't locate module sound-service-1-0
 modprobe: modprobe: Can't locate module sound-slot-1
 modprobe: modprobe: Can't locate module sound-service-1-0

Except that I don't know which aliases to use for the tvmixer. What are they?
Anyway, when it goes wrong I see:

 kernel: Linux video capture interface: v1.00
 kernel: i2c-core.o: i2c core module
 kernel: i2c-algo-bit.o: i2c bit algorithm module
 kernel: bttv: driver version 0.7.38 loaded
 kernel: bttv: using 2 buffers with 1040k (2080k total) for capture
 kernel: bttv: Bt8xx card found (0).
 kernel: bttv0: Brooktree Bt878 (rev 2) bus: 0, devfn: 80, irq: 9, memory:
0xe7000000.
 kernel: i2c-algo-bit.o: Adapter: bt848 #0 scl: 1 sda: 0 -- testing...
 kernel: i2c-algo-bit.o:1 scl: 1 sda: 0
 kernel: i2c-algo-bit.o:2 scl: 1 sda: 1
 kernel: i2c-algo-bit.o: bt848 #0 SDA stuck low!
 kernel: bttv0: model: BT878(Hauppauge new (bt878)) [insmod option]
 kernel: bttv: readee error
 kernel: bttv0: Hauppauge eeprom: tuner= (4)
 kernel: bttv0: Hauppauge msp34xx: reset line init
 kernel: i2c-core.o: unregister_adapter adap [bt848 #0] not found.
 kernel: i2c-algo-bit.o: Adapter: bt848 #0 scl: 1 sda: 1 -- testing...
 kernel: i2c-algo-bit.o:1 scl: 1 sda: 0
 kernel: i2c-algo-bit.o:2 scl: 1 sda: 1
 kernel: i2c-algo-bit.o:3 scl: 0 sda: 1
 kernel: i2c-algo-bit.o:4 scl: 1 sda: 1
 kernel: i2c-algo-bit.o: bt848 #0 passed test.
 kernel: tuner: chip found @ 0x61
 kernel: bttv0: i2c attach [Philips PAL]
 modprobe: modprobe: Can't locate module char-major-81-1
 modprobe: modprobe: Can't locate module sound-slot-1
 modprobe: modprobe: Can't locate module sound-service-1-0
 modprobe: modprobe: Can't locate module sound-slot-1
 modprobe: modprobe: Can't locate module sound-service-1-0

I can fix this by manually removing the bttv module, before starting XawTV.
But when I don't do that, next will happen:

 kernel: Unable to handle kernel paging request at virtual address c48a5a98
 kernel: printing eip:
 kernel: c4893594
 kernel: *pde = 03dd7063
 kernel: *pte = 00000000
 kernel: Oops: 0000
 kernel: CPU: 0
 kernel: EIP: 0010:[<c4893594>]
 kernel: EFLAGS: 00010246
 kernel: eax: c48a5a98 ebx: c48bd000 ecx: c48bfde0 edx: c48a5a98
 kernel: esi: c48bb000 edi: c48a5a40 ebp: 00000000 esp: c3aa3f68
 kernel: ds: 0018 es: 0018 ss: 0018
 kernel: Process rmmod (pid: 1839, stackpage=c3aa3000)
 kernel: Stack: c48bd000 c48bb000 c48bd000 bfffedf8 c4895e88 c48a5a98
c4895e9c 00000001
 kernel: 00000001 c48bed0a c48bfde0 c0116213 c48bd000 c48bb000
00000000 bfffedf8
 kernel: c011572e c48bd000 00000001 c3aa2000 00000061 bfffedf8
c0108d23 00000000
 kernel: Call Trace: [<c48bd000>] [<c48bb000>] [<c48bd000>] [<c4895e88>]
[<c48a5a98>] [<c4895e9c>] [<c48bed0a>]
 kernel: [<c48bfde0>] [free_module+23/152] [<c48bd000>] [<c48bb000>]
[sys_delete_module+378/448] [<c48bd000>] [system_call+51/64]
 kernel: Code: 8b 1c aa 85 db 74 37 8b 4c 24 28 39 4b 30 75 2e 83 3d 80 5d

$ ./ksymoops -m /boot/System.map < ../Oops
Unable to handle kernel paging request at virtual address c48a5a98
c4893594
*pde = 03dd7063
Oops: 0000
CPU: 0
EIP: 0010:[<c4893594>]
Using defaults from ksymoops -t elf32-i386 -a i386
EFLAGS: 00010246
eax: c48a5a98 ebx: c48bd000 ecx: c48bfde0 edx: c48a5a98
esi: c48bb000 edi: c48a5a40 ebp: 00000000 esp: c3aa3f68
ds: 0018 es: 0018 ss: 0018
Process rmmod (pid: 1839, stackpage=c3aa3000)
Stack: c48bd000 c48bb000 c48bd000 bfffedf8 c4895e88 c48a5a98 c4895e9c
 00000001 00000001 c48bed0a c48bfde0 c0116213 c48bd000 c48bb000 00000000
 bfffedf8 c011572e c48bd000 00000001 c3aa2000 00000061 bfffedf8 c0108d23
 00000000 Call Trace: [<c48bd000>] [<c48bb000>] [<c48bd000>] [<c4895e88>]
 [<c48a5a98>] [<c4895e9c>] [<c48bed0a>]
       [<c48bfde0>] [free_module+23/152] [<c48bd000>] [<c48bb000>]
[sys_delete_module+378/448] [<c48bd000>] [system_call+51/64]
Code: 8b 1c aa 85 db 74 37 8b 4c 24 28 39 4b 30 75 2e 83 3d 80 5d

>>EIP; c4893594 <[i2c-core]i2c_del_driver+14c/1f4> <=====

Trace; c48bd000 <[tuner]__module_parm_addr+1440/14a0>
Trace; c48bb000 <[bttv].bss.end+143a1/14401>
Trace; c48bd000 <[tuner]__module_parm_addr+1440/14a0>
Trace; c4895e88 <[i2c-core]__ksymtab_i2c_smbus_write_byte+0/8>
Trace; c48a5a98 <[bttv]__module_kernel_version+19c/1363>
Trace; c4895e9c <[i2c-core]__kstrtab_i2c_check_addr+3/7>
Trace; c48bed0a <[msp3400]msp3400_cleanup_module+a/d>
Trace; c48bfde0 <[msp3400]driver+0/40>
Code; c4893594 <[i2c-core]i2c_del_driver+14c/1f4>
00000000 <_EIP>:
Code; c4893594 <[i2c-core]i2c_del_driver+14c/1f4> <=====
   0: 8b 1c aa mov (%edx,%ebp,4),%ebx <=====
Code; c4893597 <[i2c-core]i2c_del_driver+14f/1f4>
   3: 85 db test %ebx,%ebx
Code; c4893599 <[i2c-core]i2c_del_driver+151/1f4>
   5: 74 37 je 3e <_EIP+0x3e> c48935d2
<[i2c-core]i2c_del_driver+18a/1f4>
Code; c489359b <[i2c-core]i2c_del_driver+153/1f4>
   7: 8b 4c 24 28 mov 0x28(%esp,1),%ecx
Code; c489359f <[i2c-core]i2c_del_driver+157/1f4>
   b: 39 4b 30 cmp %ecx,0x30(%ebx)
Code; c48935a2 <[i2c-core]i2c_del_driver+15a/1f4>
   e: 75 2e jne 3e <_EIP+0x3e> c48935d2
<[i2c-core]i2c_del_driver+18a/1f4>
Code; c48935a4 <[i2c-core]i2c_del_driver+15c/1f4>
  10: 83 3d 80 5d 00 00 00 cmpl $0x0,0x5d80

This is my modules.conf:
alias /dev/v4l bttv
alias char-major-89 i2c-dev
options i2c-core i2c_debug=0
options i2c-algo-bit bit_test=1
alias char-major-81 videodev
alias char-major-81-0 bttv
options bttv card=10 radio=1 pll=1 gbufsize=0x104000
options tuner debug=0 type=5
options msp3400 simple=1

My system is a RedHat 6.2 dest. with gcc-95.2 and kernel 2.4.0-test9 and:
$ cat /proc/cpuinfo
processor : 0
vendor_id : AuthenticAMD
cpu family : 5
model : 8
model name : AMD-K6(tm) 3D processor
stepping : 0
cpu MHz : 298.000825
cache size : 64 KB
fdiv_bug : no
hlt_bug : no
sep_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 1
wp : yes
flags : fpu vme de pse tsc msr mce cx8 sep mmx 3dnow
bogomips : 596.38

$ lspci
00:00.0 Host bridge: VIA Technologies, Inc. VT82C598 [Apollo MVP3] (rev 04)
00:01.0 PCI bridge: VIA Technologies, Inc. VT82C598 [Apollo MVP3 AGP]
00:07.0 ISA bridge: VIA Technologies, Inc. VT82C586/A/B PCI-to-ISA [Apollo
VP] (rev 41)
00:07.1 IDE interface: VIA Technologies, Inc. VT82C586 IDE [Apollo] (rev 06)
00:07.2 USB Controller: VIA Technologies, Inc. VT82C586B USB (rev 02)
00:07.3 Bridge: VIA Technologies, Inc. VT82C586B ACPI (rev 10)
00:08.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8029(AS)
00:0a.0 Multimedia video controller: Brooktree Corporation Bt878 (rev 02)
00:0a.1 Multimedia controller: Brooktree Corporation Bt878 (rev 02)
01:00.0 VGA compatible controller: NVidia / SGS Thomson (Joint Venture)
Riva128 (rev 10)

What is wrong?

Regards,

Koos Vriezen

P.s.: I'm not a member to this mailinglist, please CC response to
j.jvriezen@freeler.nl

-------------------------------------------------------
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Oct 07 2000 - 21:00:20 EST