summaryrefslogtreecommitdiff
path: root/include/dm
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2022-10-29 18:51:22 -0400
committerTom Rini <trini@konsulko.com>2022-10-29 18:51:22 -0400
commit6f02819cceb19c334f1dbd6eccefb4ccfae319f9 (patch)
treeada26fe279934fbb18d69324010b3ce1f55ffb63 /include/dm
parentfb63362c63c7aeacb1dfde330ee8f692da7972f9 (diff)
parentf21954750aa8ed445ab83998bb099e366136c428 (diff)
Merge tag 'dm-pull-29oct22' of https://source.denx.de/u-boot/custodians/u-boot-dm
Fix pylibfdt warnings and use setuptools to build Various minor changes to core dm and sandbox
Diffstat (limited to 'include/dm')
-rw-r--r--include/dm/device-internal.h4
-rw-r--r--include/dm/lists.h2
-rw-r--r--include/dm/uclass.h25
3 files changed, 18 insertions, 13 deletions
diff --git a/include/dm/device-internal.h b/include/dm/device-internal.h
index 94844d30d85..f31c4702086 100644
--- a/include/dm/device-internal.h
+++ b/include/dm/device-internal.h
@@ -184,8 +184,8 @@ int device_of_to_plat(struct udevice *dev);
/**
* device_probe() - Probe a device, activating it
*
- * Activate a device so that it is ready for use. All its parents are probed
- * first.
+ * Activate a device (if not yet activated) so that it is ready for use.
+ * All its parents are probed first.
*
* @dev: Pointer to device to probe
* Return: 0 if OK, -ve on error
diff --git a/include/dm/lists.h b/include/dm/lists.h
index fc3b4ae5850..97236f8fa0d 100644
--- a/include/dm/lists.h
+++ b/include/dm/lists.h
@@ -73,6 +73,7 @@ int lists_bind_fdt(struct udevice *parent, ofnode node, struct udevice **devp,
* @drv_name: Name of driver to attach to this parent
* @dev_name: Name of the new device thus created
* @devp: If non-NULL, returns the newly bound device
+ * Return: 0 if OK, -ve on error
*/
int device_bind_driver(struct udevice *parent, const char *drv_name,
const char *dev_name, struct udevice **devp);
@@ -88,6 +89,7 @@ int device_bind_driver(struct udevice *parent, const char *drv_name,
* @dev_name: Name of the new device thus created
* @node: Device tree node
* @devp: If non-NULL, returns the newly bound device
+ * Return: 0 if OK, -ve on error
*/
int device_bind_driver_to_node(struct udevice *parent, const char *drv_name,
const char *dev_name, ofnode node,
diff --git a/include/dm/uclass.h b/include/dm/uclass.h
index 823a16527f7..ee15c920633 100644
--- a/include/dm/uclass.h
+++ b/include/dm/uclass.h
@@ -320,37 +320,37 @@ int uclass_get_device_by_driver(enum uclass_id id, const struct driver *drv,
* uclass_first_device() - Get the first device in a uclass
*
* The device returned is probed if necessary, and ready for use
+ * Devices that fail to probe are skipped
*
* This function is useful to start iterating through a list of devices which
* are functioning correctly and can be probed.
*
* @id: Uclass ID to look up
* @devp: Returns pointer to the first device in that uclass if no error
- * occurred, or NULL if there is no first device, or an error occurred with
- * that device.
- * Return: 0 if OK (found or not found), other -ve on error
+ * occurred, or NULL if there is no usable device
*/
-int uclass_first_device(enum uclass_id id, struct udevice **devp);
+void uclass_first_device(enum uclass_id id, struct udevice **devp);
/**
* uclass_next_device() - Get the next device in a uclass
*
* The device returned is probed if necessary, and ready for use
+ * Devices that fail to probe are skipped
*
* This function is useful to iterate through a list of devices which
* are functioning correctly and can be probed.
*
* @devp: On entry, pointer to device to lookup. On exit, returns pointer
* to the next device in the uclass if no error occurred, or NULL if there is
- * no next device, or an error occurred with that next device.
- * Return: 0 if OK (found or not found), other -ve on error
+ * no next device
*/
-int uclass_next_device(struct udevice **devp);
+void uclass_next_device(struct udevice **devp);
/**
* uclass_first_device_err() - Get the first device in a uclass
*
- * The device returned is probed if necessary, and ready for use
+ * The device returned is probed if necessary, and ready for use if no error is
+ * returned
*
* @id: Uclass ID to look up
* @devp: Returns pointer to the first device in that uclass, or NULL if none
@@ -361,7 +361,8 @@ int uclass_first_device_err(enum uclass_id id, struct udevice **devp);
/**
* uclass_next_device_err() - Get the next device in a uclass
*
- * The device returned is probed if necessary, and ready for use
+ * The device returned is probed if necessary, and ready for use if no error is
+ * returned
*
* @devp: On entry, pointer to device to lookup. On exit, returns pointer
* to the next device in the uclass if no error occurred, or NULL if
@@ -373,7 +374,8 @@ int uclass_next_device_err(struct udevice **devp);
/**
* uclass_first_device_check() - Get the first device in a uclass
*
- * The device returned is probed if necessary, and ready for use
+ * The device returned is probed if necessary, and ready for use if no error is
+ * returned
*
* This function is useful to start iterating through a list of devices which
* are functioning correctly and can be probed.
@@ -389,7 +391,8 @@ int uclass_first_device_check(enum uclass_id id, struct udevice **devp);
/**
* uclass_next_device_check() - Get the next device in a uclass
*
- * The device returned is probed if necessary, and ready for use
+ * The device returned is probed if necessary, and ready for use if no error is
+ * returned
*
* This function is useful to start iterating through a list of devices which
* are functioning correctly and can be probed.