STRUCT FC_EXCH_MGR(9)
π struct fc_exch_mgr(9) π
okay so this is from the Kernel API Manual and it's genuinely one of those pages that looks scary but is actually just... the Exchange Manager. the EM. say hi π«Ά
β¨ NAME β¨
struct fc_exch_mgr β The Exchange Manager (EM). that's it, that's the name, and honestly the acronym being "EM" is kind of iconic of the kernel ngl π
πΈ SYNOPSIS πΈ
bestie, here's the whole struct, verbatim, don't touch it:
struct fc_exch_mgr {
struct fc_exch_pool __percpu *pool;
mempool_t *ep_pool;
struct fc_lport *lport;
enum fc_class class;
struct kref kref;
u16 min_xid;
u16 max_xid;
u16 pool_max_index;
struct {
atomic_t no_free_exch;
atomic_t no_free_exch_xid;
atomic_t xid_not_found;
atomic_t xid_busy;
atomic_t seq_not_found;
atomic_t non_bls_resp;
} stats;
};
like, she's got layers π
π Members π
let's meet the cast, one by one, no skips:
poolβ per cpu exch pool. literally each CPU gets its own little pool, main character energy per core β¨ep_poolβ reserved exchange pointers. these are the backups, the understudies, the "we planned ahead" girlies πlportβ local exchange port. the home base πclassβ default class for new sequences. the vibe new sequences get assigned by default πkrefβ reference counter. keeping track of who's still holding on πmin_xidβ minimum exchange ID. the floor, the lower bound π¦max_xidβ maximum exchange ID. the ceiling, the upper bound βpool_max_indexβ max exch array index in exch pool. biggest index allowed in the pool's exch array, periodt πstatsβ statistics structure. she's got receipts:no_free_exch,no_free_exch_xid,xid_not_found,xid_busy,seq_not_found, andnon_bls_resp, allatomic_tπ
π Description π
okay so here's the tea π₯: this structure is the center for creating exchanges and sequences. like the main hub, the group chat admin, the one who actually knows what's going on. she manages the allocation of exchange IDs π β that's the whole job. no cap.
π§ SEE ALSO π§
genuinely obsessed with how long this list is, iykyk. it's all from the kernel file ./drivers/scsi/libfc/fc_exch.c:
struct fc_exch_pool(9)struct fc_exch_mgr_anchor(9)fc_exch_name_lookup(9)fc_exch_rctl_name(9)fc_exch_hold(9)fc_exch_setup_hdr(9)fc_exch_release(9)fc_exch_timer_cancel(9)fc_exch_timer_set_locked(9)fc_exch_timer_set(9)fc_exch_done_locked(9)fc_exch_ptr_get(9)fc_exch_ptr_set(9)fc_exch_delete(9)fc_seq_send(9)fc_seq_alloc(9)fc_seq_start_next_locked(9)fc_seq_start_next(9)fc_exch_abort_locked(9)fc_seq_exch_abort(9)fc_invoke_resp(9)fc_exch_timeout(9)fc_exch_em_alloc(9)fc_exch_alloc(9)fc_exch_find(9)fc_exch_done(9)fc_exch_resp(9)fc_seq_lookup_recip(9)fc_seq_lookup_orig(9)fc_exch_set_addr(9)fc_seq_els_rsp_send(9)fc_seq_send_last(9)fc_seq_send_ack(9)fc_exch_send_ba_rjt(9)fc_exch_recv_abts(9)fc_seq_assign(9)fc_seq_release(9)fc_exch_recv_req(9)fc_exch_recv_seq_resp(9)fc_exch_recv_resp(9)fc_exch_abts_resp(9)fc_exch_recv_bls(9)fc_seq_ls_acc(9)fc_seq_ls_rjt(9)fc_exch_reset(9)fc_exch_pool_reset(9)fc_exch_mgr_reset(9)fc_exch_lookup(9)fc_exch_els_rec(9)fc_exch_rrq_resp(9)fc_exch_seq_send(9)fc_exch_rrq(9)fc_exch_els_rrq(9)fc_exch_update_stats(9)fc_exch_mgr_add(9)fc_exch_mgr_destroy(9)fc_exch_mgr_del(9)fc_exch_mgr_list_clone(9)fc_exch_mgr_alloc(9)fc_exch_mgr_free(9)fc_find_ema(9)fc_exch_recv(9)fc_exch_init(9)fc_setup_exch_mgr(9)fc_destroy_exch_mgr(9)
like... that's a lot of friends and she loves them all π«Ά
aaaand that's the page!! π this one came out of ./drivers/scsi/libfc, dated October 2026, and the whole thing is filed under struct fc_exch_mgr(9). go read the source bestie, ily, bye π¦β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms