add_changeset_property(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

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

okay so real talk, this is a page from the Kernel API Manual and it's called add_changeset_property(9). it's giving "tiny function, big responsibilities" energy and honestly? we're obsessed. let's get into it πŸ¦‹


✨ NAME ✨

add_changeset_property β€” the girl whose whole job is to add @overlay_prop to an overlay changeset 🫢


🌸 SYNOPSIS 🌸

int add_changeset_property (struct overlay_changeset *ovcs , struct
       target *target , const struct property *overlay_prop , bool
       is_symbols_prop );

like, look at that signature. four whole arguments. she's that girl πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • ovcs β€” the overlay changeset. the main character, the container, the whole vibe 🌈
  • target β€” literally where overlay_prop will be placed. the destination. the location. iykyk πŸ“
  • overlay_prop β€” the property we're adding or updating, straight out of the overlay tree. she came from the overlay tree and she's ready for her moment ✨
  • is_symbols_prop β€” 1 if overlay_prop is from the node "/__symbols__". just a little bool flag doing bool flag things πŸ’–

πŸ”₯ DESCRIPTION πŸ”₯

so here's the tea, bestie. if overlay_prop does not already exist in the live devicetree, we add a changeset entry that adds overlay_prop into target. but if it does already exist? then we add a changeset entry that updates the value of overlay_prop instead. either way, she's getting in. no cap πŸ’€

now, target is flexible like that β€” it may be either in the live devicetree or in a new subtree that's contained in the changeset. both are valid. we love options πŸ¦‹

some special properties are straight-up not added or updated, and β€” plot twist β€” no error is returned when that happens:

  • "name"
  • "phandle"
  • "linux,phandle"

like they just don't get an invite to the party and nobody makes a scene πŸ™ˆ

as for properties "#address-cells" and "#size-cells"? they are not updated if they're already in the live tree. but!! if they're present in the live tree, the values in the overlay must match the values in the live tree. no mismatching allowed, periodt πŸ‘‘

and one more thing: update of property in symbols node is not allowed. that's it. that's the rule. don't try it 🚫


⭐ RETURN ⭐

  • 0 on success β€” slay, we ate πŸ’…
  • -ENOMEM if memory allocation failure β€” the malloc said no 😭
  • -EINVAL if invalid overlay β€” the overlay was giving invalid vibes, red flag 🚩

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./drivers/of/overlay.c, plus the whole friend group:

that's the squad. go read them too, bestie, they're all icons in their own right πŸ‘‘


✨ and that's a wrap ✨ this page lives in ./drivers/of and it's dated October 2026 β€” don't forget to stan the kernel docs, fr fr πŸ“πŸ’œ

πŸ“¦ where this page comes from