Hi,
We are using TSIF interface for live capture in DVB-C. It is observed that if the input signal is not very good, PAT/PMT detection IOCTLs takes forever and there are no timeouts.
Problem is mainly with the PMT detection - if that gets stuck for a time - say longer than a few seconds, there is a kernel crash observed. PFA the log:
(Please note that "TSIF_GET_PMT_PKT : checking addresses" message is added by me to verify that the addresses going to the IOCTL are correct.)
TSIF_GET_PMT_PKT : checking addresses for NULL arg = 2495ce8 and =0
====
=================================
TRACK :Entering for pmt pid 2010
Tsif : TSIF_GET_PMT_CONFIG ok [2010, 1]
Tsif : Waiting for PMT
=================================
==========PMT DETECTED===========
=================================
TRACK :Entering for pmt pid 1988
Tsif : TSIF_GET_PMT_CONFIG ok [1988, 1]
Tsif : Waiting for PMT
...
kernel BUG at net/core/skbuff.c:1011!
Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 817 [#1] PREEMPT
Modules linked in: dsplinkk cmemk tsif_data tsif_control SI2165 xc5000
CPU: 0 Not tainted (2.6.32-rc2-davinci1-svn2201 #259)
PC is at __bug+0x20/0x2c
LR is at vprintk+0x398/0x408
pc : [<c002e500>] lr : [<c004100c>] psr: 40000013
sp : c0467e20 ip : c0467d80 fp : c0467e2c
r10: c0000040 r9 : 00000000 r8 : 80000013
r7 : c0249904 r6 : 1cf4995a r5 : 00000040 r4 : c22c69c0
r3 : 00000000 r2 : c0466000 r1 : c0467d80 r0 : 0000002c
Flags: nZcv IRQs on FIQs on Mode SVC_32 ISA ARM Segment kernel
Control: 0005317f Table: 82270000 DAC: 00000017
Process swapper (pid: 0, stack limit = 0xc0466270)
Stack: (0xc0467e20 to 0xc0468000)
7e20: c0467e4c c0467e30 c02ccaf0 c002e4f0 00000040 c3100b00 c361c2e0 c22c69c0
7e40: c0467eac c0467e50 c0249904 c02ccacc 07d432b2 ffffffff 00000040 c361c2ec
7e60: c361c000 c361c210 00000001 c0466000 c22c69c0 c3e28022 00000040 c20d9480
7e80: 00000000 c361c2ec 00000040 00000001 c0466000 00000000 0000012c c0466000
7ea0: c0467ee4 c0467eb0 c02d5460 c024952c 60000093 ffffcc1e c0467edc 00000103
7ec0: 0000000c 00000001 c0466000 00000003 0000000a c049c480 c0467f24 c0467ee8
7ee0: c0045a18 c02d53c0 c0467f14 c0467ef8 c0466000 00000000 00000019 00000019
7f00: 00000000 c0025e14 00000002 00000001 c0466000 80023974 c0467f34 c0467f28
7f20: c0045afc c0045990 c0467f4c c0467f38 c002a074 c0045abc ffffffff fec48000
7f40: c0467fa4 c0467f50 c002aacc c002a010 00000000 0005317f 0005217f 60000013
7f60: c0466000 c049763c c0025e14 c046a388 800239a8 41069265 80023974 c0467fa4
7f80: 600000d3 c0467f98 c002b9d0 c002b9dc 60000013 ffffffff c0467fbc c0467fa8
7fa0: c002bf28 c002b9b8 c04abc6c c049763c c0467fcc c0467fc0 c0358f84 c002bec0
7fc0: c0467ff4 c0467fd0 c00089b8 c0358f24 c00084f0 00000000 00000000 c0025e18
7fe0: 00053175 c04976e4 00000000 c0467ff8 80008034 c0008760 00000000 00000000
Backtrace:
[<c002e4e0>] (__bug+0x0/0x2c) from [<c02ccaf0>] (skb_put+0x34/0x6c)
[<c02ccabc>] (skb_put+0x0/0x6c) from [<c0249904>] (emac_poll+0x3e8/0x650)
r7:c22c69c0 r6:c361c2e0 r5:c3100b00 r4:00000040
[<c024951c>] (emac_poll+0x0/0x650) from [<c02d5460>] (net_rx_action+0xb0/0x224)
[<c02d53b0>] (net_rx_action+0x0/0x224) from [<c0045a18>] (__do_softirq+0x98/0x12c)
[<c0045980>] (__do_softirq+0x0/0x12c) from [<c0045afc>] (irq_exit+0x50/0xa8)
[<c0045aac>] (irq_exit+0x0/0xa8) from [<c002a074>] (asm_do_IRQ+0x74/0x8c)
[<c002a000>] (asm_do_IRQ+0x0/0x8c) from [<c002aacc>] (__irq_svc+0x4c/0x90)
Exception stack(0xc0467f50 to 0xc0467f98)
7f40: 00000000 0005317f 0005217f 60000013
7f60: c0466000 c049763c c0025e14 c046a388 800239a8 41069265 80023974 c0467fa4
7f80: 600000d3 c0467f98 c002b9d0 c002b9dc 60000013 ffffffff
r5:fec48000 r4:ffffffff
[<c002b9a8>] (default_idle+0x0/0x38) from [<c002bf28>] (cpu_idle+0x78/0xe4)
[<c002beb0>] (cpu_idle+0x0/0xe4) from [<c0358f84>] (rest_init+0x70/0x84)
r5:c049763c r4:c04abc6c
[<c0358f14>] (rest_init+0x0/0x84) from [<c00089b8>] (start_kernel+0x268/0x2c0)
[<c0008750>] (start_kernel+0x0/0x2c0) from [<80008034>] (0x80008034)
Code: e1a01000 e59f000c eb0cb456 e3a03000 (e5833000)
Kernel panic - not syncing: Fatal exception in interrupt
Backtrace:
[<c002e7e8>] (dump_backtrace+0x0/0x114) from [<c035b530>] (dump_stack+0x18/0x1c)
r7:c0467dd8 r6:c04696b8 r5:c0466000 r4:c0497b50
[<c035b518>] (dump_stack+0x0/0x1c) from [<c035b588>] (panic+0x54/0x124)
[<c035b534>] (panic+0x0/0x124) from [<c002eb8c>] (die+0x170/0x19c)
r3:00000100 r2:c0467cc0 r1:c0497b50 r0:c03f7cc3
[<c002ea1c>] (die+0x0/0x19c) from [<c0030628>] (__do_kernel_fault+0x6c/0x7c)
[<c00305bc>] (__do_kernel_fault+0x0/0x7c) from [<c0030808>] (do_page_fault+0x1d0/0x1e8)
r7:00000000 r6:00000000 r5:c04696b8 r4:c046a654
[<c0030638>] (do_page_fault+0x0/0x1e8) from [<c002a288>] (do_DataAbort+0x3c/0x9c)
[<c002a24c>] (do_DataAbort+0x0/0x9c) from [<c002aa6c>] (__dabt_svc+0x4c/0x60)
Exception stack(0xc0467dd8 to 0xc0467e20)
7dc0: 0000002c c0467d80
7de0: c0466000 00000000 c22c69c0 00000040 1cf4995a c0249904 80000013 00000000
7e00: c0000040 c0467e2c c0467d80 c0467e20 c004100c c002e500 40000013 ffffffff
r8:80000013 r7:c0249904 r6:1cf4995a r5:c0467e0c r4:ffffffff
[<c002e4e0>] (__bug+0x0/0x2c) from [<c02ccaf0>] (skb_put+0x34/0x6c)
[<c02ccabc>] (skb_put+0x0/0x6c) from [<c0249904>] (emac_poll+0x3e8/0x650)
r7:c22c69c0 r6:c361c2e0 r5:c3100b00 r4:00000040
[<c024951c>] (emac_poll+0x0/0x650) from [<c02d5460>] (net_rx_action+0xb0/0x224)
[<c02d53b0>] (net_rx_action+0x0/0x224) from [<c0045a18>] (__do_softirq+0x98/0x12c)
[<c0045980>] (__do_softirq+0x0/0x12c) from [<c0045afc>] (irq_exit+0x50/0xa8)
[<c0045aac>] (irq_exit+0x0/0xa8) from [<c002a074>] (asm_do_IRQ+0x74/0x8c)
[<c002a000>] (asm_do_IRQ+0x0/0x8c) from [<c002aacc>] (__irq_svc+0x4c/0x90)
Exception stack(0xc0467f50 to 0xc0467f98)
7f40: 00000000 0005317f 0005217f 60000013
7f60: c0466000 c049763c c0025e14 c046a388 800239a8 41069265 80023974 c0467fa4
7f80: 600000d3 c0467f98 c002b9d0 c002b9dc 60000013 ffffffff
r5:fec48000 r4:fffffff
Regards,
-Sheetal.