[linux-dvb] [Patch] saa7146: 'wait_for_debi_done' fixes

Tomi Orava tomimo+linux-dvb at ncircle.nullnet.fi
Mon Oct 15 19:13:22 CEST 2007


Hi Oliver,

> @all users of saa7146-based cards
>
> (drivers: dvb-ttpci, budget, budget-ci, budget-av)
>
> Please test whether the attached patch has any negative effects.
>
> Two fixes for the 'saa7146_wait_for_debi_done' code:
> (a) Timeout did not work when the routine was called with interrupts
>     disabled.
> (b) Reduce PCI I/O load caused by saa7146_wait_for_debi_done.
>     Seems to be very important on fast machines!
>
> Based on a patch posted by e9hack at vdr-portal.
>
> If nobody complains I will commit this patch next week.

I tried your patch and for me it resulted the following constant complaints:

saa7146 (0): saa7146_wait_for_debi_done_sleep timed out while waiting for
transfer completion
saa7146 (0): saa7146_wait_for_debi_done_sleep timed out while waiting for
transfer completion
saa7146 (0): saa7146_wait_for_debi_done_sleep timed out while waiting for
transfer completion

The above complaint started as soon MythBackend started hopping from
channel to channel and gathering EIT-information. These messages came
every once couple of minutes until I stopped the test run.

Kernel is 2.6.23.9-91 (fedora 7) and HG tree latest.

The kernel bootlog:

Linux video capture interface: v2.00
saa7146: register extension 'budget_av'.
ACPI: PCI Interrupt 0000:02:06.0[A] -> Link [APC1] -> GSI 16 (level, low)
-> IRQ 16
saa7146: found saa7146 @ mem ffffc200043a4000 (revision 1, irq 16)
(0x1894,0x002c).
saa7146 (0): dma buffer size 1347584
DVB: registering new adapter (Satelco EasyWatch DVB-C MK3)
adapter failed MAC signature check
encoded MAC from EEPROM was
ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff:ff
KNC1-0: MAC addr = 00:09:d6:6d:71:97
DVB: registering frontend 0 (Philips TDA10023 DVB-C)...
budget-av: ci interface initialised.
saa7146: register extension 'budget dvb'.
ACPI: PCI Interrupt Link [APC2] enabled at IRQ 17
ACPI: PCI Interrupt 0000:02:07.0[A] -> Link [APC2] -> GSI 17 (level, low)
-> IRQ 17
saa7146: found saa7146 @ mem ffffc200043c8000 (revision 1, irq 17)
(0x13c2,0x1004).
saa7146 (1): dma buffer size 1347584
DVB: registering new adapter (TT-Budget/WinTV-NOVA-C  PCI)
adapter has MAC addr = 00:d0:5c:03:83:6b
DVB: registering frontend 1 (VLSI VES1820 DVB-C)...
ACPI: PCI Interrupt Link [APC3] enabled at IRQ 18
ACPI: PCI Interrupt 0000:02:08.0[A] -> Link [APC3] -> GSI 18 (level, low)
-> IRQ 18
saa7146: found saa7146 @ mem ffffc200043ec000 (revision 1, irq 18)
(0x13c2,0x1004).
saa7146 (2): dma buffer size 1347584
DVB: registering new adapter (TT-Budget/WinTV-NOVA-C  PCI)
adapter has MAC addr = 00:d0:5c:00:01:07
DVB: registering frontend 2 (VLSI VES1820 DVB-C)...

lspci output:
00:00.0 RAM memory: nVidia Corporation C51 Host Bridge (rev a2)
00:00.1 RAM memory: nVidia Corporation C51 Memory Controller 0 (rev a2)
00:00.2 RAM memory: nVidia Corporation C51 Memory Controller 1 (rev a2)
00:00.3 RAM memory: nVidia Corporation C51 Memory Controller 5 (rev a2)
00:00.4 RAM memory: nVidia Corporation C51 Memory Controller 4 (rev a2)
00:00.5 RAM memory: nVidia Corporation C51 Host Bridge (rev a2)
00:00.6 RAM memory: nVidia Corporation C51 Memory Controller 3 (rev a2)
00:00.7 RAM memory: nVidia Corporation C51 Memory Controller 2 (rev a2)
00:04.0 PCI bridge: nVidia Corporation C51 PCI Express Bridge (rev a1)
00:08.0 RAM memory: nVidia Corporation MCP55 Memory Controller (rev a1)
00:09.0 ISA bridge: nVidia Corporation MCP55 LPC Bridge (rev a2)
00:09.1 SMBus: nVidia Corporation MCP55 SMBus (rev a2)
00:09.2 RAM memory: nVidia Corporation MCP55 Memory Controller (rev a2)
00:0a.0 USB Controller: nVidia Corporation MCP55 USB Controller (rev a1)
00:0a.1 USB Controller: nVidia Corporation MCP55 USB Controller (rev a2)
00:0c.0 IDE interface: nVidia Corporation MCP55 IDE (rev a1)
00:0d.0 IDE interface: nVidia Corporation MCP55 SATA Controller (rev a2)
00:0d.1 IDE interface: nVidia Corporation MCP55 SATA Controller (rev a2)
00:0d.2 IDE interface: nVidia Corporation MCP55 SATA Controller (rev a2)
00:0e.0 PCI bridge: nVidia Corporation MCP55 PCI bridge (rev a2)
00:0e.1 Audio device: nVidia Corporation MCP55 High Definition Audio (rev a2)
00:10.0 Bridge: nVidia Corporation MCP55 Ethernet (rev a2)
00:11.0 Bridge: nVidia Corporation MCP55 Ethernet (rev a2)
00:12.0 PCI bridge: nVidia Corporation MCP55 PCI Express bridge (rev a2)
00:16.0 PCI bridge: nVidia Corporation MCP55 PCI Express bridge (rev a2)
00:17.0 PCI bridge: nVidia Corporation MCP55 PCI Express bridge (rev a2)
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron]
HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron]
Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron]
DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron]
Miscellaneous Control
01:00.0 VGA compatible controller: nVidia Corporation Unknown device 0421
(rev a1)
02:06.0 Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
02:07.0 Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
02:08.0 Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
02:0b.0 FireWire (IEEE 1394): Texas Instruments TSB43AB22/A
IEEE-1394a-2000 Controller (PHY/Link)
04:00.0 Mass storage controller: Silicon Image, Inc. SiI 3132 Serial ATA
Raid II Controller (rev 01)
05:00.0 Ethernet controller: Intel Corporation 82572EI Gigabit Ethernet
Controller (Copper) (rev 06)

lspci -s 02:06.0 -v
02:06.0 Multimedia controller: Philips Semiconductors SAA7146 (rev 01)
        Subsystem: KNC One Unknown device 002c
        Flags: bus master, medium devsel, latency 128, IRQ 16
        Memory at fdfff000 (32-bit, non-prefetchable) [size=512]

I tried tinkering the latency values from default 64 all the way to 192 but
without any change.

Regards,
Tomi Orava
-- 





More information about the linux-dvb mailing list