[PATCH v2] cmd: Add Kconfig option for multiprocessor cmds

Michal Simek michal.simek at xilinx.com
Mon Jan 17 10:16:50 CET 2022


From: Ashok Reddy Soma <ashok.reddy.soma at xilinx.com>

Add Kconfig option(CONFIG_CMD_MP) to enable or disable multiprocessor
commands. Compile cmd/mp.c based on CONFIG_CMD_MP.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma at xilinx.com>
Signed-off-by: Michal Simek <michal.simek at xilinx.com>
---

Changes in v2:
- Move config MP to Kconfig (General setup menu)
- Fix description and s/support/Support/ to be consistent with other
  entries which also start with upper letter.
- all reported by trini

 Kconfig      |  6 ++++++
 cmd/Kconfig  | 11 ++++++-----
 cmd/Makefile |  2 +-
 3 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/Kconfig b/Kconfig
index c46f4fce8625..b0e45cd236f0 100644
--- a/Kconfig
+++ b/Kconfig
@@ -454,6 +454,12 @@ config SYS_SRAM_SIZE
 	default 0x10000 if TARGET_TRICORDER
 	default 0x0
 
+config MP
+	bool "Support for multiprocessor"
+	help
+	  This provides an option to bringup different processors
+	  in multiprocessor cases.
+
 config EXAMPLES
 	bool "Compile API examples"
 	depends on !SANDBOX
diff --git a/cmd/Kconfig b/cmd/Kconfig
index 5b30b13e438f..5f2668a5b173 100644
--- a/cmd/Kconfig
+++ b/cmd/Kconfig
@@ -1820,12 +1820,13 @@ config CMD_SLEEP
 	help
 	  Delay execution for some time
 
-config MP
-	bool "support for multiprocessor"
+config CMD_MP
+	bool "support for multiprocessor commands"
+	depends on MP
+	default y
 	help
-	  This provides an option to brinup
-	  different processors in multiprocessor
-	  cases.
+	  This enables commands to bringup different processors
+	  in multiprocessor cases.
 
 config CMD_TIMER
 	bool "timer"
diff --git a/cmd/Makefile b/cmd/Makefile
index 891819ae0f6b..9e8074bb7e49 100644
--- a/cmd/Makefile
+++ b/cmd/Makefile
@@ -101,7 +101,7 @@ obj-$(CONFIG_CMD_MDIO) += mdio.o
 obj-$(CONFIG_CMD_SLEEP) += sleep.o
 obj-$(CONFIG_CMD_MMC) += mmc.o
 obj-$(CONFIG_CMD_OPTEE_RPMB) += optee_rpmb.o
-obj-$(CONFIG_MP) += mp.o
+obj-$(CONFIG_CMD_MP) += mp.o
 obj-$(CONFIG_CMD_MTD) += mtd.o
 obj-$(CONFIG_CMD_MTDPARTS) += mtdparts.o
 obj-$(CONFIG_CMD_CLONE) += clone.o
-- 
2.34.1



More information about the U-Boot mailing list