Lines Matching full:overlay

9 #define pr_fmt(fmt)	"OF: overlay: " fmt
27 * struct target - info about current target node as recursing through overlay
28 * @np: node where current level of overlay will be applied
32 * an overlay fragment, which is a devicetree subtree. Initially @np is a node
33 * in the live devicetree where the overlay subtree is targeted to be grafted
34 * into. When recursing to the next level of the overlay subtree, the target
35 * also recurses to the next level of the live devicetree, as long as overlay
36 * subtree node also exists in the live devicetree. When a node in the overlay
47 * struct fragment - info about fragment nodes in overlay expanded device tree
48 * @overlay: pointer to the __overlay__ node
49 * @target: target of the overlay operation
52 struct device_node *overlay; member
63 * @notify_state: most recent notify action used on overlay
65 * @fragments: fragment nodes in the overlay expanded device tree
134 * of_overlay_notifier_register() - Register notifier for overlay operations
137 * Register for notification on overlay operations on device tree nodes. The
152 * of_overlay_notifier_unregister() - Unregister notifier for overlay operations
173 nd.overlay = fragment->overlay; in overlay_notify()
179 pr_err("overlay changeset %s notifier error %d, target: %pOF\n", in overlay_notify()
233 if (fragment->overlay == overlay_node) in dup_and_fixup_symbol_prop()
239 overlay_name_len = snprintf(NULL, 0, "%pOF", fragment->overlay); in dup_and_fixup_symbol_prop()
279 * add_changeset_property() - add @overlay_prop to overlay changeset
280 * @ovcs: overlay changeset
282 * @overlay_prop: property to add or update, from overlay tree
297 * in the overlay must match the values in the live tree.
302 * invalid @overlay.
364 pr_err("WARNING: memory leak will occur if overlay removed, property: %pOF/%s\n", in add_changeset_property()
373 * add_changeset_node() - add @node (and children) to overlay changeset
374 * @ovcs: overlay changeset
376 * @node: node from within overlay device tree fragment
382 * a phandle, the overlay node is not allowed to have a phandle.
388 * not contain the full path in node->full_name. Thus an overlay
394 * the full path in node->full_name. Even though it expects the overlay
397 * to nodes in the live devicetree so that it can apply an overlay to
403 * invalid @overlay.
463 * build_changeset_next_level() - add level of overlay changeset
464 * @ovcs: overlay changeset
466 * @overlay_node: node from within an overlay device tree fragment
597 * @ovcs: Overlay changeset
619 * build_changeset() - populate overlay changeset in @ovcs from @ovcs->fragments
620 * @ovcs: Overlay changeset
623 * overlay device tree fragments in @ovcs->fragments[]. If an error occurs,
628 * invalid overlay in @ovcs->fragments[].
651 fragment->overlay); in build_changeset()
665 fragment->overlay); in build_changeset()
729 * init_overlay_changeset() - initialize overlay changeset from overlay tree
730 * @ovcs: Overlay changeset to build
731 * @target_base: Point to the target node to apply overlay
801 fragment->overlay = overlay_node; in init_overlay_changeset()
804 of_node_put(fragment->overlay); in init_overlay_changeset()
821 fragment->overlay = node; in init_overlay_changeset()
825 pr_err("symbols in overlay, but not in live tree\n"); in init_overlay_changeset()
835 pr_err("no fragments or symbols in overlay\n"); in init_overlay_changeset()
866 of_node_put(ovcs->fragments[i].overlay); in free_overlay_changeset()
872 * ovcs->new_fdt due to the policy that overlay notifiers are not in free_overlay_changeset()
873 * allowed to retain pointers into the overlay devicetree other in free_overlay_changeset()
874 * than during the window from OF_OVERLAY_PRE_APPLY overlay in free_overlay_changeset()
875 * notifiers until the OF_OVERLAY_POST_REMOVE overlay notifiers. in free_overlay_changeset()
891 * of_overlay_apply() - Create and apply an overlay changeset
892 * @ovcs: overlay changeset
893 * @base: point to the target node to apply overlay
895 * Creates and applies an overlay changeset.
897 * If an error is returned by an overlay changeset pre-apply notifier
898 * then no further overlay changeset pre-apply notifier will be called.
900 * If an error is returned by an overlay changeset post-apply notifier
901 * then no further overlay changeset post-apply notifier will be called.
906 * If an error occurred while applying the overlay changeset, then an
910 * following attempt to apply or remove an overlay changeset will be
942 pr_debug("overlay changeset revert error %d\n", in of_overlay_apply()
951 pr_err("overlay apply changeset entry notify error %d\n", ret); in of_overlay_apply()
966 * of_overlay_fdt_apply() - Create and apply an overlay changeset
967 * @overlay_fdt: pointer to overlay FDT
970 * @base: pointer for the target node to apply overlay
972 * Creates and applies an overlay changeset.
977 * the value of overlay changeset id, which can be passed to of_overlay_remove()
978 * to remove the overlay.
998 pr_err("devicetree state suspect, refuse to apply overlay\n"); in of_overlay_fdt_apply()
1097 * node in an overlay changeset more topmost than @remove_ovcs?
1131 * We can safely remove the overlay only if it's the top-most one.
1132 * Newly applied overlays are inserted at the tail of the overlay list,
1133 * so a top most overlay is the one that is closest to the tail.
1136 * affected device node in the log list we check if this overlay is
1137 * the one closest to the tail. If another overlay has affected this
1146 pr_err("overlay #%d is not topmost\n", remove_ovcs->id); in overlay_removal_is_ok()
1155 * of_overlay_remove() - Revert and free an overlay changeset
1156 * @ovcs_id: Pointer to overlay changeset id
1158 * Removes an overlay if it is permissible. @ovcs_id was previously returned
1161 * If an error occurred while attempting to revert the overlay changeset,
1165 * an overlay changeset will be refused.
1169 * - overlay changeset pre-remove notifier
1170 * - overlay changeset entry revert
1172 * If an error is returned by an overlay changeset pre-remove notifier
1173 * then no further overlay changeset pre-remove notifier will be called.
1179 * - overlay changeset entry notifier
1180 * - overlay changeset post-remove notifier
1182 * If an error is returned by an overlay changeset post-remove notifier
1183 * then no further overlay changeset post-remove notifier will be called.
1194 pr_err("suspect devicetree state, refuse to remove overlay\n"); in of_overlay_remove()
1204 pr_err("remove: Could not find overlay #%d\n", *ovcs_id); in of_overlay_remove()
1227 pr_err("overlay remove changeset entry notify error %d\n", ret); in of_overlay_remove()
1233 * Note that the overlay memory will be kfree()ed by in of_overlay_remove()
1247 * overlay related memory. This is a memory leak unless a subsequent in of_overlay_remove()
1248 * of_overlay_remove() of this overlay is successful. in of_overlay_remove()
1260 * of_overlay_remove_all() - Reverts and frees all overlay changesets