• Home
  • Raw
  • Download

Lines Matching refs:lport

97 	struct fc_lport	*lport;  member
474 static int fc_seq_send_locked(struct fc_lport *lport, struct fc_seq *sp, in fc_seq_send_locked() argument
510 error = lport->tt.frame_send(lport, fp); in fc_seq_send_locked()
536 int fc_seq_send(struct fc_lport *lport, struct fc_seq *sp, struct fc_frame *fp) in fc_seq_send() argument
542 error = fc_seq_send_locked(lport, sp, fp); in fc_seq_send()
820 static struct fc_exch *fc_exch_em_alloc(struct fc_lport *lport, in fc_exch_em_alloc() argument
887 ep->lp = lport; in fc_exch_em_alloc()
914 static struct fc_exch *fc_exch_alloc(struct fc_lport *lport, in fc_exch_alloc() argument
920 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_alloc()
922 ep = fc_exch_em_alloc(lport, ema->mp); in fc_exch_alloc()
937 struct fc_lport *lport = mp->lport; in fc_exch_find() local
947 lport->host->host_no, lport->port_id, xid, cpu); in fc_exch_find()
956 FC_LPORT_DBG(lport, "xid %x quarantined\n", xid); in fc_exch_find()
999 static struct fc_exch *fc_exch_resp(struct fc_lport *lport, in fc_exch_resp() argument
1006 ep = fc_exch_alloc(lport, fp); in fc_exch_resp()
1047 static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, in fc_seq_lookup_recip() argument
1102 ep = fc_exch_resp(lport, mp, fp); in fc_seq_lookup_recip()
1290 struct fc_lport *lport = ep->lp; in fc_seq_send_ack() local
1297 fp = fc_frame_alloc(lport, 0); in fc_seq_send_ack()
1334 lport->tt.frame_send(lport, fp); in fc_seq_send_ack()
1355 struct fc_lport *lport; in fc_exch_send_ba_rjt() local
1358 lport = fr_dev(rx_fp); in fc_exch_send_ba_rjt()
1360 fp = fc_frame_alloc(lport, sizeof(*rp)); in fc_exch_send_ba_rjt()
1408 lport->tt.frame_send(lport, fp); in fc_exch_send_ba_rjt()
1483 struct fc_seq *fc_seq_assign(struct fc_lport *lport, struct fc_frame *fp) in fc_seq_assign() argument
1487 WARN_ON(lport != fr_dev(fp)); in fc_seq_assign()
1491 list_for_each_entry(ema, &lport->ema_list, ema_list) in fc_seq_assign()
1493 fc_seq_lookup_recip(lport, ema->mp, fp) == FC_RJT_NONE) in fc_seq_assign()
1518 static void fc_exch_recv_req(struct fc_lport *lport, struct fc_exch_mgr *mp, in fc_exch_recv_req() argument
1529 lport = fc_vport_id_lookup(lport, ntoh24(fh->fh_d_id)); in fc_exch_recv_req()
1530 if (!lport) { in fc_exch_recv_req()
1534 fr_dev(fp) = lport; in fc_exch_recv_req()
1543 return fc_lport_recv(lport, fp); in fc_exch_recv_req()
1545 reject = fc_seq_lookup_recip(lport, mp, fp); in fc_exch_recv_req()
1564 fc_lport_recv(lport, fp); in fc_exch_recv_req()
1567 FC_LPORT_DBG(lport, "exch/seq lookup failed: reject %x\n", in fc_exch_recv_req()
1833 struct fc_lport *lport; in fc_seq_ls_acc() local
1838 lport = fr_dev(rx_fp); in fc_seq_ls_acc()
1840 fp = fc_frame_alloc(lport, sizeof(*acc)); in fc_seq_ls_acc()
1850 lport->tt.frame_send(lport, fp); in fc_seq_ls_acc()
1865 struct fc_lport *lport; in fc_seq_ls_rjt() local
1870 lport = fr_dev(rx_fp); in fc_seq_ls_rjt()
1872 fp = fc_frame_alloc(lport, sizeof(*rjt)); in fc_seq_ls_rjt()
1884 lport->tt.frame_send(lport, fp); in fc_seq_ls_rjt()
1930 static void fc_exch_pool_reset(struct fc_lport *lport, in fc_exch_pool_reset() argument
1940 if ((lport == ep->lp) && in fc_exch_pool_reset()
1975 void fc_exch_mgr_reset(struct fc_lport *lport, u32 sid, u32 did) in fc_exch_mgr_reset() argument
1980 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_mgr_reset()
1982 fc_exch_pool_reset(lport, in fc_exch_mgr_reset()
1996 static struct fc_exch *fc_exch_lookup(struct fc_lport *lport, u32 xid) in fc_exch_lookup() argument
2000 list_for_each_entry(ema, &lport->ema_list, ema_list) in fc_exch_lookup()
2014 struct fc_lport *lport; in fc_exch_els_rec() local
2024 lport = fr_dev(rfp); in fc_exch_els_rec()
2034 if (sid == fc_host_port_id(lport->host)) in fc_exch_els_rec()
2039 FC_LPORT_DBG(lport, in fc_exch_els_rec()
2044 ep = fc_exch_lookup(lport, xid); in fc_exch_els_rec()
2046 FC_LPORT_DBG(lport, in fc_exch_els_rec()
2057 fp = fc_frame_alloc(lport, sizeof(*acc)); in fc_exch_els_rec()
2078 lport->tt.frame_send(lport, fp); in fc_exch_els_rec()
2171 struct fc_seq *fc_exch_seq_send(struct fc_lport *lport, in fc_exch_seq_send() argument
2185 ep = fc_exch_alloc(lport, fp); in fc_exch_seq_send()
2196 ep->r_a_tov = lport->r_a_tov; in fc_exch_seq_send()
2197 ep->lp = lport; in fc_exch_seq_send()
2205 if (ep->xid <= lport->lro_xid && fh->fh_r_ctl == FC_RCTL_DD_UNSOL_CMD) { in fc_exch_seq_send()
2210 if (unlikely(lport->tt.frame_send(lport, fp))) in fc_exch_seq_send()
2241 struct fc_lport *lport; in fc_exch_rrq() local
2246 lport = ep->lp; in fc_exch_rrq()
2248 fp = fc_frame_alloc(lport, sizeof(*rrq)); in fc_exch_rrq()
2264 lport->port_id, FC_TYPE_ELS, in fc_exch_rrq()
2267 if (fc_exch_seq_send(lport, fp, fc_exch_rrq_resp, NULL, ep, in fc_exch_rrq()
2268 lport->e_d_tov)) in fc_exch_rrq()
2291 struct fc_lport *lport; in fc_exch_els_rrq() local
2298 lport = fr_dev(fp); in fc_exch_els_rrq()
2308 xid = fc_host_port_id(lport->host) == sid ? in fc_exch_els_rrq()
2310 ep = fc_exch_lookup(lport, xid); in fc_exch_els_rrq()
2357 void fc_exch_update_stats(struct fc_lport *lport) in fc_exch_update_stats() argument
2363 st = &lport->host_stats; in fc_exch_update_stats()
2365 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_update_stats()
2384 struct fc_exch_mgr_anchor *fc_exch_mgr_add(struct fc_lport *lport, in fc_exch_mgr_add() argument
2397 list_add_tail(&ema->ema_list, &lport->ema_list); in fc_exch_mgr_add()
2458 struct fc_exch_mgr *fc_exch_mgr_alloc(struct fc_lport *lport, in fc_exch_mgr_alloc() argument
2471 FC_LPORT_DBG(lport, "Invalid min_xid 0x:%x and max_xid 0x:%x\n", in fc_exch_mgr_alloc()
2484 mp->lport = lport; in fc_exch_mgr_alloc()
2528 if (!fc_exch_mgr_add(lport, mp, match)) { in fc_exch_mgr_alloc()
2553 void fc_exch_mgr_free(struct fc_lport *lport) in fc_exch_mgr_free() argument
2558 list_for_each_entry_safe(ema, next, &lport->ema_list, ema_list) in fc_exch_mgr_free()
2571 struct fc_lport *lport, in fc_find_ema() argument
2582 return list_entry(lport->ema_list.prev, in fc_find_ema()
2586 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_find_ema()
2598 void fc_exch_recv(struct fc_lport *lport, struct fc_frame *fp) in fc_exch_recv() argument
2605 if (!lport || lport->state == LPORT_ST_DISABLED) { in fc_exch_recv()
2613 ema = fc_find_ema(f_ctl, lport, fh); in fc_exch_recv()
2615 FC_LPORT_DBG(lport, "Unable to find Exchange Manager Anchor," in fc_exch_recv()
2642 fc_exch_recv_req(lport, ema->mp, fp); in fc_exch_recv()
2645 FC_LPORT_DBG(lport, "dropping invalid frame (eof %x)", in fc_exch_recv()
2656 int fc_exch_init(struct fc_lport *lport) in fc_exch_init() argument
2658 if (!lport->tt.exch_mgr_reset) in fc_exch_init()
2659 lport->tt.exch_mgr_reset = fc_exch_mgr_reset; in fc_exch_init()