ufshcd_set_variant(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… ufshcd_set_variant(9) β€” like, the Kernel API Manual page, bestie ✨

okay so picture this: it's a Kernel API Manual page, it's called ufshcd_set_variant(9), and it's genuinely so short you could read it in the time it takes to microwave a bagel πŸ₯―. But it's a baddie of a function and it does exactly one job, so let's get into it.


🌸 NAME 🌸

ufshcd_set_variant β€” sets the variant-specific data onto the hba πŸ’… like that's literally the whole personality


✨ SYNOPSIS ✨

void ufshcd_set_variant (struct ufs_hba *hba , void *variant );

it returns void, so like… don't go looking for a return value, she gives you nothing back and she's iconic for it πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • hba β€” the per adapter instance 🫢 yes, per adapter, each one gets its own, don't be weird about it
  • variant β€” a pointer to the variant specific data πŸ¦‹ that's it, that's the pointer, it's just vibes and a void *

πŸ’œ SEE ALSO πŸ’œ

okay this is the part where the page goes FULL main character and name-drops literally everyone in the group chat 😭 and yes, we're listing every single one, no skipping, no "etc.", because bestie we do NOT do that here:

Kernel file ./include/ufs/ufshcd.h and also:

  • struct uic_command(9)
  • struct ufshcd_lrb(9)
  • struct ufs_query_req(9)
  • struct ufs_query_res(9)
  • struct ufs_query(9)
  • struct ufs_dev_cmd(9)
  • struct ufs_clk_info(9)
  • struct tx_eqtr_iter(9)
  • struct ufshcd_tx_eq_settings(9)
  • struct ufshcd_tx_eqtr_data(9)
  • struct ufshcd_tx_eqtr_record(9)
  • struct ufshcd_tx_eq_params(9)
  • struct ufs_hba_variant_ops(9)
  • struct ufs_clk_gating(9)
  • struct ufs_clk_scaling(9)
  • struct ufs_event_hist(9)
  • struct ufs_stats(9)
  • enum ufshcd_state(9)
  • enum ufshcd_pmc_policy(9)
  • struct ufshcd_mcq_opr_info_t(9)
  • struct ufs_hba(9)
  • struct ufs_hw_queue(9)
  • ufshcd_rmwl(9)
  • ufshcd_get_variant(9)

like, the whole friend group showed up to the function's birthday party πŸŒˆπŸŽ‚ and ufshcd_get_variant(9) is right there at the end being the obvious counterpart β€” the getter to this setter, iykyk 😌


lowkey a whole vibe check of a page: ./include/ufs, October 2026 β€” that's where she lives and when she was last seen out πŸ’€βœ¨ slay, go set that variant, bestie πŸ«ΆπŸ’–πŸŽ€
πŸ“¦ where this page comes from