omap_set_pwrdm_state(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… omap_set_pwrdm_state(9) ✨

okay bestie, welcome to the Kernel API Manual β€” this one's about omap_set_pwrdm_state, and it's literally the glow-up button for a powerdomain's vibe (its power state, obvi). 🫢


✨ NAME ✨

omap_set_pwrdm_state β€” change a powerdomain's current power state πŸ’«


πŸŽ€ SYNOPSIS πŸŽ€

int omap_set_pwrdm_state (struct powerdomain *pwrdm , u8 pwrst );

🌸 ARGUMENTS 🌸

  • pwrdm β€” a struct powerdomain *, i.e. the powerdomain whose power state you're about to change, mwah πŸ’–
  • pwrst β€” the power state you want to change to, periodt ✨

πŸ‘‘ DESCRIPTION πŸ‘‘

So here's the tea: this function changes the current hardware power state of the powerdomain represented by pwrdm to the power state represented by pwrst. Slay. πŸ’…

Now the return-value lore, and bestie you gotta listen:

  • It returns -EINVAL if pwrdm is null or invalid, or if the powerdomain's current power state could not be read 😭
  • It returns 0 upon success or if pwrdm does not support pwrst or any lower-power state πŸ¦‹
⚠️ XXX β€” okay so the original devs left a note here and it's kind of a big deal: it says it should not return 0 if the pwrdm does not support pwrst or any lower-power state β€” like, that should be an error. So yeah, that 0 is giving "everything's fine" when it is not, in fact, fine. πŸ’€

🌈 SEE ALSO 🌈

Kernel file ./arch/arm/mach-omap2/powerdomain.c β€” and honestly, the whole friend group:


and that's the whole page, bestie, no cap πŸ§šπŸ’œ

k bye ily β€” this one came from ./arch/arm/mach-omap2, dated October 2026, so it's fresh off the kernel sidewalk πŸ“β­

πŸ“¦ where this page comes from