diff options
author | Dick Kennedy <dick.kennedy@broadcom.com> | 2017-09-30 02:34:40 +0200 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2017-10-03 04:46:39 +0200 |
commit | 42270dce9d78acbaa5b9ca4fd4e82d251a8d099b (patch) | |
tree | 7dc35aadef5a38cfa4141fbdc60472029215c6c0 /drivers/scsi/lpfc | |
parent | scsi: lpfc: Fix oops if nvmet_fc_register_targetport fails (diff) | |
download | linux-42270dce9d78acbaa5b9ca4fd4e82d251a8d099b.tar.xz linux-42270dce9d78acbaa5b9ca4fd4e82d251a8d099b.zip |
scsi: lpfc: Disable NPIV support if NVME is enabled
The initial implementation of NVME didn't merge with NPIV support. As
such, there are several issues if NPIV is used with NVME. For now,
ensure that if NVME is enabled then NPIV is not enabled.
Support for NPIV with NVME will be added in the near future.
Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <james.smart@broadcom.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/lpfc')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_vport.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/scsi/lpfc/lpfc_vport.c b/drivers/scsi/lpfc/lpfc_vport.c index c714482bf4c5..c9d33b1268cb 100644 --- a/drivers/scsi/lpfc/lpfc_vport.c +++ b/drivers/scsi/lpfc/lpfc_vport.c @@ -313,6 +313,15 @@ lpfc_vport_create(struct fc_vport *fc_vport, bool disable) goto error_out; } + /* NPIV is not supported if HBA has NVME enabled */ + if (phba->cfg_enable_fc4_type & LPFC_ENABLE_NVME) { + lpfc_printf_log(phba, KERN_ERR, LOG_VPORT, + "3189 Create VPORT failed: " + "NPIV is not supported on NVME\n"); + rc = VPORT_INVAL; + goto error_out; + } + vpi = lpfc_alloc_vpi(phba); if (vpi == 0) { lpfc_printf_log(phba, KERN_ERR, LOG_VPORT, |