From 98040015bc5d6cea3bd2dcb642fe1e8c4bded8e1 Mon Sep 17 00:00:00 2001 From: "mike.miller@hp.com" Date: Wed, 13 Dec 2006 13:08:56 +0100 Subject: [PATCH 1/2] cciss: map out more memory for config table This patch maps out more memory for our config table. It's required to reach offset 0x214 to disable DMA on the P600. I'm not sure how I lost this hunk. Please consider this for inclusion. Signed-off-by: Mike Miller Signed-off-by: Jens Axboe --- drivers/block/cciss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/block') diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index ee159edb6b88..8879e95b121e 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -2865,7 +2865,7 @@ static int cciss_pci_init(ctlr_info_t *c, struct pci_dev *pdev) #ifdef CCISS_DEBUG printk("address 0 = %x\n", c->paddr); #endif /* CCISS_DEBUG */ - c->vaddr = remap_pci_mem(c->paddr, 200); + c->vaddr = remap_pci_mem(c->paddr, 0x250); /* Wait for the board to become ready. (PCI hotplug needs this.) * We poll for up to 120 secs, once per 100ms. */ -- cgit v1.2.3 From c4977f596c5bce4d20fbd22cdb03486112985622 Mon Sep 17 00:00:00 2001 From: "mike.miller@hp.com" Date: Wed, 13 Dec 2006 13:10:04 +0100 Subject: [PATCH 2/2] cciss: remove calls to pci_disable_device This patch removes calls to pci_disable_device except in fail_all_cmds. The pci_disable_device function does something nasty to Smart Array controllers that pci_enable_device does not undo. So if the driver is unloaded it cannot be reloaded. Also, customers can disable any pci device via the ROM Based Setup Utility (RBSU). If the customer has disabled the controller we should not try to blindly enable the card from the driver. Please consider this for inclusion. Signed-off-by: Mike Miller Acked-by: Alan Cox Signed-off-by: Jens Axboe --- drivers/block/cciss.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'drivers/block') diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index 8879e95b121e..335e218b6dcc 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -3006,10 +3006,8 @@ static int cciss_pci_init(ctlr_info_t *c, struct pci_dev *pdev) err_out_free_res: pci_release_regions(pdev); - - err_out_disable_pdev: - pci_disable_device(pdev); return err; + } /* @@ -3383,7 +3381,6 @@ static int __devinit cciss_init_one(struct pci_dev *pdev, blk_cleanup_queue(drv->queue); } pci_release_regions(pdev); - pci_disable_device(pdev); pci_set_drvdata(pdev, NULL); free_hba(i); return -1; @@ -3453,7 +3450,6 @@ static void __devexit cciss_remove_one(struct pci_dev *pdev) kfree(hba[i]->scsi_rejects.complete); #endif pci_release_regions(pdev); - pci_disable_device(pdev); pci_set_drvdata(pdev, NULL); free_hba(i); } -- cgit v1.2.3 From 2fc2c60df3d2b3a557eb8d750779def9d51934b1 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Wed, 13 Dec 2006 15:44:27 +0100 Subject: [PATCH] Fixup cciss error handling The previous cciss commit removed the err_out_disable_pdev label, but there was still a user of that. Fix that up. Signed-off-by: Jens Axboe --- drivers/block/cciss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/block') diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index 335e218b6dcc..2ee4a44423df 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -2837,7 +2837,7 @@ static int cciss_pci_init(ctlr_info_t *c, struct pci_dev *pdev) if (err) { printk(KERN_ERR "cciss: Cannot obtain PCI resources, " "aborting\n"); - goto err_out_disable_pdev; + return err; } subsystem_vendor_id = pdev->subsystem_vendor; -- cgit v1.2.3