Commit 7dce0e1c authored by Brian King's avatar Brian King Committed by James Bottomley

[SCSI] ipr: Tolerate not finding PCI-X registers

Don't fail initialization of an adapter if the PCI-X registers
cannot be found since it may be a PCI-E adapter.
Signed-off-by: default avatarBrian King <brking@linux.vnet.ibm.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent 6d84c944
...@@ -595,10 +595,8 @@ static int ipr_save_pcix_cmd_reg(struct ipr_ioa_cfg *ioa_cfg) ...@@ -595,10 +595,8 @@ static int ipr_save_pcix_cmd_reg(struct ipr_ioa_cfg *ioa_cfg)
{ {
int pcix_cmd_reg = pci_find_capability(ioa_cfg->pdev, PCI_CAP_ID_PCIX); int pcix_cmd_reg = pci_find_capability(ioa_cfg->pdev, PCI_CAP_ID_PCIX);
if (pcix_cmd_reg == 0) { if (pcix_cmd_reg == 0)
dev_err(&ioa_cfg->pdev->dev, "Failed to save PCI-X command register\n"); return 0;
return -EIO;
}
if (pci_read_config_word(ioa_cfg->pdev, pcix_cmd_reg + PCI_X_CMD, if (pci_read_config_word(ioa_cfg->pdev, pcix_cmd_reg + PCI_X_CMD,
&ioa_cfg->saved_pcix_cmd_reg) != PCIBIOS_SUCCESSFUL) { &ioa_cfg->saved_pcix_cmd_reg) != PCIBIOS_SUCCESSFUL) {
...@@ -627,10 +625,6 @@ static int ipr_set_pcix_cmd_reg(struct ipr_ioa_cfg *ioa_cfg) ...@@ -627,10 +625,6 @@ static int ipr_set_pcix_cmd_reg(struct ipr_ioa_cfg *ioa_cfg)
dev_err(&ioa_cfg->pdev->dev, "Failed to setup PCI-X command register\n"); dev_err(&ioa_cfg->pdev->dev, "Failed to setup PCI-X command register\n");
return -EIO; return -EIO;
} }
} else {
dev_err(&ioa_cfg->pdev->dev,
"Failed to setup PCI-X command register\n");
return -EIO;
} }
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment