ufs_qcom_setup_clocks(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ ufs_qcom_setup_clocks(9) ✨

okay so bestie, this is a page from the Kernel API Manual, and it's all about one lil' function that turns clocks on and off πŸ•°οΈπŸ’–


🌸 NAME 🌸

ufs_qcom_setup_clocks β€” enables/disable clocks


πŸŽ€ SYNOPSIS πŸŽ€

int ufs_qcom_setup_clocks (struct ufs_hba *hba , bool on , enum
       ufs_notify_change_status status );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • hba β€” the host controller instance, aka the main character here πŸ‘‘
  • on β€” if it's true, we enable the clocks; otherwise we disable them. Simple as that, no cap πŸ’…
  • status β€” either PRE_CHANGE or POST_CHANGE notify. pick your moment bestie ⏰

πŸ’œ DESCRIPTION πŸ’œ

So here's the tea β˜•: there are certain clocks that come from the PHY, which means they gotta be managed together with the controller clocks β€” and lowkey that's also just better for power saving, fr fr 🌱✨

That's literally why the phy_power_off/on calls live inside ufs_qcom_setup_clocks β€” so that the PHY's regulators & clks can be turned on/off right along with UFS's clocks. team work makes the dream work 🫢


πŸ”₯ RETURN πŸ”₯

0 on success, non-zero on failure. slay when it works, sad girl hours when it doesn't 😭


🌈 SEE ALSO 🌈

Kernel file ./drivers/ufs/host/ufs-qcom.c


πŸ’Œ and that's the whole page bestie! it lives in ./drivers/ufs/host, it's dated October 2026, and that's the ufs_qcom_setup_clocks(9) moment β€” periodt πŸŽ€βœ¨
πŸ“¦ where this page comes from