diff mbox series

[U-Boot,RFC,v2,04/15] efi_driver: rename UCLASS_EFI to UCLASS_EFI_DRIVER

Message ID 20190208081542.2813-5-takahiro.akashi@linaro.org
State RFC
Delegated to: Alexander Graf
Headers show
Series dm, efi: integrate efi objects into DM | expand

Commit Message

AKASHI Takahiro Feb. 8, 2019, 8:15 a.m. UTC
UCLASS_EFI will be reused later for efi root (EFI sub system itself).

Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
---
 include/dm/uclass-id.h            |  3 ++-
 lib/efi_driver/efi_block_device.c |  2 +-
 lib/efi_driver/efi_uclass.c       | 10 +++++-----
 3 files changed, 8 insertions(+), 7 deletions(-)
diff mbox series

Patch

diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h
index fb0ab40891c8..b4fca51a8192 100644
--- a/include/dm/uclass-id.h
+++ b/include/dm/uclass-id.h
@@ -39,7 +39,8 @@  enum uclass_id {
 	UCLASS_CROS_EC,		/* Chrome OS EC */
 	UCLASS_DISPLAY,		/* Display (e.g. DisplayPort, HDMI) */
 	UCLASS_DMA,		/* Direct Memory Access */
-	UCLASS_EFI,		/* EFI managed devices */
+	UCLASS_EFI,		/* EFI sub system */
+	UCLASS_EFI_DRIVER,	/* EFI managed drivers */
 	UCLASS_EFI_OBJECT,	/* EFI managed objects */
 	UCLASS_EFI_PROTOCOL,	/* EFI managed protocols */
 	UCLASS_ETH,		/* Ethernet device */
diff --git a/lib/efi_driver/efi_block_device.c b/lib/efi_driver/efi_block_device.c
index 3f147cf60879..e0d50c866f00 100644
--- a/lib/efi_driver/efi_block_device.c
+++ b/lib/efi_driver/efi_block_device.c
@@ -204,6 +204,6 @@  static const struct efi_driver_ops driver_ops = {
 /* Identify as EFI driver */
 U_BOOT_DRIVER(efi_block) = {
 	.name		= "EFI block driver",
-	.id		= UCLASS_EFI,
+	.id		= UCLASS_EFI_DRIVER,
 	.ops		= &driver_ops,
 };
diff --git a/lib/efi_driver/efi_uclass.c b/lib/efi_driver/efi_uclass.c
index bb86ffd399c3..d42612a5ee03 100644
--- a/lib/efi_driver/efi_uclass.c
+++ b/lib/efi_driver/efi_uclass.c
@@ -307,7 +307,7 @@  efi_status_t efi_driver_init(void)
 	debug("EFI: Initializing EFI driver framework\n");
 	for (drv = ll_entry_start(struct driver, driver);
 	     drv < ll_entry_end(struct driver, driver); ++drv) {
-		if (drv->id == UCLASS_EFI) {
+		if (drv->id == UCLASS_EFI_DRIVER) {
 			ret = efi_add_driver(drv);
 			if (ret != EFI_SUCCESS) {
 				printf("EFI: ERROR: failed to add driver %s\n",
@@ -327,7 +327,7 @@  efi_status_t efi_driver_init(void)
  */
 static int efi_uc_init(struct uclass *class)
 {
-	printf("EFI: Initializing UCLASS_EFI\n");
+	printf("EFI: Initializing UCLASS_EFI_DRIVER\n");
 	return 0;
 }
 
@@ -343,9 +343,9 @@  static int efi_uc_destroy(struct uclass *class)
 	return 0;
 }
 
-UCLASS_DRIVER(efi) = {
-	.name		= "efi",
-	.id		= UCLASS_EFI,
+UCLASS_DRIVER(efi_driver) = {
+	.name		= "efi_driver",
+	.id		= UCLASS_EFI_DRIVER,
 	.init		= efi_uc_init,
 	.destroy	= efi_uc_destroy,
 };