diff options
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_ct.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_ct.c | 62 |
1 files changed, 51 insertions, 11 deletions
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c index dbe020e66b09..e8bd7c122f1e 100644 --- a/drivers/scsi/lpfc/lpfc_ct.c +++ b/drivers/scsi/lpfc/lpfc_ct.c | |||
@@ -458,7 +458,7 @@ lpfc_ns_rsp(struct lpfc_vport *vport, struct lpfc_dmabuf *mp, uint32_t Size) | |||
458 | ((lpfc_find_vport_by_did(phba, Did) == NULL) || | 458 | ((lpfc_find_vport_by_did(phba, Did) == NULL) || |
459 | vport->cfg_peer_port_login)) { | 459 | vport->cfg_peer_port_login)) { |
460 | if ((vport->port_type != LPFC_NPIV_PORT) || | 460 | if ((vport->port_type != LPFC_NPIV_PORT) || |
461 | (!vport->ct_flags & FC_CT_RFF_ID) || | 461 | (!(vport->ct_flags & FC_CT_RFF_ID)) || |
462 | (!vport->cfg_restrict_login)) { | 462 | (!vport->cfg_restrict_login)) { |
463 | ndlp = lpfc_setup_disc_node(vport, Did); | 463 | ndlp = lpfc_setup_disc_node(vport, Did); |
464 | if (ndlp) { | 464 | if (ndlp) { |
@@ -854,8 +854,16 @@ lpfc_cmpl_ct_cmd_rft_id(struct lpfc_hba *phba, struct lpfc_iocbq *cmdiocb, | |||
854 | IOCB_t *irsp = &rspiocb->iocb; | 854 | IOCB_t *irsp = &rspiocb->iocb; |
855 | struct lpfc_vport *vport = cmdiocb->vport; | 855 | struct lpfc_vport *vport = cmdiocb->vport; |
856 | 856 | ||
857 | if (irsp->ulpStatus == IOSTAT_SUCCESS) | 857 | if (irsp->ulpStatus == IOSTAT_SUCCESS) { |
858 | vport->ct_flags |= FC_CT_RFT_ID; | 858 | struct lpfc_dmabuf *outp; |
859 | struct lpfc_sli_ct_request *CTrsp; | ||
860 | |||
861 | outp = (struct lpfc_dmabuf *) cmdiocb->context2; | ||
862 | CTrsp = (struct lpfc_sli_ct_request *) outp->virt; | ||
863 | if (CTrsp->CommandResponse.bits.CmdRsp == | ||
864 | be16_to_cpu(SLI_CT_RESPONSE_FS_ACC)) | ||
865 | vport->ct_flags |= FC_CT_RFT_ID; | ||
866 | } | ||
859 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); | 867 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); |
860 | return; | 868 | return; |
861 | } | 869 | } |
@@ -867,8 +875,16 @@ lpfc_cmpl_ct_cmd_rnn_id(struct lpfc_hba *phba, struct lpfc_iocbq *cmdiocb, | |||
867 | IOCB_t *irsp = &rspiocb->iocb; | 875 | IOCB_t *irsp = &rspiocb->iocb; |
868 | struct lpfc_vport *vport = cmdiocb->vport; | 876 | struct lpfc_vport *vport = cmdiocb->vport; |
869 | 877 | ||
870 | if (irsp->ulpStatus == IOSTAT_SUCCESS) | 878 | if (irsp->ulpStatus == IOSTAT_SUCCESS) { |
871 | vport->ct_flags |= FC_CT_RNN_ID; | 879 | struct lpfc_dmabuf *outp; |
880 | struct lpfc_sli_ct_request *CTrsp; | ||
881 | |||
882 | outp = (struct lpfc_dmabuf *) cmdiocb->context2; | ||
883 | CTrsp = (struct lpfc_sli_ct_request *) outp->virt; | ||
884 | if (CTrsp->CommandResponse.bits.CmdRsp == | ||
885 | be16_to_cpu(SLI_CT_RESPONSE_FS_ACC)) | ||
886 | vport->ct_flags |= FC_CT_RNN_ID; | ||
887 | } | ||
872 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); | 888 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); |
873 | return; | 889 | return; |
874 | } | 890 | } |
@@ -880,8 +896,16 @@ lpfc_cmpl_ct_cmd_rspn_id(struct lpfc_hba *phba, struct lpfc_iocbq *cmdiocb, | |||
880 | IOCB_t *irsp = &rspiocb->iocb; | 896 | IOCB_t *irsp = &rspiocb->iocb; |
881 | struct lpfc_vport *vport = cmdiocb->vport; | 897 | struct lpfc_vport *vport = cmdiocb->vport; |
882 | 898 | ||
883 | if (irsp->ulpStatus == IOSTAT_SUCCESS) | 899 | if (irsp->ulpStatus == IOSTAT_SUCCESS) { |
884 | vport->ct_flags |= FC_CT_RSPN_ID; | 900 | struct lpfc_dmabuf *outp; |
901 | struct lpfc_sli_ct_request *CTrsp; | ||
902 | |||
903 | outp = (struct lpfc_dmabuf *) cmdiocb->context2; | ||
904 | CTrsp = (struct lpfc_sli_ct_request *) outp->virt; | ||
905 | if (CTrsp->CommandResponse.bits.CmdRsp == | ||
906 | be16_to_cpu(SLI_CT_RESPONSE_FS_ACC)) | ||
907 | vport->ct_flags |= FC_CT_RSPN_ID; | ||
908 | } | ||
885 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); | 909 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); |
886 | return; | 910 | return; |
887 | } | 911 | } |
@@ -893,8 +917,16 @@ lpfc_cmpl_ct_cmd_rsnn_nn(struct lpfc_hba *phba, struct lpfc_iocbq *cmdiocb, | |||
893 | IOCB_t *irsp = &rspiocb->iocb; | 917 | IOCB_t *irsp = &rspiocb->iocb; |
894 | struct lpfc_vport *vport = cmdiocb->vport; | 918 | struct lpfc_vport *vport = cmdiocb->vport; |
895 | 919 | ||
896 | if (irsp->ulpStatus == IOSTAT_SUCCESS) | 920 | if (irsp->ulpStatus == IOSTAT_SUCCESS) { |
897 | vport->ct_flags |= FC_CT_RSNN_NN; | 921 | struct lpfc_dmabuf *outp; |
922 | struct lpfc_sli_ct_request *CTrsp; | ||
923 | |||
924 | outp = (struct lpfc_dmabuf *) cmdiocb->context2; | ||
925 | CTrsp = (struct lpfc_sli_ct_request *) outp->virt; | ||
926 | if (CTrsp->CommandResponse.bits.CmdRsp == | ||
927 | be16_to_cpu(SLI_CT_RESPONSE_FS_ACC)) | ||
928 | vport->ct_flags |= FC_CT_RSNN_NN; | ||
929 | } | ||
898 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); | 930 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); |
899 | return; | 931 | return; |
900 | } | 932 | } |
@@ -918,8 +950,16 @@ lpfc_cmpl_ct_cmd_rff_id(struct lpfc_hba *phba, struct lpfc_iocbq *cmdiocb, | |||
918 | IOCB_t *irsp = &rspiocb->iocb; | 950 | IOCB_t *irsp = &rspiocb->iocb; |
919 | struct lpfc_vport *vport = cmdiocb->vport; | 951 | struct lpfc_vport *vport = cmdiocb->vport; |
920 | 952 | ||
921 | if (irsp->ulpStatus == IOSTAT_SUCCESS) | 953 | if (irsp->ulpStatus == IOSTAT_SUCCESS) { |
922 | vport->ct_flags |= FC_CT_RFF_ID; | 954 | struct lpfc_dmabuf *outp; |
955 | struct lpfc_sli_ct_request *CTrsp; | ||
956 | |||
957 | outp = (struct lpfc_dmabuf *) cmdiocb->context2; | ||
958 | CTrsp = (struct lpfc_sli_ct_request *) outp->virt; | ||
959 | if (CTrsp->CommandResponse.bits.CmdRsp == | ||
960 | be16_to_cpu(SLI_CT_RESPONSE_FS_ACC)) | ||
961 | vport->ct_flags |= FC_CT_RFF_ID; | ||
962 | } | ||
923 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); | 963 | lpfc_cmpl_ct(phba, cmdiocb, rspiocb); |
924 | return; | 964 | return; |
925 | } | 965 | } |