lpfc 8.2.4 : Make lpfc legacy I/O port free
Subsystems (2)
PATCH 5/10 lpfc 8.2.4 : Make lpfc legacy I/O port free
Make lpfc legacy I/O port free
This is a patch written by Tomohiro Kusumi and submitted to linux-scsi:
http://marc.info/?l=linux-scsi&m=118673720712152&w=2
The original patch comment:
This patch makes Emulex lpfc driver legacy I/O port free. It has already been acked quite long time ago. So I resubmit the patch.
http://lkml.org/lkml/2006/11/22/28
Current lpfc driver is already using pci_select_bars() and pci_enable_device_bars() when the PCI bus has been reset. So I think this patch should also be acked.
Tomohiro Kusumi
drivers/scsi/lpfc/lpfc_init.c +7 -4
@@ -1892,10 +1892,11 @@ lpfc_pci_probe_one(struct pci_dev *pdev,int error = -ENODEV , retval;int i, hbq_count;uint16_t iotag; +int bars =pci_select_bars (pdev,IORESOURCE_MEM ); -if (pci_enable_device (pdev)) +if (pci_enable_device_bars (pdev, bars)) goto out; -if (pci_request_regions (pdev,LPFC_DRIVER_NAME )) +if (pci_request_selected_regions (pdev, bars,LPFC_DRIVER_NAME )) goto out_disable_device; phba =kzalloc (sizeof (struct lpfc_hba ),GFP_KERNEL );
@@ -2167,7 +2168,7 @@ out_idr_remove: out_free_phba:kfree (phba); out_release_regions: -pci_release_regions (pdev); +pci_release_selected_regions (pdev, bars); out_disable_device:pci_disable_device (pdev); out:
@@ -2183,6 +2184,8 @@ lpfc_pci_remove_one(struct pci_dev *pdevstruct Scsi_Host *shost =pci_get_drvdata (pdev);struct lpfc_vport *vport = (struct lpfc_vport *) shost->hostdata;struct lpfc_hba *phba = vport->phba; +int bars =pci_select_bars (pdev,IORESOURCE_MEM ); +spin_lock_irq (&phba->hbalock); vport->load_flag |=FC_UNLOADING ;spin_unlock_irq (&phba->hbalock);
@@ -2241,7 +2244,7 @@ lpfc_pci_remove_one(struct pci_dev *pdevkfree (phba); -pci_release_regions (pdev); +pci_release_selected_regions (pdev, bars);pci_disable_device (pdev); }
drivers/scsi/lpfc/lpfc_init.c.orig +2474 -0
2,474 lines not on this page · raw message
James Bottomley
maintainerQuoted 14 lines · James Smart
Make lpfc legacy I/O port free
This is a patch written by Tomohiro Kusumi and submitted to linux-scsi:
http://marc.info/?l=linux-scsi&m=118673720712152&w=2
The original patch comment:
This patch makes Emulex lpfc driver legacy I/O port free. It has already been acked quite long time ago. So I resubmit the patch.
http://lkml.org/lkml/2006/11/22/28
Quoted 8 lines
Current lpfc driver is already using
pci_select_bars()andpci_enable_device_bars()when the PCI bus has been reset. So I think this patch should also be acked.Tomohiro Kusumi
Signed-off-by Tomohiro Kusumi <[email protected]>Signed-off-by James Smart <[email protected]>
You didn't check the diffstat of this one:
lpfc_init.c | 11 lpfc_init.c.orig | 2475 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 2481 insertions(+), 5 deletions(-)
I've manually removed all references to the lpfc_init.c.orig file that popped into existence with this patch and was deleted with the subsequent one.
James
Quoted 11 lines · James Bottomley
You didn't check the diffstat of this one:
lpfc_init.c | 11 lpfc_init.c.orig | 2475 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 2481 insertions(+), 5 deletions(-)I've manually removed all references to the lpfc_init.c.orig file that popped into existence with this patch and was deleted with the subsequent one.
James
(grumble...) Thank You James... That was the action that was needed.
-- james s