mtd: spi-nor: Use CONFIG_IS_ENABLED for CONFIG_SPI_FLASH_BAR defines
authorBernhard Messerklinger <bernhard.messerklinger@br-automation.com>
Fri, 4 Apr 2025 09:56:07 +0000 (11:56 +0200)
committerTom Rini <trini@konsulko.com>
Tue, 29 Apr 2025 21:27:07 +0000 (15:27 -0600)
commit37ccf4a949c4b8b24ed45495a0960695ddb3f7a7
treea0a4afbba3c49b6d5e1e34e4056fa3683a1a169e
parent299371dc8ea1e777b12a1e7c95fc8f9c1d9542ee
mtd: spi-nor: Use CONFIG_IS_ENABLED for CONFIG_SPI_FLASH_BAR defines

At the moment a mixture of ifdef(CONFIG_IS_ENABLED) and
CONFIG_IS_ENABLED(SPI_FLASH_BAR) is used in the spi-nor framework.
This leads to misbehaviour in the SPL as there is no Kconfig option
CONFIG_SPL_SPI_FLASH_BAR. This commit standardizes the use of
CONFIG_SPI_FLASH to get SPLs that load U-Boot proper from the
SPI flash to work again.

Fixes: 9bb02f7 (mtd: spi-nor: Fix the spi_nor_read() when config SPI_STACKED_PARALLEL is enabled)
Signed-off-by: Bernhard Messerklinger <bernhard.messerklinger@br-automation.com>
drivers/mtd/spi/spi-nor-core.c
include/linux/mtd/spi-nor.h