of_changeset..._prop_string(9)
π of_changeset_add_prop_string(9) π
okay so bestie, welcome to the Kernel API Manual β yes we're literally reading kernel docs together, this is our bonding era π«Ά
β¨ NAME β¨
of_changeset_add_prop_string β adds a string property to a changeset. that's it, that's the whole vibe π
π¦ SYNOPSIS π¦
int of_changeset_add_prop_string (struct of_changeset *ocs , struct
device_node *np , const char *prop_name , const char *str );
like, look at her. four params, one int coming back. main character energy fr π
πΈ ARGUMENTS πΈ
ocsβ the changeset pointer π this is the little container your changes go intonpβ the device node pointer, aka where this property is headedprop_nameβ the name of the property you're adding, pick something cute (or, yk, semantically correct)strβ a pointer to a null terminated string. null terminated!! don't forget the terminator, i'm begging π
π DESCRIPTION π
so the way this works is: you create a string property, and then you add it to a changeset. that's the entire thing. no cap. π¦
like it's giving "small but essential." iconic behaviour honestly.
β RETURN β
0on success β slay, we ate π β¨- a negative error value in case of an error β not slay, but at least it tells you π
ngl bestie, always check the return value. negative numbers are NOT the vibe and they are NOT success.
π SEE ALSO π
Kernel file ./drivers/of/dynamic.c β go read the source, i believe in you π§
and then the whole friend group:
of_node_get(9)of_node_put(9)of_attach_node(9)of_detach_node(9)of_node_release(9)__of_prop_dup(9)__of_node_dup(9)of_changeset_create_node(9)of_changeset_init(9)of_changeset_destroy(9)of_changeset_apply(9)of_changeset_revert(9)of_changeset_action(9)of_changeset_add_prop_string_array(9)of_changeset_add_prop_u32_array(9)of_changeset_add_prop_bool(9)of_changeset_update_prop_string(9)
π reminder that all of these are (9) β kernel API section, not section 1. iykyk.
okay bye bestie, go forth and add your strings πΈπ
this page came from ./drivers/of and it's dated October 2026 β that's the source and the date, mwah, love u, drink some water ππ§ββοΈβ¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms