summaryrefslogtreecommitdiff
path: root/include/dm/device.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-12-04 02:55:17 +0300
committerSimon Glass <sjg@chromium.org>2020-12-13 18:00:25 +0300
commit41575d8e4c334df148c4cdd7c40cc825dc0fcaa1 (patch)
treec27d9450fb5e72372be8483fc15079467b588169 /include/dm/device.h
parent78128d52dfca9fff53770c7aed2e4673070c5978 (diff)
downloadu-boot-41575d8e4c334df148c4cdd7c40cc825dc0fcaa1.tar.xz
dm: treewide: Rename auto_alloc_size members to be shorter
This construct is quite long-winded. In earlier days it made some sense since auto-allocation was a strange concept. But with driver model now used pretty universally, we can shorten this to 'auto'. This reduces verbosity and makes it easier to read. Coincidentally it also ensures that every declaration is on one line, thus making dtoc's job easier. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/dm/device.h')
-rw-r--r--include/dm/device.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/include/dm/device.h b/include/dm/device.h
index 25a77d08b9..f4c2b9b246 100644
--- a/include/dm/device.h
+++ b/include/dm/device.h
@@ -111,7 +111,7 @@ enum {
* probe method if the device has a device tree node.
*
* All three of platdata, priv and uclass_priv can be allocated by the
- * driver, or you can use the auto_alloc_size members of struct driver and
+ * driver, or you can use the 'auto' members of struct driver and
* struct uclass_driver to have driver model do this automatically.
*
* @driver: The driver used by this device
@@ -225,18 +225,18 @@ struct udevice_id {
* memory allocated but it has not yet been probed.
* @child_post_remove: Called after a child device is removed. The device
* has memory allocated but its device_remove() method has been called.
- * @priv_auto_alloc_size: If non-zero this is the size of the private data
+ * @priv_auto: If non-zero this is the size of the private data
* to be allocated in the device's ->priv pointer. If zero, then the driver
* is responsible for allocating any data required.
- * @platdata_auto_alloc_size: If non-zero this is the size of the
+ * @platdata_auto: If non-zero this is the size of the
* platform data to be allocated in the device's ->platdata pointer.
* This is typically only useful for device-tree-aware drivers (those with
* an of_match), since drivers which use platdata will have the data
* provided in the U_BOOT_DEVICE() instantiation.
- * @per_child_auto_alloc_size: Each device can hold private data owned by
+ * @per_child_auto: Each device can hold private data owned by
* its parent. If required this will be automatically allocated if this
* value is non-zero.
- * @per_child_platdata_auto_alloc_size: A bus likes to store information about
+ * @per_child_platdata_auto: A bus likes to store information about
* its children. If non-zero this is the size of this data, to be allocated
* in the child's parent_platdata pointer.
* @ops: Driver-specific operations. This is typically a list of function
@@ -258,10 +258,10 @@ struct driver {
int (*child_post_bind)(struct udevice *dev);
int (*child_pre_probe)(struct udevice *dev);
int (*child_post_remove)(struct udevice *dev);
- int priv_auto_alloc_size;
- int platdata_auto_alloc_size;
- int per_child_auto_alloc_size;
- int per_child_platdata_auto_alloc_size;
+ int priv_auto;
+ int platdata_auto;
+ int per_child_auto;
+ int per_child_platdata_auto;
const void *ops; /* driver-specific operations */
uint32_t flags;
#if CONFIG_IS_ENABLED(ACPIGEN)