summaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorManu Abraham <abraham.manu@gmail.com>2009-12-04 05:32:51 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-01-17 11:55:41 -0200
commitff63ac56705539e162d2f020a0c2a607eae37d7b (patch)
tree8f568e4dfbbdefadf3443a7913ba1b74575dc4b4 /drivers/media
parentf5701b67767c6b81a035c9e2b539025f91d1e84d (diff)
downloadop-kernel-dev-ff63ac56705539e162d2f020a0c2a607eae37d7b.zip
op-kernel-dev-ff63ac56705539e162d2f020a0c2a607eae37d7b.tar.gz
V4L/DVB (13784): [Mantis] Use PCI API instead of hardcoded length
Signed-off-by: Manu Abraham <manu@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/dvb/mantis/mantis_pci.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/media/dvb/mantis/mantis_pci.c b/drivers/media/dvb/mantis/mantis_pci.c
index a068ffb..d3a62b1 100644
--- a/drivers/media/dvb/mantis/mantis_pci.c
+++ b/drivers/media/dvb/mantis/mantis_pci.c
@@ -169,7 +169,10 @@ static int __devinit mantis_pci_probe(struct pci_dev *pdev,
goto err0;
}
- if ((mantis->mantis_mmio = ioremap(mantis->mantis_addr, 0x1000)) == NULL) {
+ mantis->mantis_mmio = ioremap(pci_resource_start(pdev, 0),
+ pci_resource_len(pdev, 0));
+
+ if (!mantis->mantis_mmio) {
dprintk(verbose, MANTIS_ERROR, 1, "IO remap failed");
ret = -ENODEV;
goto err1;
OpenPOWER on IntegriCloud