diff options
author | Simon Glass <sjg@chromium.org> | 2022-07-30 15:52:31 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-08-12 08:17:11 -0400 |
commit | 98887ab802e4118e7c813e5e052678772fa1b3a8 (patch) | |
tree | d44b4041a2d15e73977641e508700770330076e1 /include | |
parent | 569524741a01e1a96fc2b75dd7e5d12e41ce6c2b (diff) | |
download | u-boot-98887ab802e4118e7c813e5e052678772fa1b3a8.tar.gz u-boot-98887ab802e4118e7c813e5e052678772fa1b3a8.tar.bz2 u-boot-98887ab802e4118e7c813e5e052678772fa1b3a8.zip |
event: Add an event for device tree fixups
At present there is a confusing array of functions that handle the
device tree fix-ups needed for booting an OS. We should be able to switch
to using events to clean this up.
As a first step, create a new event type and call it from the standard
place.
Note that this event uses the ofnode interface only, since this can
support live tree which is more efficient when making lots of updates.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/event.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/event.h b/include/event.h index fb0734ed4e..e8f2f55c63 100644 --- a/include/event.h +++ b/include/event.h @@ -10,6 +10,8 @@ #ifndef __event_h #define __event_h +#include <dm/ofnode_decl.h> + /** * enum event_t - Types of events supported by U-Boot * @@ -29,6 +31,9 @@ enum event_t { /* Init hooks */ EVT_MISC_INIT_F, + /* Device tree fixups before booting */ + EVT_FT_FIXUP, + EVT_COUNT }; @@ -50,6 +55,15 @@ union event_data { struct event_dm { struct udevice *dev; } dm; + + /** + * struct event_ft_fixup - FDT fixup before booting + * + * @tree: tree to update + */ + struct event_ft_fixup { + oftree tree; + } ft_fixup; }; /** |