diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-03-10 19:46:50 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-21 16:53:06 (GMT) |
commit | 9050d942b7dc55cd8e6d9b2c1ce260656021f0fb (patch) | |
tree | 6906a570d9519b7368c626704413a317dda3c7e5 /drivers/media/video/saa7134 | |
parent | f705e6e4940c4e803240b77c6c63fb2d47a97b59 (diff) | |
download | linux-fsl-qoriq-9050d942b7dc55cd8e6d9b2c1ce260656021f0fb.tar.xz |
V4L/DVB (3439): Added no_overlay option and quirks to saa7134
Some chipsets have several problems when pci to pci transfers are activated
on overlay mode. the option no_overlay allows disabling such feature of
the driver, in favor of keeping the system stable.
The default is to use pcipci_fail flag defined on drivers/pci/quirks.c.
It also allows the user to override it by forcing disable overlay or forcing
enable. Forcing enable may generate PCI transfer corruption, including disk
mass corruption, so should be used with care.
Added a text description to this option and make messages looks the same at
both bttv and saa7134 drivers.
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/saa7134')
-rw-r--r-- | drivers/media/video/saa7134/saa7134-core.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/media/video/saa7134/saa7134-core.c b/drivers/media/video/saa7134/saa7134-core.c index e7c3066..f5f2cf5 100644 --- a/drivers/media/video/saa7134/saa7134-core.c +++ b/drivers/media/video/saa7134/saa7134-core.c @@ -66,6 +66,11 @@ static unsigned int latency = UNSET; module_param(latency, int, 0444); MODULE_PARM_DESC(latency,"pci latency timer"); +static int no_overlay=-1; +module_param(no_overlay, int, 0444); +MODULE_PARM_DESC(no_overlay,"allow override overlay default (0 disables, 1 enables)" + " [some VIA/SIS chipsets are known to have problem with overlay]"); + static unsigned int video_nr[] = {[0 ... (SAA7134_MAXBOARDS - 1)] = UNSET }; static unsigned int vbi_nr[] = {[0 ... (SAA7134_MAXBOARDS - 1)] = UNSET }; static unsigned int radio_nr[] = {[0 ... (SAA7134_MAXBOARDS - 1)] = UNSET }; @@ -835,6 +840,22 @@ static int __devinit saa7134_initdev(struct pci_dev *pci_dev, latency = 0x0A; } #endif + if (pci_pci_problems & PCIPCI_FAIL) { + printk(KERN_INFO "%s: quirk: this driver and your " + "chipset may not work together" + " in overlay mode.\n",dev->name); + if (!no_overlay) { + printk(KERN_INFO "%s: quirk: overlay " + "mode will be disabled.\n", + dev->name); + no_overlay = 1; + } else { + printk(KERN_INFO "%s: quirk: overlay " + "mode will be forced. Use this" + " option at your own risk.\n", + dev->name); + } + } } if (UNSET != latency) { printk(KERN_INFO "%s: setting pci latency timer to %d\n", |