public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [PATCH v2 0/2] dfu: sf: fix flash probe when DM_SPI_FLASH is enabled
@ 2024-10-01 16:06 Neil Armstrong
  2024-10-01 16:06 ` [PATCH v2 1/2] spi: add DM_SPI_FLASH compatibility inline functions Neil Armstrong
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Neil Armstrong @ 2024-10-01 16:06 UTC (permalink / raw)
  To: Lukasz Majewski, Mattijs Korpershoek, Tom Rini, Jagan Teki,
	Vignesh R
  Cc: u-boot, Neil Armstrong

With DM_SPI_FLASH is enabled, the code uses the legacy
SPI FLASH code leading to probable errors since it doesn't
use speed and mode provided by DT.

This adds the DM functions as dummy inline functions
to add both legacy and DM support in DFU sf code avoiding
using #if/#else conditionals.

Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
---
Changes in v2:
- switch to if(IS_ENABLED())
- add SPI FLASH DM functions as dummy inline functions
- Link to v1: https://lore.kernel.org/r/20240917-uboot-topic-dfu-sf-dt-v1-1-8cf38451eea4@linaro.org

---
Neil Armstrong (2):
      spi: add DM_SPI_FLASH compatibility inline functions
      dfu: sf: rely on DT for spi speed and mode

 drivers/dfu/dfu_sf.c | 16 +++++++++++++++-
 include/spi_flash.h  | 34 ++++++++++++++++++++++++++++++++++
 2 files changed, 49 insertions(+), 1 deletion(-)
---
base-commit: 19dbc09405d3503ce3efef3c2e4b4f0f1a03372d
change-id: 20240917-uboot-topic-dfu-sf-dt-8ae62e5c7d79

Best regards,
-- 
Neil Armstrong <neil.armstrong@linaro.org>


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

end of thread, other threads:[~2024-10-24  7:43 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-01 16:06 [PATCH v2 0/2] dfu: sf: fix flash probe when DM_SPI_FLASH is enabled Neil Armstrong
2024-10-01 16:06 ` [PATCH v2 1/2] spi: add DM_SPI_FLASH compatibility inline functions Neil Armstrong
2024-10-02  7:29   ` Mattijs Korpershoek
2024-10-10  8:09   ` Mattijs Korpershoek
2024-10-01 16:06 ` [PATCH v2 2/2] dfu: sf: rely on DT for spi speed and mode Neil Armstrong
2024-10-02  7:30   ` Mattijs Korpershoek
2024-10-24  7:43 ` [PATCH v2 0/2] dfu: sf: fix flash probe when DM_SPI_FLASH is enabled Mattijs Korpershoek

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