diff options
author | Bin Meng <bmeng.cn@gmail.com> | 2018-10-15 02:20:57 -0700 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2018-11-14 09:16:27 -0800 |
commit | 651d0c019a428ca8b14352210c1ce7804dd51fae (patch) | |
tree | 899f50340f961295b0b7e4cfac051e9d823d20d4 /include/dm | |
parent | a6d4b0608b79023c703ca2ad1cbdfa784160449b (diff) | |
download | u-boot-651d0c019a428ca8b14352210c1ce7804dd51fae.tar.gz |
dm: core: Allow uclass to set up a device's child after it is probed
Some buses need to set up their child devices after they are probed.
Support a common child_post_probe() method for the uclass.
With this change, the two APIs uclass_pre_probe_device() and
uclass_post_probe_device() become symmetric.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/dm')
-rw-r--r-- | include/dm/uclass.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/dm/uclass.h b/include/dm/uclass.h index eebf2d5614..4ef0d0f0c0 100644 --- a/include/dm/uclass.h +++ b/include/dm/uclass.h @@ -61,7 +61,8 @@ struct udevice; * @post_probe: Called after a new device is probed * @pre_remove: Called before a device is removed * @child_post_bind: Called after a child is bound to a device in this uclass - * @child_pre_probe: Called before a child is probed in this uclass + * @child_pre_probe: Called before a child in this uclass is probed + * @child_post_probe: Called after a child in this uclass is probed * @init: Called to set up the uclass * @destroy: Called to destroy the uclass * @priv_auto_alloc_size: If non-zero this is the size of the private data @@ -94,6 +95,7 @@ struct uclass_driver { int (*pre_remove)(struct udevice *dev); int (*child_post_bind)(struct udevice *dev); int (*child_pre_probe)(struct udevice *dev); + int (*child_post_probe)(struct udevice *dev); int (*init)(struct uclass *class); int (*destroy)(struct uclass *class); int priv_auto_alloc_size; |