All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/4] sunxi_nand_spl: Rename SPL_NAND_SUNXI to NAND_SUNXI
@ 2015-08-22 18:13 Hans de Goede
  2015-08-22 18:13 ` [U-Boot] [PATCH 2/4] sunxi_nand_spl: Remove NAND_SUNXI_SPL_SYNDROME_PARTITIONS_END Hans de Goede
                   ` (4 more replies)
  0 siblings, 5 replies; 18+ messages in thread
From: Hans de Goede @ 2015-08-22 18:13 UTC (permalink / raw)
  To: u-boot

We eventually want to add full nand support, since it makes no sense
to build SPL with nand support and u-boot without, or the other way
around, a single option will suffice.

Renaming the Kconfig option now makes things easier when we add full
nand support in the future.

The "obj-$(CONFIG_NAND_SUNXI) += sunxi_nand_spl.o" is moved to an
"ifdef CONFIG_SPL_BUILD" block in the Makefile.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 board/sunxi/board.c            |  2 +-
 drivers/mtd/nand/Kconfig       | 18 +++++++++---------
 drivers/mtd/nand/Makefile      |  2 +-
 include/configs/sunxi-common.h |  2 +-
 4 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/board/sunxi/board.c b/board/sunxi/board.c
index d411e96..9c855f6 100644
--- a/board/sunxi/board.c
+++ b/board/sunxi/board.c
@@ -108,7 +108,7 @@ int dram_init(void)
 	return 0;
 }
 
-#if defined(CONFIG_SPL_NAND_SUNXI) && defined(CONFIG_SPL_BUILD)
+#if defined(CONFIG_NAND_SUNXI) && defined(CONFIG_SPL_BUILD)
 static void nand_pinmux_setup(void)
 {
 	unsigned int pin;
diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig
index 5f456c9..c331f66 100644
--- a/drivers/mtd/nand/Kconfig
+++ b/drivers/mtd/nand/Kconfig
@@ -56,6 +56,14 @@ config SYS_NAND_VF610_NFC_60_ECC_BYTES
 
 endchoice
 
+config NAND_SUNXI
+	bool "Support for NAND on Allwinner SoCs in SPL"
+	depends on MACH_SUN4I || MACH_SUN5I || MACH_SUN7I
+	select SYS_NAND_SELF_INIT
+	---help---
+	Enable support for NAND. This option allows SPL to read from
+	sunxi NAND using DMA transfers.
+
 comment "Generic NAND options"
 
 # Enhance depends when converting drivers to Kconfig which use this config
@@ -85,18 +93,10 @@ config SPL_NAND_DENALI
 	  This is a small implementation of the Denali NAND controller
 	  for use on SPL.
 
-config SPL_NAND_SUNXI
-	bool "Support for NAND on Allwinner SoCs in SPL"
-	depends on MACH_SUN4I || MACH_SUN5I || MACH_SUN7I
-	select SYS_NAND_SELF_INIT
-	---help---
-	Enable support for NAND. This option allows SPL to read from
-	sunxi NAND using DMA transfers.
-
 config NAND_SUNXI_SPL_SYNDROME_PARTITIONS_END
 	hex "Size of syndrome partitions in sunxi NAND"
 	default 0x400000
-	depends on SPL_NAND_SUNXI
+	depends on NAND_SUNXI
 	---help---
 	End address for boot partitions on NAND. Those partitions have a
 	different random seed that has to match the sunxi BROM setting.
diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile
index 46dce72..c3bd0f7 100644
--- a/drivers/mtd/nand/Makefile
+++ b/drivers/mtd/nand/Makefile
@@ -12,7 +12,6 @@ NORMAL_DRIVERS=y
 endif
 
 obj-$(CONFIG_SPL_NAND_AM33XX_BCH) += am335x_spl_bch.o
-obj-$(CONFIG_SPL_NAND_SUNXI) += sunxi_nand_spl.o
 obj-$(CONFIG_SPL_NAND_DENALI) += denali_spl.o
 obj-$(CONFIG_SPL_NAND_DOCG4) += docg4_spl.o
 obj-$(CONFIG_SPL_NAND_SIMPLE) += nand_spl_simple.o
@@ -75,5 +74,6 @@ obj-$(CONFIG_NAND_FSL_ELBC) += fsl_elbc_spl.o
 obj-$(CONFIG_NAND_FSL_IFC) += fsl_ifc_spl.o
 obj-$(CONFIG_NAND_MXC) += mxc_nand_spl.o
 obj-$(CONFIG_NAND_MXS) += mxs_nand_spl.o mxs_nand.o
+obj-$(CONFIG_NAND_SUNXI) += sunxi_nand_spl.o
 
 endif # drivers
diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
index 3735afb..519c99c 100644
--- a/include/configs/sunxi-common.h
+++ b/include/configs/sunxi-common.h
@@ -137,7 +137,7 @@
 #define CONFIG_INITRD_TAG
 #define CONFIG_SERIAL_TAG
 
-#if defined(CONFIG_SPL_NAND_SUNXI)
+#ifdef CONFIG_NAND_SUNXI
 #define CONFIG_SPL_NAND_SUPPORT 1
 #define CONFIG_SYS_NAND_U_BOOT_OFFS 0x008000
 #endif
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2015-09-26 13:01 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-22 18:13 [U-Boot] [PATCH 1/4] sunxi_nand_spl: Rename SPL_NAND_SUNXI to NAND_SUNXI Hans de Goede
2015-08-22 18:13 ` [U-Boot] [PATCH 2/4] sunxi_nand_spl: Remove NAND_SUNXI_SPL_SYNDROME_PARTITIONS_END Hans de Goede
2015-08-24 17:02   ` Scott Wood
2015-08-25  7:18     ` Hans de Goede
2015-08-26 18:37       ` Ian Campbell
2015-08-22 18:13 ` [U-Boot] [PATCH 3/4] mtd: nand: Make CONFIG_SYS_NAND_U_BOOT_OFFS configurable through Kconfig Hans de Goede
2015-08-26 18:38   ` Ian Campbell
2015-08-26 19:08     ` Scott Wood
2015-08-27 18:04       ` Hans de Goede
2015-08-22 18:13 ` [U-Boot] [PATCH 4/4] sunxi: Add inet97fv2_defconfig Hans de Goede
2015-08-26 18:39   ` Ian Campbell
2015-08-27  8:11     ` Hans de Goede
2015-08-27 20:18       ` Ian Campbell
2015-08-26 18:35 ` [U-Boot] [PATCH 1/4] sunxi_nand_spl: Rename SPL_NAND_SUNXI to NAND_SUNXI Ian Campbell
2015-09-18 11:43 ` [U-Boot] [PATCH 1/4] sunxi_nand_spl: Rename SPL_NAND_SUNXIto NAND_SUNXI Olliver Schinagl
2015-09-18 11:51   ` Olliver Schinagl
2015-09-20 13:09   ` Hans de Goede
2015-09-26 13:01     ` Olliver Schinagl

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.