summaryrefslogtreecommitdiff
path: root/include/dm/uclass-internal.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2015-01-25 08:27:10 -0700
committerSimon Glass <sjg@chromium.org>2015-01-29 17:09:56 -0700
commit83c7e434c9dd3ca81f8b763e23c1881b973bcf2f (patch)
treec0fc096ee51bbcd66ccabd77826e236f49329845 /include/dm/uclass-internal.h
parent1603bf3cc189da65362b83b85831e094a2fe8516 (diff)
downloadu-boot-imx-83c7e434c9dd3ca81f8b763e23c1881b973bcf2f.zip
u-boot-imx-83c7e434c9dd3ca81f8b763e23c1881b973bcf2f.tar.gz
u-boot-imx-83c7e434c9dd3ca81f8b763e23c1881b973bcf2f.tar.bz2
dm: core: Allow uclass to set up a device's child before it is probed
Some buses need to set up their devices before they can be used. This setup may well be common to all buses in a particular uclass. Support a common pre-probe method for the uclass, called before any bus devices are probed. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Diffstat (limited to 'include/dm/uclass-internal.h')
-rw-r--r--include/dm/uclass-internal.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/dm/uclass-internal.h b/include/dm/uclass-internal.h
index f718f37..f2f254a 100644
--- a/include/dm/uclass-internal.h
+++ b/include/dm/uclass-internal.h
@@ -44,6 +44,17 @@ int uclass_bind_device(struct udevice *dev);
int uclass_unbind_device(struct udevice *dev);
/**
+ * uclass_pre_probe_child() - Deal with a child that is about to be probed
+ *
+ * Perform any pre-processing that is needed by the uclass before it can be
+ * probed.
+ *
+ * @dev: Pointer to the device
+ * #return 0 on success, -ve on error
+ */
+int uclass_pre_probe_child(struct udevice *dev);
+
+/**
* uclass_post_probe_device() - Deal with a device that has just been probed
*
* Perform any post-processing of a probed device that is needed by the