STRUCT MACSEC_TX_SA(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ NAME πŸŽ€

Bestie, meet struct macsec_tx_sa(9) from the Kernel API Manual β€” aka the transmit secure association. The manual name is folded right here in the intro instead of being copied as a header line, periodt 🫢.

✨ SYNOPSIS ✨

Okay so here's the whole struct, no cap β€” copy-paste energy, but make it iconic:

       struct macsec_tx_sa {
           struct macsec_key key;
           ssci_t ssci;
           spinlock_t lock;
           union {
             pn_t next_pn_halves;
             u64 next_pn;
           };
           refcount_t refcnt;
           bool active;
           struct macsec_tx_sa_stats __percpu *stats;
           struct rcu_work destroy_work;
        };

πŸ¦‹ Members πŸ¦‹

  • key β€” the key structure πŸ’–
  • ssci β€” the short secure channel identifier πŸ†”
  • lock β€” this one protects next_pn manipulations πŸ”’
  • {unnamed_union} β€” anonymous, bestie. The code block has pn_t next_pn_halves; and u64 next_pn; living inside it, and the note below is all about next_pn πŸ’…
  • next_pn β€” packet number to use for the next packet πŸ“¦
  • active β€” the page literally doesn't describe this one, so we're not inventing lore πŸ™ˆ
  • stats β€” per-SA stats πŸ“Š
  • destroy_work β€” deferred work to free the SA in process context after RCU grace period 🧹✨

Tiny note: the code block also contains refcount_t refcnt; β€” the Members list doesn't describe it, so we're just acknowledging it exists, bestie πŸ’….

🌈 SEE ALSO 🌈

Kernel file ./include/net/macsec.h β€” go check these out, bestie:

  • struct macsec_key(9)
  • struct macsec_rx_sa(9)
  • struct macsec_rx_sc(9)
  • struct macsec_tx_sc(9)
  • struct macsec_secy(9)
  • struct macsec_context(9)
  • struct macsec_ops(9)

Okay that's the whole page β€” slay! Cute sign-off: source/version vibes come from ./include/net, dated October 2026, and the footer's manual tag is struct macsec_tx_sa(9). Bye bestie, go free that SA in process context after the RCU grace period πŸ’–πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from