Lines Matching refs:ema
910 struct fc_exch_mgr_anchor *ema; in fc_exch_alloc() local
913 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_alloc()
914 if (!ema->match || ema->match(fp)) { in fc_exch_alloc()
915 ep = fc_exch_em_alloc(lport, ema->mp); in fc_exch_alloc()
1478 struct fc_exch_mgr_anchor *ema; in fc_seq_assign() local
1484 list_for_each_entry(ema, &lport->ema_list, ema_list) in fc_seq_assign()
1485 if ((!ema->match || ema->match(fp)) && in fc_seq_assign()
1486 fc_seq_lookup_recip(lport, ema->mp, fp) == FC_RJT_NONE) in fc_seq_assign()
1970 struct fc_exch_mgr_anchor *ema; in fc_exch_mgr_reset() local
1973 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_mgr_reset()
1976 per_cpu_ptr(ema->mp->pool, cpu), in fc_exch_mgr_reset()
1991 struct fc_exch_mgr_anchor *ema; in fc_exch_lookup() local
1993 list_for_each_entry(ema, &lport->ema_list, ema_list) in fc_exch_lookup()
1994 if (ema->mp->min_xid <= xid && xid <= ema->mp->max_xid) in fc_exch_lookup()
1995 return fc_exch_find(ema->mp, xid); in fc_exch_lookup()
2353 struct fc_exch_mgr_anchor *ema; in fc_exch_update_stats() local
2358 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_exch_update_stats()
2359 mp = ema->mp; in fc_exch_update_stats()
2381 struct fc_exch_mgr_anchor *ema; in fc_exch_mgr_add() local
2383 ema = kmalloc(sizeof(*ema), GFP_ATOMIC); in fc_exch_mgr_add()
2384 if (!ema) in fc_exch_mgr_add()
2385 return ema; in fc_exch_mgr_add()
2387 ema->mp = mp; in fc_exch_mgr_add()
2388 ema->match = match; in fc_exch_mgr_add()
2390 list_add_tail(&ema->ema_list, &lport->ema_list); in fc_exch_mgr_add()
2392 return ema; in fc_exch_mgr_add()
2413 void fc_exch_mgr_del(struct fc_exch_mgr_anchor *ema) in fc_exch_mgr_del() argument
2416 list_del(&ema->ema_list); in fc_exch_mgr_del()
2417 kref_put(&ema->mp->kref, fc_exch_mgr_destroy); in fc_exch_mgr_del()
2418 kfree(ema); in fc_exch_mgr_del()
2429 struct fc_exch_mgr_anchor *ema, *tmp; in fc_exch_mgr_list_clone() local
2431 list_for_each_entry(ema, &src->ema_list, ema_list) { in fc_exch_mgr_list_clone()
2432 if (!fc_exch_mgr_add(dst, ema->mp, ema->match)) in fc_exch_mgr_list_clone()
2437 list_for_each_entry_safe(ema, tmp, &dst->ema_list, ema_list) in fc_exch_mgr_list_clone()
2438 fc_exch_mgr_del(ema); in fc_exch_mgr_list_clone()
2548 struct fc_exch_mgr_anchor *ema, *next; in fc_exch_mgr_free() local
2551 list_for_each_entry_safe(ema, next, &lport->ema_list, ema_list) in fc_exch_mgr_free()
2552 fc_exch_mgr_del(ema); in fc_exch_mgr_free()
2567 struct fc_exch_mgr_anchor *ema; in fc_find_ema() local
2576 typeof(*ema), ema_list); in fc_find_ema()
2579 list_for_each_entry(ema, &lport->ema_list, ema_list) { in fc_find_ema()
2580 if ((xid >= ema->mp->min_xid) && in fc_find_ema()
2581 (xid <= ema->mp->max_xid)) in fc_find_ema()
2582 return ema; in fc_find_ema()
2594 struct fc_exch_mgr_anchor *ema; in fc_exch_recv() local
2606 ema = fc_find_ema(f_ctl, lport, fh); in fc_exch_recv()
2607 if (!ema) { in fc_exch_recv()
2628 fc_exch_recv_bls(ema->mp, fp); in fc_exch_recv()
2631 fc_exch_recv_seq_resp(ema->mp, fp); in fc_exch_recv()
2633 fc_exch_recv_resp(ema->mp, fp); in fc_exch_recv()
2635 fc_exch_recv_req(lport, ema->mp, fp); in fc_exch_recv()