diff options
author | Simon Glass | 2022-03-04 08:43:03 -0700 |
---|---|---|
committer | Tom Rini | 2022-03-10 08:28:36 -0500 |
commit | 5b896ed5856f768cdd55cdeb44c5f8f6b6a7a18a (patch) | |
tree | 427918a7828619a8620cd9b95d547539c9eb6733 /include/event.h | |
parent | 5a4219043d659514316e41d3d09866030c773e78 (diff) |
event: Add events for device probe/remove
Generate events when devices are probed or removed, allowing hooks
to be added for these situations.
This is controlled by the DM_EVENT config option.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/event.h')
-rw-r--r-- | include/event.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/event.h b/include/event.h index effd58c7047..f4c12d768b4 100644 --- a/include/event.h +++ b/include/event.h @@ -19,6 +19,12 @@ enum event_t { EVT_NONE, EVT_TEST, + /* Events related to driver model */ + EVT_DM_PRE_PROBE, + EVT_DM_POST_PROBE, + EVT_DM_PRE_REMOVE, + EVT_DM_POST_REMOVE, + EVT_COUNT }; @@ -31,6 +37,15 @@ union event_data { struct event_data_test { int signal; } test; + + /** + * struct event_dm - driver model event + * + * @dev: Device this event relates to + */ + struct event_dm { + struct udevice *dev; + } dm; }; /** |