u-boot/drivers/mmc
Ovidiu Panait 741280e9ac spi: spi-uclass: Fix spi_claim_bus() speed/mode setup logic
Currently, when different spi slaves claim the bus consecutively using
spi_claim_bus(), spi_set_speed_mode() will only be executed on the first
two calls, leaving the bus in a bad state starting with the third call.

This patch drops spi_slave->speed member and adds caching of bus
speed/mode in dm_spi_bus struct. It also updates spi_claim_bus() to call
spi_set_speed_mode() if either speed or mode is different from what the
bus is currently configured for. Current behavior is to only take into
account the speed, but not the mode, which seems wrong.

Fixes: 60e2809a84 ("dm: spi: Avoid setting the speed with every transfer")
Reviewed-by: Simon Glass <sjg@chromium.org>
Reported-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
Reported-by: Moshe, Yaniv <yanivmo@amazon.com>
Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
2020-12-22 20:39:26 -07:00
..
am654_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
arm_pl180_mmci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
arm_pl180_mmci.h mmc: arm_pl180_mmci: Sync compatible with kernel 2019-04-23 15:31:30 +02:00
aspeed_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
atmel_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
bcm2835_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
bcm2835_sdhost.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
bcmstb_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
ca_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
davinci_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
dw_mmc.c common: Drop linux/delay.h from common header 2020-05-18 21:19:23 -04:00
exynos_dw_mmc.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
fsl_esdhc.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
fsl_esdhc_imx.c dm: Avoid accessing seq directly 2020-12-18 20:32:21 -07:00
fsl_esdhc_spl.c common: Move hang() to the same header as panic() 2020-01-17 17:53:40 -05:00
ftsdc010_mci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
ftsdc010_mci.h SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
gen_atmel_mci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
hi6220_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
iproc_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
jz_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
Kconfig mmc: fsl_esdhc: add ADMA2 support 2020-10-14 14:00:44 +08:00
kona_sdhci.c common: Drop linux/delay.h from common header 2020-05-18 21:19:23 -04:00
Makefile mmc: sdhci: move the ADMA2 table handling into own module 2020-10-12 15:50:19 +08:00
meson_gx_mmc.c dm: treewide: Rename ..._platdata variables to just ..._plat 2020-12-13 16:51:09 -07:00
meson_gx_mmc.h dm: treewide: Rename ..._platdata variables to just ..._plat 2020-12-13 16:51:09 -07:00
mmc-uclass.c dm: treewide: Rename 'platdata' variables to just 'plat' 2020-12-13 16:51:08 -07:00
mmc.c dm: treewide: Rename 'platdata' variables to just 'plat' 2020-12-13 16:51:08 -07:00
mmc_boot.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
mmc_legacy.c Move eSDHC adapter card identification to board files 2020-07-27 14:16:28 +05:30
mmc_private.h Move eSDHC adapter card identification to board files 2020-07-27 14:16:28 +05:30
mmc_spi.c spi: spi-uclass: Fix spi_claim_bus() speed/mode setup logic 2020-12-22 20:39:26 -07:00
mmc_write.c dm: treewide: Rename 'platdata' variables to just 'plat' 2020-12-13 16:51:08 -07:00
msm_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
mtk-sd.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
mv_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
mvebu_mmc.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00
mxcmmc.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00
mxsmmc.c dm: treewide: Rename ..._platdata variables to just ..._plat 2020-12-13 16:51:09 -07:00
nexell_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
octeontx_hsmmc.c octeon: Don't attempt to set the sequence number 2020-12-18 20:32:21 -07:00
octeontx_hsmmc.h mmc: Add MMC controller driver for OcteonTX / TX2 2020-08-25 08:01:16 +02:00
omap_hsmmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
pci_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
pic32_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
pxa_mmc_gen.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
renesas-sdhi.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
rockchip_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
rockchip_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
rpmb.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
s5p_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
sandbox_mmc.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
sdhci-adma.c mmc: sdhci: move the ADMA2 table handling into own module 2020-10-12 15:50:19 +08:00
sdhci-cadence.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
sdhci.c Revert "mmc: zynq: parse dt when probing" 2020-10-27 08:13:33 +01:00
sh_mmcif.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
sh_mmcif.h SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
sh_sdhi.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
snps_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
socfpga_dw_mmc.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
sti_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
stm32_sdmmc2.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
sunxi_mmc.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
tangier_sdhci.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
tegra_mmc.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
tmio-common.c dm: treewide: Rename dev_get_platdata() to dev_get_plat() 2020-12-13 16:51:09 -07:00
tmio-common.h common: Drop linux/bitops.h from common header 2020-05-18 21:19:23 -04:00
uniphier-sd.c dm: treewide: Rename 'platdata' variables to just 'plat' 2020-12-13 16:51:08 -07:00
xenon_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00
zynq_sdhci.c dm: treewide: Rename ofdata_to_platdata() to of_to_plat() 2020-12-13 16:51:09 -07:00