_clktrctrl_write(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… _clktrctrl_write(9) β€” like, the Kernel API Manual, bestie πŸŽ€

okay so this is a page from the Kernel API Manual, section 9, and the star of the show is _clktrctrl_write. Buckle up, it's a tiny function with a big job πŸ’–


✨ NAME ✨

_clktrctrl_write β€” write @c to a CM_CLKSTCTRL.CLKTRCTRL register bitfield 🌸


πŸ¦‹ SYNOPSIS πŸ¦‹

void _clktrctrl_write (u8 c , u8 part , u16 inst , u16 cdoffs );

that's the whole signature, no cap β€” returns nothing (void), takes four little args 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • c β€” the CLKTRCTRL register bitfield, and listen: it's the LSB = bit 0, i.e., unshifted value. like, do NOT pre-shift it, she handles that herself πŸ’…
  • part β€” the PRCM partition ID that the CM_CLKSTCTRL register lives in 🏠
  • inst β€” the CM instance register offset (that's the *_INST macro) ⭐
  • cdoffs β€” the clockdomain register offset (that's the *_CDOFFS macro) πŸ¦‹

πŸ’œ DESCRIPTION πŸ’œ

so c must be the unshifted value for CLKTRCTRL β€” like, genuinely unshifted β€” because this function will handle the shift itself. she's got it, bestie, don't do her job for her πŸ™ˆβœ¨


🌈 SEE ALSO 🌈

the whole friend group 🫢 also peep the kernel file ./arch/arm/mach-omap2/cminst44xx.c:


main character energy only: unshifted c in, correct bitfield out πŸ’€ no pre-shifting, iykyk

and that's the vibe check, bestie πŸ‘‘ this iconic lil page came from ./arch/arm/mach-omap2 and is dated October 2026 β€” periodt, slay, go write some registers πŸ’–πŸ”₯

πŸ“¦ where this page comes from