Lines Matching defs:fcport

127 	fc_port_t *fcport, bool local);
545 static int qla24xx_post_nack_work(struct scsi_qla_host *vha, fc_port_t *fcport,
554 e->u.nack.fcport = fcport;
567 sp->name, res, sp->fcport->port_name, sp->type);
570 sp->fcport->flags &= ~FCF_ASYNC_SENT;
571 sp->fcport->chip_reset = vha->hw->base_qpair->chip_reset;
575 sp->fcport->login_gen++;
576 sp->fcport->fw_login_state = DSC_LS_PLOGI_COMP;
577 sp->fcport->logout_on_delete = 1;
578 sp->fcport->plogi_nack_done_deadline = jiffies + HZ;
579 sp->fcport->send_els_logo = 0;
583 sp->fcport->fw_login_state = DSC_LS_PRLI_COMP;
584 sp->fcport->deleted = 0;
585 sp->fcport->send_els_logo = 0;
587 if (!sp->fcport->login_succ &&
588 !IS_SW_RESV_ADDR(sp->fcport->d_id)) {
589 sp->fcport->login_succ = 1;
593 qla24xx_sched_upd_fcport(sp->fcport);
596 sp->fcport->login_retry = 0;
597 qla2x00_set_fcport_disc_state(sp->fcport,
599 sp->fcport->deleted = 0;
600 sp->fcport->logout_on_delete = 1;
605 sp->fcport->login_gen++;
606 sp->fcport->fw_login_state = DSC_LS_PORT_UNAVAIL;
607 qlt_logo_completion_handler(sp->fcport, MBS_COMMAND_COMPLETE);
615 int qla24xx_async_notify_ack(scsi_qla_host_t *vha, fc_port_t *fcport,
622 fcport->flags |= FCF_ASYNC_SENT;
625 fcport->fw_login_state = DSC_LS_PLOGI_PEND;
629 fcport->fw_login_state = DSC_LS_PRLI_PEND;
630 fcport->deleted = 0;
634 fcport->fw_login_state = DSC_LS_LOGO_PEND;
639 sp = qla2x00_get_sp(vha, fcport, GFP_ATOMIC);
654 sp->name, fcport->port_name, sp->handle, c);
665 fcport->flags &= ~FCF_ASYNC_SENT;
675 t = e->u.nack.fcport;
679 t = qlt_create_sess(vha, e->u.nack.fcport, 0);
685 vha->hw->tgt.tgt_ops->put_sess(e->u.nack.fcport);
689 qla24xx_async_notify_ack(vha, e->u.nack.fcport,
695 fc_port_t *fcport = container_of(work, struct fc_port, del_work);
696 struct qla_hw_data *ha = fcport->vha->hw;
698 if (fcport->se_sess) {
699 ha->tgt.tgt_ops->shutdown_sess(fcport);
700 ha->tgt.tgt_ops->put_sess(fcport);
702 qlt_unreg_sess(fcport);
709 void qlt_fc_port_added(struct scsi_qla_host *vha, fc_port_t *fcport)
713 struct fc_port *sess = fcport;
725 if (fcport->disc_state == DSC_DELETE_PEND) {
734 sess = qlt_create_sess(vha, fcport, false);
739 if (fcport->fw_login_state == DSC_LS_PRLI_COMP) {
760 ha->tgt.tgt_ops->update_sess(sess, fcport->d_id,
761 fcport->loop_id,
762 (fcport->flags & FCF_CONF_COMP_SUPPORTED));
769 fcport->port_name, sess->loop_id);
823 fc_port_t *fcport = pla->fcport;
846 fcport->loop_id = loop_id;
847 fcport->d_id = port_id;
849 qla24xx_post_nack_work(vha, fcport, iocb, SRB_NACK_PLOGI);
851 qla24xx_post_nack_work(vha, fcport, iocb, SRB_NACK_PRLI);
853 list_for_each_entry(fcport, &vha->vp_fcports, list) {
854 if (fcport->plogi_link[QLT_PLOGI_LINK_SAME_WWN] == pla)
855 fcport->plogi_link[QLT_PLOGI_LINK_SAME_WWN] = NULL;
856 if (fcport->plogi_link[QLT_PLOGI_LINK_CONFLICT] == pla)
857 fcport->plogi_link[QLT_PLOGI_LINK_CONFLICT] = NULL;
895 pla->fcport = sess;
1349 fc_port_t *fcport,
1353 struct fc_port *sess = fcport;
1359 if (fcport->se_sess) {
1366 return fcport;
1382 &fcport->port_name[0], sess) < 0) {
1385 vha->vp_idx, fcport->port_name);
1388 kref_init(&fcport->sess_kref);
1416 vha->vp_idx, local ? "local " : "", fcport->port_name,
1417 fcport->loop_id, sess->d_id.b.domain, sess->d_id.b.area,
1428 qlt_fc_port_deleted(struct scsi_qla_host *vha, fc_port_t *fcport, int max_gen)
1431 struct fc_port *sess = fcport;
4545 void qlt_logo_completion_handler(fc_port_t *fcport, int rc)
4548 ql_dbg(ql_dbg_tgt_mgt, fcport->vha, 0xf093,
4553 fcport->se_sess,
4554 fcport,
4555 fcport->port_name, fcport->loop_id,
4556 fcport->d_id.b.domain, fcport->d_id.b.area,
4557 fcport->d_id.b.al_pa, rc);
4560 fcport->logout_completed = 1;
6009 fc_port_t *fcport, *tfcp, *del;
6014 fcport = qla2x00_alloc_fcport(vha, GFP_KERNEL);
6015 if (!fcport) {
6022 fcport->loop_id = loop_id;
6024 rc = qla24xx_gpdb_wait(vha, fcport, 0);
6027 "qla_target(%d): Failed to retrieve fcport "
6030 kfree(fcport);
6036 tfcp = qla2x00_find_fcport_by_wwpn(vha, fcport->port_name, 1);
6039 tfcp->d_id = fcport->d_id;
6040 tfcp->port_type = fcport->port_type;
6041 tfcp->supported_classes = fcport->supported_classes;
6042 tfcp->flags |= fcport->flags;
6045 del = fcport;
6046 fcport = tfcp;
6049 fcport->flags |= FCF_FABRIC_DEVICE;
6051 list_add_tail(&fcport->list, &vha->vp_fcports);
6052 if (!IS_SW_RESV_ADDR(fcport->d_id))
6054 fcport->login_gen++;
6055 qla2x00_set_fcport_disc_state(fcport, DSC_LOGIN_COMPLETE);
6056 fcport->login_succ = 1;
6060 fcport->deleted = 0;
6068 qla24xx_sched_upd_fcport(fcport);
6072 __func__, __LINE__, fcport->port_name, vha->fcport_count);
6073 qla24xx_post_gpsc_work(vha, fcport);
6085 return fcport;
6093 fc_port_t *fcport = NULL;
6134 fcport = qlt_get_port_database(vha, loop_id);
6135 if (!fcport) {
6151 sess = qlt_create_sess(vha, fcport, true);