UNION BMI_CTL(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… union bmi_ctl(9) β€” the BMI control register, bestie

okay so real talk: this is a page from the Kernel API Manual (section 9, kernel API, iykyk) and it's about union bmi_ctl β€” the BMI control register. tiny page, big main character energy. let's get into it πŸŽ€


✨ NAME ✨

union bmi_ctl β€” the BMI control register. that's it, that's the whole name. she's concise πŸ’…


🌸 SYNOPSIS 🌸

here's the whole shape of her, no cap, copy it exactly:

union bmi_ctl {
    u64 value;
    struct {
  #if (defined(__BIG_ENDIAN_BITFIELD));
      u64 raz_56_63 : 8;
      u64 ilk_hdrq_thrsh : 8;
      u64 nps_hdrq_thrsh : 8;
      u64 totl_hdrq_thrsh : 8;
      u64 ilk_free_thrsh : 8;
      u64 nps_free_thrsh : 8;
      u64 totl_free_thrsh : 8;
      u64 max_pkt_len : 8;
  #else;
      u64 max_pkt_len : 8;
      u64 totl_free_thrsh : 8;
      u64 nps_free_thrsh : 8;
      u64 ilk_free_thrsh : 8;
      u64 totl_hdrq_thrsh : 8;
      u64 nps_hdrq_thrsh : 8;
      u64 ilk_hdrq_thrsh : 8;
      u64 raz_56_63 : 8;
  #endif;
    } s;
 };

the way this is literally two views of the same 64 bits 🫢:

  • u64 value β€” the whole register as one single u64. grab it whole, she's right there.
  • struct { ... } s β€” the same thing sliced into eight 8-bit bitfields, so you can poke at individual bytes by name.

and the order flips depending on __BIG_ENDIAN_BITFIELD πŸ‘‘ β€” big-endian gets raz_56_63 first and max_pkt_len last; everyone else gets the reverse, max_pkt_len first and raz_56_63 last. the preprocessor is doing a little outfit change, we stan a conditional.

the bitfields, in big-endian reading order:

  • raz_56_63 β€” 8 bits
  • ilk_hdrq_thrsh β€” 8 bits
  • nps_hdrq_thrsh β€” 8 bits
  • totl_hdrq_thrsh β€” 8 bits
  • ilk_free_thrsh β€” 8 bits
  • nps_free_thrsh β€” 8 bits
  • totl_free_thrsh β€” 8 bits
  • max_pkt_len β€” 8 bits

every single one is : 8. eight of them. sixty-four bits total. the math is mathing ✨


πŸ¦‹ Members πŸ¦‹

there's a Members section here and it is, and I cannot stress this enough, completely empty. nothing listed. a blank little runway. not me scrolling looking for content 😭 consider this a vibe check she did not pass β€” but fr fr, the members are the bitfields up in the synopsis, bestie, they're right there πŸ’–


πŸ’€ SEE ALSO πŸ’€

the whole extended friend group, and yes, we're listing all of them because nobody gets left on read:

  • union ucd_core_eid_ucode_block_num(9)
  • union aqm_grp_execmsk_lo(9)
  • union aqm_grp_execmsk_hi(9)
  • union aqmq_drbl(9)
  • union aqmq_qsz(9)
  • union aqmq_cmp_thr(9)
  • union aqmq_cmp_cnt(9)
  • union aqmq_en(9)
  • union aqmq_activity_stat(9)
  • union emu_fuse_map(9)
  • union emu_se_enable(9)
  • union emu_ae_enable(9)
  • union emu_wd_int_ena_w1s(9)
  • union emu_ge_int_ena_w1s(9)
  • union nps_pkt_slc_ctl(9)
  • union nps_pkt_slc_cnts(9)
  • union nps_pkt_slc_int_levels(9)
  • union nps_pkt_in_done_cnts(9)
  • union nps_pkt_in_instr_ctl(9)
  • union nps_pkt_in_instr_rsize(9)
  • union nps_pkt_in_instr_baoff_dbell(9)
  • union nps_core_int_ena_w1s(9)
  • union nps_core_gbl_vfcfg(9)
  • union nps_core_int_active(9)
  • union efl_core_int(9)
  • union efl_core_int_ena_w1s(9)
  • union efl_rnm_ctl_status(9)
  • union bmi_int_ena_w1s(9)
  • union bmo_ctl2(9)
  • union pom_int_ena_w1s(9)
  • union lbc_inval_ctl(9)
  • union lbc_int_ena_w1s(9)
  • union lbc_int(9)
  • union lbc_inval_status(9)
  • union rst_boot(9)
  • union fus_dat1(9)

and where does she actually live? kernel file ./drivers/crypto/cavium/nitrox/nitrox_csr.h β€” and the original line ends with a stray union hanging out there, so we're preserving it because we do not touch the source material πŸ™ˆ

also note: bmi_int_ena_w1s(9) is right there in the list and it sounds like her sibling, but nobody said they were the same thing, so don't come for me, I'm just reading the page πŸ’…

🧚 sign-off 🧚

that's the whole page, bestie β€” short, sweet, and full of bytes. this little icon comes from source ./drivers/crypto/cavium/nitrox, dated October 2026, and it's filed under union bmi_ctl(9). go forth and threshold responsibly βœ¨πŸ’–πŸŒˆ

πŸ“¦ where this page comes from