Message ID | 20240107223817.EDB59C433C7@smtp.kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [GIT,PULL] SPI updates for v6.8 | expand |
The pull request you sent on Sun, 07 Jan 2024 22:38:09 +0000:
> https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git tags/spi-v6.8
has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/301940020a92ebdef9352a0573075a1db42d17aa
Thank you!
On Sun, 2024-01-07 at 22:38 +0000, Mark Brown wrote: > The following changes since commit 2cc14f52aeb78ce3f29677c2de1f06c0e91471ab: > > Linux 6.7-rc3 (2023-11-26 19:59:33 -0800) > > are available in the Git repository at: > > https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git tags/spi-v6.8 > > for you to fetch changes up to f6cd66231aa58599526584ff4df1bdde8d86eac8: > > spi: stm32: add st,stm32mp25-spi compatible supporting STM32MP25 soc (2023-12-21 20:44:05 +0000) > > ---------------------------------------------------------------- > spi: Updates for v6.8 > > A moderately busy release for SPI, the main core update was the merging > of support for multiple chip selects, used in some flash configurations. > There were also big overhauls for the AXI SPI Engine and PL022 drivers, > plus some new device support for ST. > > There's a few patches for other trees, API updates to allow the > multiple chip select support and one of the naming modernisations > touched a controller embedded in the USB code. > > - Support for multiple chip selects. [skipped the rest] Hi, it seems I have an issue related with this new feature. I just booted 6.8.0-rc1 on Turris Omnia (CONFIG_SPI_ORION=y, device tree: arch/arm/boot/dts/marvell/armada-385-turris-omnia.dts) and got the following error: [ 0.090231] spi_master spi0: No. of CS is more than max. no. of supported CS [ 0.097358] spi_master spi0: Failed to create SPI device for /soc/spi@10600/flash@0 End result: the three MTD partitions I used to have on the SPI-NOR are gone. *** For reference, here's the output of 6.7.0 (configs as identical as they can be): [ 0.087965] spi-nor spi0.0: s25fl164k (8192 Kbytes) [ 0.183729] Freeing initrd memory: 4676K [ 0.191605] 3 fixed-partitions partitions found on MTD device spi0.0 [ 0.191619] Creating 3 MTD partitions on "spi0.0": [ 0.191624] 0x000000000000-0x0000000f0000 : "U-Boot" [ 0.191837] 0x000000100000-0x000000800000 : "Rescue system" [ 0.191982] 0x0000000f0000-0x000000100000 : "u-boot-env" I haven't bisected this further, but maybe the error message already rings a bell. Best regards, Klaus
On Mon, Jan 22, 2024 at 07:30:09PM +0100, Klaus Kudielka wrote: > On Sun, 2024-01-07 at 22:38 +0000, Mark Brown wrote: > > - Support for multiple chip selects. > [skipped the rest] > > Hi, it seems I have an issue related with this new feature. > > I just booted 6.8.0-rc1 on Turris Omnia (CONFIG_SPI_ORION=y, > device tree: arch/arm/boot/dts/marvell/armada-385-turris-omnia.dts) > and got the following error: > > [ 0.090231] spi_master spi0: No. of CS is more than max. no. of supported CS > [ 0.097358] spi_master spi0: Failed to create SPI device for /soc/spi@10600/flash@0 > End result: the three MTD partitions I used to have on the SPI-NOR are gone. Yes, this was found on another platform - there's a patch which should address this (unless the number is more than 8) in CI: https://lore.kernel.org/linux-spi/20240122-spi-multi-cs-max-v1-1-a7e98cd5f6c7@kernel.org/T/#u
On Mon, Jan 22, 2024 at 07:30:09PM +0100, Klaus Kudielka wrote: > On Sun, 2024-01-07 at 22:38 +0000, Mark Brown wrote: > I just booted 6.8.0-rc1 on Turris Omnia (CONFIG_SPI_ORION=y, > device tree: arch/arm/boot/dts/marvell/armada-385-turris-omnia.dts) > and got the following error: > > [ 0.090231] spi_master spi0: No. of CS is more than max. no. of supported CS > [ 0.097358] spi_master spi0: Failed to create SPI device for /soc/spi@10600/flash@0 > > End result: the three MTD partitions I used to have on the SPI-NOR are gone. Actualy looking at the DT it's not immediately obvious why this is triggering - there's only one chip select in use, numbered 0 AFAICT. Anyway, if you could test the patch I linked hopefully it does fix the issue.
On Mon, 2024-01-22 at 18:38 +0000, Mark Brown wrote: > On Mon, Jan 22, 2024 at 07:30:09PM +0100, Klaus Kudielka wrote: > > On Sun, 2024-01-07 at 22:38 +0000, Mark Brown wrote: > > > I just booted 6.8.0-rc1 on Turris Omnia (CONFIG_SPI_ORION=y, > > device tree: arch/arm/boot/dts/marvell/armada-385-turris-omnia.dts) > > > and got the following error: > > > > [ 0.090231] spi_master spi0: No. of CS is more than max. no. of supported CS > > [ 0.097358] spi_master spi0: Failed to create SPI device for /soc/spi@10600/flash@0 > > > > End result: the three MTD partitions I used to have on the SPI-NOR are gone. > > Actualy looking at the DT it's not immediately obvious why this is > triggering - there's only one chip select in use, numbered 0 AFAICT. > Anyway, if you could test the patch I linked hopefully it does fix the > issue. I wouldn't have an explanation either. But said patch, applied on top of 6.8.0-rc1, seems to be a possible cure. Everything nominal again, AFAICT. [ 0.191427] 3 fixed-partitions partitions found on MTD device spi0.0 [ 0.191440] Creating 3 MTD partitions on "spi0.0": [ 0.191446] 0x000000000000-0x0000000f0000 : "U-Boot" [ 0.191656] 0x000000100000-0x000000800000 : "Rescue system" [ 0.191796] 0x0000000f0000-0x000000100000 : "u-boot-env" Thanks, Klaus
On Mon, Jan 22, 2024 at 07:57:01PM +0100, Klaus Kudielka wrote: > I wouldn't have an explanation either. But said patch, applied on top of 6.8.0-rc1, > seems to be a possible cure. Everything nominal again, AFAICT. Great, thanks for checking - the fix should in -rc2 all being well.
On Mon, 2024-01-22 at 18:38 +0000, Mark Brown wrote: > On Mon, Jan 22, 2024 at 07:30:09PM +0100, Klaus Kudielka wrote: > > On Sun, 2024-01-07 at 22:38 +0000, Mark Brown wrote: > > > I just booted 6.8.0-rc1 on Turris Omnia (CONFIG_SPI_ORION=y, > > device tree: arch/arm/boot/dts/marvell/armada-385-turris-omnia.dts) > > > and got the following error: > > > > [ 0.090231] spi_master spi0: No. of CS is more than max. no. of supported CS > > [ 0.097358] spi_master spi0: Failed to create SPI device for /soc/spi@10600/flash@0 > > > > End result: the three MTD partitions I used to have on the SPI-NOR are gone. > > Actualy looking at the DT it's not immediately obvious why this is > triggering - there's only one chip select in use, numbered 0 AFAICT. > Anyway, if you could test the patch I linked hopefully it does fix the > issue. For the records, drivers/spi/spi-orion.c states: /* Some SoCs using this driver support up to 8 chip selects. * It is up to the implementer to only use the chip selects * that are available. */ #define ORION_NUM_CHIPSELECTS 8 [...] and then in orion_spi_probe(): host->num_chipselect = ORION_NUM_CHIPSELECTS;