From 0269dfae0e9f0303e3f0044e90a1ba476e8328f2 Mon Sep 17 00:00:00 2001 From: Maxime Ripard Date: Mon, 27 Feb 2017 18:22:04 +0100 Subject: cmd: Add Kconfig option for CMD_MTDPARTS and related options CMD_MTDPARTS is something the user might or might not want to select, and might depends on (or be selected by) other options too. This is even truer for the MTDIDS_DEFAULT and MTDPARTS_DEFAULT options that might change from one board to another, or from one user to the other, depending on what it expects and what storage devices are available. In order to ease that configuration, add those options to Kconfig. Signed-off-by: Maxime Ripard Reviewed-by: Tom Rini Reviewed-by: Jagan Teki --- cmd/mtdparts.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'cmd/mtdparts.c') diff --git a/cmd/mtdparts.c b/cmd/mtdparts.c index b9b160dc1e2..112bf1f3e3c 100644 --- a/cmd/mtdparts.c +++ b/cmd/mtdparts.c @@ -110,11 +110,19 @@ DECLARE_GLOBAL_DATA_PTR; /* default values for mtdids and mtdparts variables */ #if !defined(MTDIDS_DEFAULT) +#ifdef CONFIG_MTDIDS_DEFAULT +#define MTDIDS_DEFAULT CONFIG_MTDIDS_DEFAULT +#else #define MTDIDS_DEFAULT NULL #endif +#endif #if !defined(MTDPARTS_DEFAULT) +#ifdef CONFIG_MTDPARTS_DEFAULT +#define MTDPARTS_DEFAULT CONFIG_MTDPARTS_DEFAULT +#else #define MTDPARTS_DEFAULT NULL #endif +#endif #if defined(CONFIG_SYS_MTDPARTS_RUNTIME) extern void board_mtdparts_default(const char **mtdids, const char **mtdparts); #endif -- cgit