public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [RFC][PATCH] mtd: spi: Set CONFIG_SF_DEFAULT_MODE default to 0
@ 2021-09-14 18:28 Marek Vasut
  2021-09-14 19:19 ` Tom Rini
  2021-09-28 18:45 ` Tom Rini
  0 siblings, 2 replies; 9+ messages in thread
From: Marek Vasut @ 2021-09-14 18:28 UTC (permalink / raw)
  To: u-boot
  Cc: Marek Vasut, Aleksandar Gerasimovski, Andreas Biessmann,
	Eugen Hristev, Michal Simek, Patrice Chotard, Patrick Delaunay,
	Peng Fan, Siew Chin Lim, Tom Rini, Valentin Longchamp,
	Vignesh Raghavendra

Before e2e95e5e254 ("spi: Update speed/mode on change") most systems
silently defaulted to SF bus mode 0. Now the mode is always updated,
which causes breakage. It seems most SF which are used as boot media
operate in bus mode 0, so switch that as the default.

This should fix booting at least on Altera SoCFPGA, ST STM32, Xilinx
ZynqMP, NXP iMX and Rockchip SoCs, which recently ran into trouble
with mode 3. Marvell Kirkwood and Xilinx microblaze need to be checked
as those might need mode 3.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Aleksandar Gerasimovski <aleksandar.gerasimovski@hitachi-powergrids.com>
Cc: Andreas Biessmann <andreas@biessmann.org>
Cc: Eugen Hristev <eugen.hristev@microchip.com>
Cc: Michal Simek <michal.simek@xilinx.com>
Cc: Patrice Chotard <patrice.chotard@foss.st.com>
Cc: Patrick Delaunay <patrick.delaunay@foss.st.com>
Cc: Peng Fan <peng.fan@nxp.com>
Cc: Siew Chin Lim <elly.siew.chin.lim@intel.com>
Cc: Tom Rini <trini@konsulko.com>
Cc: Valentin Longchamp <valentin.longchamp@hitachi-powergrids.com>
Cc: Vignesh Raghavendra <vigneshr@ti.com>
---
 drivers/mtd/spi/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/spi/Kconfig b/drivers/mtd/spi/Kconfig
index b2291f72905..f03fe05e333 100644
--- a/drivers/mtd/spi/Kconfig
+++ b/drivers/mtd/spi/Kconfig
@@ -57,7 +57,7 @@ config SF_DEFAULT_CS
 config SF_DEFAULT_MODE
 	hex "SPI Flash default mode (see include/spi.h)"
 	depends on SPI_FLASH || DM_SPI_FLASH
-	default 3
+	default 0
 	help
 	  The default mode may be provided by the platform
 	  to handle the common case when only a single serial
-- 
2.33.0


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

end of thread, other threads:[~2021-09-28 18:45 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-09-14 18:28 [RFC][PATCH] mtd: spi: Set CONFIG_SF_DEFAULT_MODE default to 0 Marek Vasut
2021-09-14 19:19 ` Tom Rini
2021-09-14 20:10   ` Marek Vasut
2021-09-14 20:45     ` Tom Rini
2021-09-14 21:30       ` Marek Vasut
2021-09-14 21:44         ` Tom Rini
2021-09-15 17:55           ` Tom Rini
2021-09-15 18:52             ` Marek Vasut
2021-09-28 18:45 ` Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox