diff --git a/drivers/core/device-remove.c b/drivers/core/device-remove.c
index efdb0f2..9953118 100644
--- a/drivers/core/device-remove.c
+++ b/drivers/core/device-remove.c
@@ -124,20 +124,20 @@
 {
 	int size;
 
-	if (dev->driver->priv_auto_alloc_size) {
+	if (dev->driver->priv_auto) {
 		free(dev->priv);
 		dev->priv = NULL;
 	}
-	size = dev->uclass->uc_drv->per_device_auto_alloc_size;
+	size = dev->uclass->uc_drv->per_device_auto;
 	if (size) {
 		free(dev->uclass_priv);
 		dev->uclass_priv = NULL;
 	}
 	if (dev->parent) {
-		size = dev->parent->driver->per_child_auto_alloc_size;
+		size = dev->parent->driver->per_child_auto;
 		if (!size) {
 			size = dev->parent->uclass->uc_drv->
-					per_child_auto_alloc_size;
+					per_child_auto;
 		}
 		if (size) {
 			free(dev->parent_priv);
diff --git a/drivers/core/device.c b/drivers/core/device.c
index 79afaf0..5df6112 100644
--- a/drivers/core/device.c
+++ b/drivers/core/device.c
@@ -96,21 +96,19 @@
 		}
 	}
 
-	if (drv->platdata_auto_alloc_size) {
+	if (drv->platdata_auto) {
 		bool alloc = !platdata;
 
 		if (CONFIG_IS_ENABLED(OF_PLATDATA)) {
 			if (of_platdata_size) {
 				dev->flags |= DM_FLAG_OF_PLATDATA;
-				if (of_platdata_size <
-						drv->platdata_auto_alloc_size)
+				if (of_platdata_size < drv->platdata_auto)
 					alloc = true;
 			}
 		}
 		if (alloc) {
 			dev->flags |= DM_FLAG_ALLOC_PDATA;
-			dev->platdata = calloc(1,
-					       drv->platdata_auto_alloc_size);
+			dev->platdata = calloc(1, drv->platdata_auto);
 			if (!dev->platdata) {
 				ret = -ENOMEM;
 				goto fail_alloc1;
@@ -122,7 +120,7 @@
 		}
 	}
 
-	size = uc->uc_drv->per_device_platdata_auto_alloc_size;
+	size = uc->uc_drv->per_device_platdata_auto;
 	if (size) {
 		dev->flags |= DM_FLAG_ALLOC_UCLASS_PDATA;
 		dev->uclass_platdata = calloc(1, size);
@@ -133,10 +131,9 @@
 	}
 
 	if (parent) {
-		size = parent->driver->per_child_platdata_auto_alloc_size;
+		size = parent->driver->per_child_platdata_auto;
 		if (!size) {
-			size = parent->uclass->uc_drv->
-					per_child_platdata_auto_alloc_size;
+			size = parent->uclass->uc_drv->per_child_platdata_auto;
 		}
 		if (size) {
 			dev->flags |= DM_FLAG_ALLOC_PARENT_PDATA;
@@ -363,15 +360,15 @@
 	assert(drv);
 
 	/* Allocate private data if requested and not reentered */
-	if (drv->priv_auto_alloc_size && !dev->priv) {
-		dev->priv = alloc_priv(drv->priv_auto_alloc_size, drv->flags);
+	if (drv->priv_auto && !dev->priv) {
+		dev->priv = alloc_priv(drv->priv_auto, drv->flags);
 		if (!dev->priv) {
 			ret = -ENOMEM;
 			goto fail;
 		}
 	}
 	/* Allocate private data if requested and not reentered */
-	size = dev->uclass->uc_drv->per_device_auto_alloc_size;
+	size = dev->uclass->uc_drv->per_device_auto;
 	if (size && !dev->uclass_priv) {
 		dev->uclass_priv = alloc_priv(size,
 					      dev->uclass->uc_drv->flags);
@@ -383,10 +380,9 @@
 
 	/* Allocate parent data for this child */
 	if (dev->parent) {
-		size = dev->parent->driver->per_child_auto_alloc_size;
+		size = dev->parent->driver->per_child_auto;
 		if (!size) {
-			size = dev->parent->uclass->uc_drv->
-					per_child_auto_alloc_size;
+			size = dev->parent->uclass->uc_drv->per_child_auto;
 		}
 		if (size && !dev->parent_priv) {
 			dev->parent_priv = alloc_priv(size, drv->flags);
diff --git a/drivers/core/simple-bus.c b/drivers/core/simple-bus.c
index 7cc1d46..c244b39 100644
--- a/drivers/core/simple-bus.c
+++ b/drivers/core/simple-bus.c
@@ -47,7 +47,7 @@
 	.id		= UCLASS_SIMPLE_BUS,
 	.name		= "simple_bus",
 	.post_bind	= simple_bus_post_bind,
-	.per_device_platdata_auto_alloc_size = sizeof(struct simple_bus_plat),
+	.per_device_platdata_auto	= sizeof(struct simple_bus_plat),
 };
 
 static const struct udevice_id generic_simple_bus_ids[] = {
diff --git a/drivers/core/simple-pm-bus.c b/drivers/core/simple-pm-bus.c
index 51dc9b2..7a18953 100644
--- a/drivers/core/simple-pm-bus.c
+++ b/drivers/core/simple-pm-bus.c
@@ -51,6 +51,6 @@
 	.of_match = simple_pm_bus_ids,
 	.probe = simple_pm_bus_probe,
 	.remove = simple_pm_bus_remove,
-	.priv_auto_alloc_size = sizeof(struct clk_bulk),
+	.priv_auto	= sizeof(struct clk_bulk),
 	.flags	= DM_FLAG_PRE_RELOC,
 };
diff --git a/drivers/core/syscon-uclass.c b/drivers/core/syscon-uclass.c
index 567d0a4..823d073 100644
--- a/drivers/core/syscon-uclass.c
+++ b/drivers/core/syscon-uclass.c
@@ -174,7 +174,7 @@
 UCLASS_DRIVER(syscon) = {
 	.id		= UCLASS_SYSCON,
 	.name		= "syscon",
-	.per_device_auto_alloc_size = sizeof(struct syscon_uc_info),
+	.per_device_auto	= sizeof(struct syscon_uc_info),
 	.pre_probe = syscon_pre_probe,
 };
 
diff --git a/drivers/core/uclass.c b/drivers/core/uclass.c
index c3f1b73..b1d882e 100644
--- a/drivers/core/uclass.c
+++ b/drivers/core/uclass.c
@@ -71,8 +71,8 @@
 	uc = calloc(1, sizeof(*uc));
 	if (!uc)
 		return -ENOMEM;
-	if (uc_drv->priv_auto_alloc_size) {
-		uc->priv = calloc(1, uc_drv->priv_auto_alloc_size);
+	if (uc_drv->priv_auto) {
+		uc->priv = calloc(1, uc_drv->priv_auto);
 		if (!uc->priv) {
 			ret = -ENOMEM;
 			goto fail_mem;
@@ -93,7 +93,7 @@
 
 	return 0;
 fail:
-	if (uc_drv->priv_auto_alloc_size) {
+	if (uc_drv->priv_auto) {
 		free(uc->priv);
 		uc->priv = NULL;
 	}
@@ -131,7 +131,7 @@
 	if (uc_drv->destroy)
 		uc_drv->destroy(uc);
 	list_del(&uc->sibling_node);
-	if (uc_drv->priv_auto_alloc_size)
+	if (uc_drv->priv_auto)
 		free(uc->priv);
 	free(uc);
 
