From: Lukasz Majewski <lukma@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v1 3/4] spi: Move DM_SPI_FLASH and SPI_FLASH_DATAFLASH to Kconfig (for ls1021aXXX)
Date: Mon, 12 Aug 2019 09:07:46 +0200 [thread overview]
Message-ID: <20190812070748.7315-4-lukma@denx.de> (raw)
In-Reply-To: <20190812070748.7315-1-lukma@denx.de>
This patch moves the CONFIG_DM_SPI_FLASH and CONFIG_SPI_FLASH_DATAFLASH
to be defined in Kconfig, not in board specific header file
(include/configs/<board>.h).
Before this change the CONFIG_DM_SPI_FLASH was not set in .config (so it
was not possible to use CONFIG_IS_ENABLED(DM_SPI_FLASH) in SPI DM/DTS
converted drivers), but it was set in u-boot.cfg file.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
---
arch/arm/Kconfig | 6 ++++--
include/configs/ls1021aiot.h | 6 ------
include/configs/ls1021aqds.h | 8 --------
include/configs/ls1021atwr.h | 5 -----
4 files changed, 4 insertions(+), 21 deletions(-)
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 656ac9c543..f10ca68511 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1341,6 +1341,8 @@ config TARGET_LS1021AQDS
select SUPPORT_SPL
select SYS_FSL_DDR
select FSL_DDR_INTERACTIVE
+ select DM_SPI_FLASH if FSL_DSPI || FSL_QSPI
+ select SPI_FLASH_DATAFLASH if FSL_DSPI || FSL_QSPI
imply SCSI
config TARGET_LS1021ATWR
@@ -1354,6 +1356,7 @@ config TARGET_LS1021ATWR
select CPU_V7_HAS_VIRT
select LS1_DEEP_SLEEP
select SUPPORT_SPL
+ select DM_SPI_FLASH if FSL_DSPI || FSL_QSPI
imply SCSI
config TARGET_LS1021ATSN
@@ -1378,6 +1381,7 @@ config TARGET_LS1021AIOT
select CPU_V7_HAS_NONSEC
select CPU_V7_HAS_VIRT
select SUPPORT_SPL
+ select DM_SPI_FLASH if FSL_DSPI || FSL_QSPI
imply SCSI
help
Support for Freescale LS1021AIOT platform.
@@ -1811,5 +1815,3 @@ config SPL_LDSCRIPT
default "arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds" if (ARCH_MX23 || ARCH_MX28) && !SPL_FRAMEWORK
default "arch/arm/cpu/arm1136/u-boot-spl.lds" if CPU_ARM1136
default "arch/arm/cpu/armv8/u-boot-spl.lds" if ARM64
-
-
diff --git a/include/configs/ls1021aiot.h b/include/configs/ls1021aiot.h
index ee570bc1a9..0ab1fb17a6 100644
--- a/include/configs/ls1021aiot.h
+++ b/include/configs/ls1021aiot.h
@@ -139,12 +139,6 @@
#define CONFIG_SPI_FLASH_SPANSION
#endif
-/* DM SPI */
-#if defined(CONFIG_FSL_DSPI) || defined(CONFIG_FSL_QSPI)
-#define CONFIG_CMD_SF
-#define CONFIG_DM_SPI_FLASH
-#endif
-
/*
* eTSEC
*/
diff --git a/include/configs/ls1021aqds.h b/include/configs/ls1021aqds.h
index 66771e279b..e2529dfb9c 100644
--- a/include/configs/ls1021aqds.h
+++ b/include/configs/ls1021aqds.h
@@ -363,14 +363,6 @@ unsigned long get_board_ddr_clk(void);
#define QSPI0_AMBA_BASE 0x40000000
#define FSL_QSPI_FLASH_SIZE (1 << 24)
#define FSL_QSPI_FLASH_NUM 2
-
-/* DSPI */
-
-/* DM SPI */
-#if defined(CONFIG_FSL_DSPI) || defined(CONFIG_FSL_QSPI)
-#define CONFIG_DM_SPI_FLASH
-#define CONFIG_SPI_FLASH_DATAFLASH
-#endif
#endif
/*
diff --git a/include/configs/ls1021atwr.h b/include/configs/ls1021atwr.h
index 31abee81ed..397afb668b 100644
--- a/include/configs/ls1021atwr.h
+++ b/include/configs/ls1021atwr.h
@@ -238,11 +238,6 @@
/* DSPI */
#endif
-/* DM SPI */
-#if defined(CONFIG_FSL_DSPI) || defined(CONFIG_FSL_QSPI)
-#define CONFIG_DM_SPI_FLASH
-#endif
-
/*
* Video
*/
--
2.11.0
next prev parent reply other threads:[~2019-08-12 7:07 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-12 7:07 [U-Boot] [PATCH v1 0/4] spi: Split CONFIG_DM_SPI* to CONFIG_{SPL_TPL}DM_SPI* Lukasz Majewski
2019-08-12 7:07 ` [U-Boot] [PATCH v1 1/4] kconfig: Update comment regarding CONFIG_IS_ENABLED(FOO) for TPL Lukasz Majewski
2019-08-12 7:07 ` [U-Boot] [PATCH v1 2/4] spi: Move DM_SPI_FLASH to Kconfig (for NXP's ls1043a) Lukasz Majewski
2019-08-12 7:07 ` Lukasz Majewski [this message]
2019-08-12 7:07 ` [U-Boot] [PATCH v1 4/4] spi: Convert CONFIG_DM_SPI* to CONFIG_$(SPL_TPL_)DM_SPI* Lukasz Majewski
2019-08-12 13:07 ` [U-Boot] [PATCH v1 0/4] spi: Split CONFIG_DM_SPI* to CONFIG_{SPL_TPL}DM_SPI* Adam Ford
2019-08-12 14:02 ` Lukasz Majewski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190812070748.7315-4-lukma@denx.de \
--to=lukma@denx.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox