ipr: add MSI support
Subsystems (2)
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/2 ipr: add MSI support
Enable MSI if available/supported.
--- drivers/scsi/ipr.c | 7 +++++++ drivers/scsi/ipr.h | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-)
drivers/scsi/ipr.c +7 -0
@@ -7147,6 +7147,7 @@ENTER ;free_irq (pdev->irq, ioa_cfg); +pci_disable_msi (pdev);iounmap (ioa_cfg->hdw_dma_regs);pci_release_regions (pdev);ipr_free_mem (ioa_cfg);
@@ -7432,6 +7433,11 @@ goto out; } +if (!(rc =pci_enable_msi (pdev))) +dev_info (&pdev->dev,"MSI enabled\n" ); +else if (ipr_debug) +dev_info (&pdev->dev,"Cannot enable MSI\n" ); +dev_info (&pdev->dev,"Found IOA with IRQ: %d\n" , pdev->irq); host =scsi_host_alloc (&driver_template,sizeof (*ioa_cfg));
@@ -7574,6 +7580,7 @@ out_scsi_host_put:scsi_host_put (host); out_disable: +pci_disable_msi (pdev);pci_disable_device (pdev); goto out; }
drivers/scsi/ipr.h +2 -2
@@ -37,8 +37,8 @@/* * Literals */ -#define IPR_DRIVER_VERSION "2.4.1" -#define IPR_DRIVER_DATE "(April 24, 2007)" +#define IPR_DRIVER_VERSION "2.4.2" +#define IPR_DRIVER_DATE "(January 21, 2009)"/* * IPR_MAX_CMD_PER_LUN: This defines the maximum number of outstanding
Acked by: Brian King <[email protected]>
Quoted 60 lines · Wayne Boyer
Enable MSI if available/supported.
Signed-off-by Wayne Boyer <[email protected]>--- drivers/scsi/ipr.c | 7 +++++++ drivers/scsi/ipr.h | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-)Index:
linux-2.6/drivers/scsi/ipr.c
===================================================================drivers/scsi/ipr.c +7
-0@@ -7147,6 +7147,7 @@ENTER ;free_irq (pdev->irq, ioa_cfg); +pci_disable_msi (pdev);iounmap (ioa_cfg->hdw_dma_regs);pci_release_regions (pdev);ipr_free_mem (ioa_cfg);@@ -7432,6 +7433,11 @@ goto out; } +if (!(rc =pci_enable_msi (pdev))) +dev_info (&pdev->dev,"MSI enabled\n" ); +else if (ipr_debug) +dev_info (&pdev->dev,"Cannot enable MSI\n" ); +dev_info (&pdev->dev,"Found IOA with IRQ: %d\n" , pdev->irq); host =scsi_host_alloc (&driver_template,sizeof (*ioa_cfg));@@ -7574,6 +7580,7 @@ out_scsi_host_put:scsi_host_put (host); out_disable: +pci_disable_msi (pdev);pci_disable_device (pdev); goto out; }Index:
linux-2.6/drivers/scsi/ipr.h
===================================================================drivers/scsi/ipr.h +2
-3@@ -37,8 +37,8 @@/* * Literals */ -#define IPR_DRIVER_VERSION "2.4.1" -#define IPR_DRIVER_DATE "(April 24, 2007)" +#define IPR_DRIVER_VERSION "2.4.2" +#define IPR_DRIVER_DATE "(January 21, 2009)"/* * IPR_MAX_CMD_PER_LUN: This defines the maximum number of outstanding -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 3 lines
Brian King Linux on Power Virtualization IBM Linux Technology Center
PATCH 2/2 ipr: add message to error table
In reply to a message not in the archiveAdds a message to the error table for an error that wasn't previously handled.
---
drivers/scsi/ipr.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/scsi/ipr.c +2 -0
@@ -354,6 +354,8 @@ "9076: Configuration error, missing remote IOA"}, {0x06679100 ,0 ,IPR_DEFAULT_LOG_LEVEL , "4050: Enclosure does not support a required multipath function"}, + {0x06690000, 0, IPR_DEFAULT_LOG_LEVEL, + "4070: Logically bad written to device"}, {0x06690200, 0, IPR_DEFAULT_LOG_LEVEL, "9041: Array protection temporarily suspended"}, {0x06698200, 0, IPR_DEFAULT_LOG_LEVEL,
Re: [PATCH 2/2] ipr: add message to error table
Acked by: Brian King <[email protected]>
Quoted 26 lines · Wayne Boyer
Adds a message to the error table for an error that wasn't previously handled.
Signed-off-by Wayne Boyer <[email protected]>---
drivers/scsi/ipr.c | 2 ++ 1 file changed, 2 insertions(+)Index:
linux-2.6/drivers/scsi/ipr.c
===================================================================drivers/scsi/ipr.c +2
-1@@ -354,6 +354,8 @@ "9076: Configuration error, missing remote IOA"}, {0x06679100 ,0 ,IPR_DEFAULT_LOG_LEVEL , "4050: Enclosure does not support a required multipath function"}, + {0x06690000, 0, IPR_DEFAULT_LOG_LEVEL, + "4070: Logically bad written to device"}, {0x06690200, 0, IPR_DEFAULT_LOG_LEVEL, "9041: Array protection temporarily suspended"}, {0x06698200, 0, IPR_DEFAULT_LOG_LEVEL, --To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 3 lines
Brian King Linux on Power Virtualization IBM Linux Technology Center
James Bottomley
maintainerRe: [PATCH 2/2] ipr: add message to error table
In reply to Wayne BoyerQuoted 13 lines · Wayne Boyer
Adds a message to the error table for an error that wasn't previously handled.
Signed-off-by Wayne Boyer <[email protected]>---
drivers/scsi/ipr.c | 2 ++ 1 file changed, 2 insertions(+)Index:
linux-2.6/drivers/scsi/ipr.c
===================================================================
drivers/scsi/ipr.c line 358
Quoted 5 lines
drivers/scsi/ipr.c +2
-0@@ -354,6 +354,8 @@ "9076: Configuration error, missing remote IOA"}, {0x06679100 ,0 ,IPR_DEFAULT_LOG_LEVEL , "4050: Enclosure does not support a required multipath function"}, + {0x06690000, 0, IPR_DEFAULT_LOG_LEVEL, + "4070: Logically bad written to device"},
Neither from the change log nor from the actual text can I tell what the problem is ... is there a word missing (like block or sector)?
James
Re: [PATCH 2/2] ipr: add message to error table
Quoted 9 lines · James Bottomley
Quoted 8 lines · Wayne Boyer
Adds a message to the error table for an error that wasn't previously handled.
Signed-off-by Wayne Boyer <[email protected]>---
drivers/scsi/ipr.c | 2 ++ 1 file changed, 2 insertions(+)
Quoted 14 lines
drivers/scsi/ipr.c line 358
Quoted 10 lines
Index:
linux-2.6/drivers/scsi/ipr.c
===================================================================drivers/scsi/ipr.c +2
-0@@ -354,6 +354,8 @@ "9076: Configuration error, missing remote IOA"}, {0x06679100 ,0 ,IPR_DEFAULT_LOG_LEVEL , "4050: Enclosure does not support a required multipath function"}, + {0x06690000, 0, IPR_DEFAULT_LOG_LEVEL, + "4070: Logically bad written to device"},Neither from the change log nor from the actual text can I tell what the problem is ... is there a word missing (like block or sector)?
After some discussion, I've come up with a more descriptive message and better change log. Updated patch below...
Quoted 2 lines
James
Adds a message to the error table for an error that wasn't previously handled. In some cases the I/O Adapter will detect an error condition and mark a block as "logically bad".
---
drivers/scsi/ipr.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/scsi/ipr.c +2 -0
@@ -354,6 +354,8 @@ "9076: Configuration error, missing remote IOA"}, {0x06679100 ,0 ,IPR_DEFAULT_LOG_LEVEL , "4050: Enclosure does not support a required multipath function"}, + {0x06690000, 0, IPR_DEFAULT_LOG_LEVEL, + "4070: Logically bad block written on device"}, {0x06690200, 0, IPR_DEFAULT_LOG_LEVEL, "9041: Array protection temporarily suspended"}, {0x06698200, 0, IPR_DEFAULT_LOG_LEVEL,
Signature · 4 lines
Wayne Boyer IBM - Beaverton, Oregon LTC S/W Development - eServerIO (503) 578-5236, T/L 775-5236