aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/message/i2o/pci.c10
-rw-r--r--drivers/scsi/dpt_i2o.c10
2 files changed, 11 insertions, 9 deletions
diff --git a/drivers/message/i2o/pci.c b/drivers/message/i2o/pci.c
index c5b656cdea7c..f23aeea43f62 100644
--- a/drivers/message/i2o/pci.c
+++ b/drivers/message/i2o/pci.c
@@ -88,11 +88,6 @@ static int __devinit i2o_pci_alloc(struct i2o_controller *c)
88 struct device *dev = &pdev->dev; 88 struct device *dev = &pdev->dev;
89 int i; 89 int i;
90 90
91 if (pci_request_regions(pdev, OSM_DESCRIPTION)) {
92 printk(KERN_ERR "%s: device already claimed\n", c->name);
93 return -ENODEV;
94 }
95
96 for (i = 0; i < 6; i++) { 91 for (i = 0; i < 6; i++) {
97 /* Skip I/O spaces */ 92 /* Skip I/O spaces */
98 if (!(pci_resource_flags(pdev, i) & IORESOURCE_IO)) { 93 if (!(pci_resource_flags(pdev, i) & IORESOURCE_IO)) {
@@ -319,6 +314,11 @@ static int __devinit i2o_pci_probe(struct pci_dev *pdev,
319 return rc; 314 return rc;
320 } 315 }
321 316
317 if (pci_request_regions(pdev, OSM_DESCRIPTION)) {
318 printk(KERN_ERR "i2o: device already claimed\n", c->name);
319 return -ENODEV;
320 }
321
322 if (pci_set_dma_mask(pdev, DMA_32BIT_MASK)) { 322 if (pci_set_dma_mask(pdev, DMA_32BIT_MASK)) {
323 printk(KERN_WARNING "i2o: no suitable DMA found for %s\n", 323 printk(KERN_WARNING "i2o: no suitable DMA found for %s\n",
324 pci_name(pdev)); 324 pci_name(pdev));
diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c
index cdeb30b0462e..6e6b293dcb28 100644
--- a/drivers/scsi/dpt_i2o.c
+++ b/drivers/scsi/dpt_i2o.c
@@ -899,6 +899,12 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
899 if(pci_enable_device(pDev)) { 899 if(pci_enable_device(pDev)) {
900 return -EINVAL; 900 return -EINVAL;
901 } 901 }
902
903 if (pci_request_regions(pDev, "dpt_i2o")) {
904 PERROR("dpti: adpt_config_hba: pci request region failed\n");
905 return -EINVAL;
906 }
907
902 pci_set_master(pDev); 908 pci_set_master(pDev);
903 if (pci_set_dma_mask(pDev, 0xffffffffffffffffULL) && 909 if (pci_set_dma_mask(pDev, 0xffffffffffffffffULL) &&
904 pci_set_dma_mask(pDev, 0xffffffffULL)) 910 pci_set_dma_mask(pDev, 0xffffffffULL))
@@ -924,10 +930,6 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
924 raptorFlag = TRUE; 930 raptorFlag = TRUE;
925 } 931 }
926 932
927 if (pci_request_regions(pDev, "dpt_i2o")) {
928 PERROR("dpti: adpt_config_hba: pci request region failed\n");
929 return -EINVAL;
930 }
931 base_addr_virt = ioremap(base_addr0_phys,hba_map0_area_size); 933 base_addr_virt = ioremap(base_addr0_phys,hba_map0_area_size);
932 if (!base_addr_virt) { 934 if (!base_addr_virt) {
933 pci_release_regions(pDev); 935 pci_release_regions(pDev);