of_genpd_add_child_ids(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… of_genpd_add_child_ids(9) β€” like, the Kernel API Manual entry, but make it make sense πŸŽ€

okay bestie, so you know how this whole thing lives in of_genpd_add_child_ids(9)? yeah. that's the one. we're doing the genpd child-ids function today and honestly it's giving "quietly important" ✨


πŸ’– NAME πŸ’–

of_genpd_add_child_ids β€” it parses the power-domains-child-ids property, no cap πŸ¦‹


✨ SYNOPSIS ✨

int of_genpd_add_child_ids (struct device_node *np , struct genpd_onecell_data *data );

like literally that's the whole signature, she's compact πŸ‘‘


🌸 ARGUMENTS 🌸

  • np β€” a device node pointer that's associated with the PM domain provider. that's her whole job. she's the node. the provider's node. 🧚
  • data β€” pointer to the onecell data that goes with the PM domain provider. also known as "the onecell data associated with the PM domain provider", because we said that already, and we're saying it again πŸ’…

πŸ”₯ DESCRIPTION πŸ”₯

so what she actually does is parse the power-domains and power-domains-child-ids properties to establish parent-child relationships for PM domains. the way that works: power-domains lists the parent domains, and power-domains-child-ids lists which child domain IDs should be associated with each parent. matching them up, basically. cupid but for power domains 🫢

and here's the part where she's a total main character β€” it's "all or nothing" semantics. either all the relationships get established successfully, or none of them do. if something errors out partway, any partially-added relationships get unwound. no half-finished situationships here, periodt. πŸ’€

her return values, bestie, listen up:

  • she returns the number of parent-child relationships established on success πŸŽ‰
  • she returns 0 if the properties don't exist πŸ™ˆ
  • she returns a negative error code on failure 😭

πŸ¦‹ SEE ALSO πŸ¦‹

first off, the kernel file herself: ./drivers/pmdomain/core.c β€” that's home base 🏠

and then, because genpd has a lot going on, here's the extended family:

like, that's the whole group chat. iykyk πŸ’œ


and that's the page, bestie πŸŽ€ source/version lives in ./drivers/pmdomain, dated October 2026, and the whole thing is filed under of_genpd_add_child_ids(9). slay. go forth and parse those child IDs responsibly πŸ’–βœ¨πŸŒˆ

πŸ“¦ where this page comes from