diff options
Diffstat (limited to 'drivers/mcb/mcb-pci.c')
-rw-r--r-- | drivers/mcb/mcb-pci.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/mcb/mcb-pci.c b/drivers/mcb/mcb-pci.c index 53d9202ff9a7..3b634ea318c7 100644 --- a/drivers/mcb/mcb-pci.c +++ b/drivers/mcb/mcb-pci.c @@ -45,6 +45,14 @@ static int mcb_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) } pci_set_master(pdev); + flags = pci_resource_flags(pdev, 0); + if (flags & IORESOURCE_IO) { + ret = -ENOTSUPP; + dev_err(&pdev->dev, + "IO mapped PCI devices are not supported\n"); + goto out_disable; + } + priv->mapbase = pci_resource_start(pdev, 0); if (!priv->mapbase) { dev_err(&pdev->dev, "No PCI resource\n"); @@ -68,14 +76,6 @@ static int mcb_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) goto out_disable; } - flags = pci_resource_flags(pdev, 0); - if (flags & IORESOURCE_IO) { - ret = -ENOTSUPP; - dev_err(&pdev->dev, - "IO mapped PCI devices are not supported\n"); - goto out_disable; - } - pci_set_drvdata(pdev, priv); priv->bus = mcb_alloc_bus(&pdev->dev); |