diff options
author | James Smart <james.smart@emulex.com> | 2011-07-22 18:37:42 -0400 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2011-07-27 07:14:00 -0400 |
commit | b76f2dc91c0fff7a66616affdc039dc2e4b7ff98 (patch) | |
tree | c918b99e5e368f32118044a3ecbb4e793443028c /drivers/scsi/lpfc/lpfc_attr.c | |
parent | 0a96e9754d6c4a2a31e50ee6c6e36ec13f80bc25 (diff) |
[SCSI] lpfc 8.3.25: Enhancements to Debug infrastructure
Enhancements to Debug infrastructure
- debugfs additions for new hardware.
- Correct stack overflow in lpfc_debugfs_dumpHBASlim_data()
- Correct warning on uninitialized reg_val in lpfc_idiag_drbacc_write()
- Separated the iDiag command for capturing mailbox commands for generic
issue mailbox command entry point and for BSG multi-buffer handling.
- Added capturing dumping capabiliy of mailbox command and external buffer
for the completion of the mailbox command so that the outcome can be
examined.
- Changed all the iDiag command structure data array indexing introduced so
far with properly defined macros.
- Added SLI4 device PCI BAR memory mapped register read/browse, write-by-
value, set-bit, and clear-bit methods for both interface type 0 and
interface type 2.
- Corrected warnings on mbxstatus being uninitialized in error paths in
lpfc_bsg.c
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_attr.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_attr.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/scsi/lpfc/lpfc_attr.c b/drivers/scsi/lpfc/lpfc_attr.c index 80ca11c5158c..fa5bc146d67b 100644 --- a/drivers/scsi/lpfc/lpfc_attr.c +++ b/drivers/scsi/lpfc/lpfc_attr.c | |||
@@ -810,6 +810,7 @@ static ssize_t | |||
810 | lpfc_sli4_pdev_reg_request(struct lpfc_hba *phba, uint32_t opcode) | 810 | lpfc_sli4_pdev_reg_request(struct lpfc_hba *phba, uint32_t opcode) |
811 | { | 811 | { |
812 | struct completion online_compl; | 812 | struct completion online_compl; |
813 | struct pci_dev *pdev = phba->pcidev; | ||
813 | uint32_t reg_val; | 814 | uint32_t reg_val; |
814 | int status = 0; | 815 | int status = 0; |
815 | int rc; | 816 | int rc; |
@@ -822,6 +823,14 @@ lpfc_sli4_pdev_reg_request(struct lpfc_hba *phba, uint32_t opcode) | |||
822 | LPFC_SLI_INTF_IF_TYPE_2)) | 823 | LPFC_SLI_INTF_IF_TYPE_2)) |
823 | return -EPERM; | 824 | return -EPERM; |
824 | 825 | ||
826 | if (!pdev->is_physfn) | ||
827 | return -EPERM; | ||
828 | |||
829 | /* Disable SR-IOV virtual functions if enabled */ | ||
830 | if (phba->cfg_sriov_nr_virtfn) { | ||
831 | pci_disable_sriov(pdev); | ||
832 | phba->cfg_sriov_nr_virtfn = 0; | ||
833 | } | ||
825 | status = lpfc_do_offline(phba, LPFC_EVT_OFFLINE); | 834 | status = lpfc_do_offline(phba, LPFC_EVT_OFFLINE); |
826 | 835 | ||
827 | if (status != 0) | 836 | if (status != 0) |