linux/drivers/spi
Mark Brown b7d73cb63c
Merge series "add ecspi ERR009165 for i.mx6/7 soc family" from Robin Gong <yibin.gong@nxp.com>:
There is ecspi ERR009165 on i.mx6/7 soc family, which cause FIFO
transfer to be send twice in DMA mode. Please get more information from:
https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf. The workaround is adding
new sdma ram script which works in XCH  mode as PIO inside sdma instead
of SMC mode, meanwhile, 'TX_THRESHOLD' should be 0. The issue should be
exist on all legacy i.mx6/7 soc family before i.mx6ul.
NXP fix this design issue from i.mx6ul, so newer chips including i.mx6ul/
6ull/6sll do not need this workaroud anymore. All other i.mx6/7/8 chips
still need this workaroud. This patch set add new 'fsl,imx6ul-ecspi'
for ecspi driver and 'ecspi_fixed' in sdma driver to choose if need errata
or not.
The first two reverted patches should be the same issue, though, it
seems 'fixed' by changing to other shp script. Hope Sean or Sascha could
have the chance to test this patch set if could fix their issues.
Besides, enable sdma support for i.mx8mm/8mq and fix ecspi1 not work
on i.mx8mm because the event id is zero.

PS:
   Please get sdma firmware from below linux-firmware and copy it to your
local rootfs /lib/firmware/imx/sdma.
https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/imx/sdma

v2:
  1.Add commit log for reverted patches.
  2.Add comment for 'ecspi_fixed' in sdma driver.
  3.Add 'fsl,imx6sll-ecspi' compatible instead of 'fsl,imx6ul-ecspi'
    rather than remove.
v3:
  1.Confirm with design team make sure ERR009165 fixed on i.mx6ul/i.mx6ull
    /i.mx6sll, not fixed on i.mx8m/8mm and other i.mx6/7 legacy chips.
    Correct dts related dts patch in v2.
  2.Clean eratta information in binding doc and new 'tx_glitch_fixed' flag
    in spi-imx driver to state ERR009165 fixed or not.
  3.Enlarge burst size to fifo size for tx since tx_wml set to 0 in the
    errata workaroud, thus improve performance as possible.
v4:
  1.Add Ack tag from Mark and Vinod
  2.Remove checking 'event_id1' zero as 'event_id0'.
v5:
  1.Add the last patch for compatible with the current uart driver which
    using rom script, so both uart ram script and rom script supported
    in latest firmware, by default uart rom script used. UART driver
    will be broken without this patch.
v6:
  1.Resend after rebase the latest next branch.
  2.Remove below No.13~No.15 patches of v5 because they were mergered.
  	ARM: dts: imx6ul: add dma support on ecspi
  	ARM: dts: imx6sll: correct sdma compatible
  	arm64: defconfig: Enable SDMA on i.mx8mq/8mm
  3.Revert "dmaengine: imx-sdma: fix context cache" since
    'context_loaded' removed.
v7:
  1.Put the last patch 13/13 'Revert "dmaengine: imx-sdma: fix context
    cache"' to the ahead of 03/13 'Revert "dmaengine: imx-sdma: refine
    to load context only once" so that no building waring during comes out
    during bisect.
  2.Address Sascha's comments, including eliminating any i.mx6sx in this
    series, adding new 'is_imx6ul_ecspi()' instead imx in imx51 and taking
    care SMC bit for PIO.
  3.Add back missing 'Reviewed-by' tag on 08/15(v5):09/13(v7)
   'spi: imx: add new i.mx6ul compatible name in binding doc'
v8:
  1.remove 0003-Revert-dmaengine-imx-sdma-fix-context-cache.patch and merge
    it into 04/13 of v7
  2.add 0005-spi-imx-fallback-to-PIO-if-dma-setup-failure.patch for no any
    ecspi function broken even if sdma firmware not updated.
  3.merge 'tx.dst_maxburst' changes in the two continous patches into one
    patch to avoid confusion.
  4.fix typo 'duplicated'.

Robin Gong (13):
  Revert "ARM: dts: imx6q: Use correct SDMA script for SPI5 core"
  Revert "ARM: dts: imx6: Use correct SDMA script for SPI cores"
  Revert "dmaengine: imx-sdma: refine to load context only once"
  dmaengine: imx-sdma: remove duplicated sdma_load_context
  spi: imx: fallback to PIO if dma setup failure
  dmaengine: imx-sdma: add mcu_2_ecspi script
  spi: imx: fix ERR009165
  spi: imx: remove ERR009165 workaround on i.mx6ul
  spi: imx: add new i.mx6ul compatible name in binding doc
  dmaengine: imx-sdma: remove ERR009165 on i.mx6ul
  dma: imx-sdma: add i.mx6ul compatible name
  dmaengine: imx-sdma: fix ecspi1 rx dma not work on i.mx8mm
  dmaengine: imx-sdma: add uart rom script

 .../devicetree/bindings/dma/fsl-imx-sdma.txt       |  1 +
 .../devicetree/bindings/spi/fsl-imx-cspi.txt       |  1 +
 arch/arm/boot/dts/imx6q.dtsi                       |  2 +-
 arch/arm/boot/dts/imx6qdl.dtsi                     |  8 +-
 drivers/dma/imx-sdma.c                             | 67 ++++++++++------
 drivers/spi/spi-imx.c                              | 92 +++++++++++++++++++---
 include/linux/platform_data/dma-imx-sdma.h         |  8 +-
 7 files changed, 135 insertions(+), 44 deletions(-)

--
2.7.4

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
2020-05-28 14:01:17 +01:00
..
atmel-quadspi.c spi: atmel-quadspi: Add verbose debug facilities to monitor register accesses 2020-03-20 13:03:38 +00:00
internals.h spi: Add an helper to flush the message queue 2018-04-23 15:48:18 +01:00
Kconfig spi: uniphier: Depend on HAS_IOMEM 2020-05-11 18:17:51 +01:00
Makefile spi: spi-amd: Add AMD SPI controller driver support 2020-04-27 16:38:32 +01:00
spi-altera.c spi: altera: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:14:50 +01:00
spi-amd.c spi: amd: Drop superfluous member from struct amd_spi 2020-05-04 17:18:49 +01:00
spi-ar934x.c spi: add driver for ar934x spi controller 2020-02-11 11:37:30 +00:00
spi-armada-3700.c spi: a3700: make a3700_spi_init() return void 2020-05-06 15:55:13 +01:00
spi-at91-usart.c spi: at91-usart: Use dma_request_chan() directly for channel request 2019-11-15 12:13:02 +00:00
spi-ath79.c spi: ath79: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:15:29 +01:00
spi-atmel.c spi: atmel: Add missing annotation for atmel_spi_next_xfer_dma_submit() 2020-04-30 15:35:25 +01:00
spi-au1550.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
spi-axi-spi-engine.c spi: spi-axi-spi-engine: Access register after clock initialization 2020-04-09 18:46:53 +01:00
spi-bcm-qspi.c Merge branch 'for-5.7' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi into spi-5.8 2020-05-05 11:48:25 +01:00
spi-bcm-qspi.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 459 2019-06-19 17:09:09 +02:00
spi-bcm63xx-hsspi.c spi: bcm63xx-hsspi: Really keep pll clk enabled 2020-03-02 15:03:19 +00:00
spi-bcm63xx.c spi: bcm63xx: extend error condition to delay as well 2019-10-15 11:47:06 +01:00
spi-bcm2835.c spi: bcm2835: Tear down DMA before turning off SPI controller 2020-05-20 18:16:41 +01:00
spi-bcm2835aux.c spi: bcm2835aux: Fix controller unregister order 2020-05-20 15:16:12 +01:00
spi-bitbang-txrx.h
spi-bitbang.c spi: bitbang: Make chipselect callback optional 2019-12-09 18:46:34 +00:00
spi-brcmstb-qspi.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 459 2019-06-19 17:09:09 +02:00
spi-butterfly.c spi: docs: convert to ReST and add it to the kABI bookset 2019-07-31 14:13:13 -06:00
spi-cadence.c spi: cadence: Correct handling of native chipselect 2019-11-27 12:54:45 +00:00
spi-cavium-octeon.c spi: octeon: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:17:27 +01:00
spi-cavium-thunderx.c spi: spi-cavium-thunderx: Add missing pci_release_regions() 2019-12-09 18:44:19 +00:00
spi-cavium.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-cavium.h
spi-clps711x.c spi: clps711x: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:17:36 +01:00
spi-coldfire-qspi.c spi: coldfire-qspi: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:17:56 +01:00
spi-davinci.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
spi-dln2.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 372 2019-06-05 17:37:10 +02:00
spi-dw-mid.c spi: dw: Discard dma_width member of the dw_spi structure 2020-05-22 13:45:55 +01:00
spi-dw-mmio.c spi: dw: Initialize paddr in DW SPI MMIO private data 2020-05-15 18:29:16 +01:00
spi-dw-pci.c spi: dw: Add Elkhart Lake PSE DMA support 2020-05-06 18:11:36 +01:00
spi-dw.c spi: dw: Discard dma_width member of the dw_spi structure 2020-05-22 13:45:55 +01:00
spi-dw.h spi: dw: Discard dma_width member of the dw_spi structure 2020-05-22 13:45:55 +01:00
spi-efm32.c spi: efm32: Convert to use GPIO descriptors 2020-03-27 15:52:23 +00:00
spi-ep93xx.c spi: spi-ep93xx: fix wrong SPI mode selection 2020-04-03 14:55:55 +01:00
spi-falcon.c spi: spi-falcon: extend warning to delay as well 2019-10-15 11:46:57 +01:00
spi-fsi.c spi: Add FSI-attached SPI controller driver 2020-03-10 14:11:57 +00:00
spi-fsl-cpm.c spi: fsl-cpm: Correct the free:ing 2019-11-15 12:12:15 +00:00
spi-fsl-cpm.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
spi-fsl-dspi.c spi: spi-fsl-dspi: Adding shutdown hook 2020-04-24 13:56:38 +01:00
spi-fsl-espi.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-fsl-lib.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
spi-fsl-lib.h spi: fsl: Convert to use CS GPIO descriptors 2019-08-28 14:10:41 +01:00
spi-fsl-lpspi.c spi: spi-fsl-lpspi: Fix runtime PM imbalance on error 2020-05-26 17:44:55 +01:00
spi-fsl-qspi.c spi: spi-fsl-qspi: Fix return value check of devm_ioremap() in probe 2020-04-22 14:07:46 +01:00
spi-fsl-spi.c spi: spi-fsl-spi: Fix checkpatch error "foo * bar" should be "foo *bar" 2020-04-14 18:36:30 +01:00
spi-fsl-spi.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
spi-geni-qcom.c spi: spi-geni-qcom: Drop of.h include 2020-02-11 11:36:51 +00:00
spi-gpio.c Merge branch 'for-5.4' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi into spi-5.5 2019-10-08 19:12:28 +01:00
spi-hisi-sfc-v3xx.c spi: hisi-sfc-v3xx: add error check after per operation 2020-04-17 14:21:00 +01:00
spi-img-spfi.c spi: img-spfi: Use dma_request_chan() instead dma_request_slave_channel() 2019-12-16 11:57:06 +00:00
spi-imx.c spi: imx: fallback to PIO if dma setup failure 2020-05-28 13:41:48 +01:00
spi-iproc-qspi.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
spi-jcore.c remove ioremap_nocache and devm_ioremap_nocache 2020-01-06 09:45:59 +01:00
spi-lantiq-ssc.c spi: lantiq-ssc: Use devm_platform_ioremap_resource() in lantiq_ssc_probe() 2019-10-01 12:34:18 +01:00
spi-lm70llp.c spi: docs: convert to ReST and add it to the kABI bookset 2019-07-31 14:13:13 -06:00
spi-loopback-test.c spi: spi-loopback-test: use new delay field 2019-10-15 11:45:19 +01:00
spi-lp8841-rtc.c spi: lp-8841: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:18:35 +01:00
spi-mem.c spi: spi-mem: Fix Dual/Quad modes on Octal-capable devices 2020-04-23 16:35:27 +01:00
spi-meson-spicc.c spi: meson-spicc: add support for Amlogic G12A 2020-03-12 17:22:55 +00:00
spi-meson-spifc.c spi: spi-meson-spifc: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:19:14 +01:00
spi-mpc52xx-psc.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-mpc52xx.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 428 2019-06-05 17:37:16 +02:00
spi-mpc512x-psc.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-mt65xx.c spi: mediatek: add SPI_CS_HIGH support 2019-11-18 17:47:00 +00:00
spi-mt7621.c spi: mt7621: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:19:34 +01:00
spi-mtk-nor.c spi: spi-mtk-nor: make mtk_nor_exec_op() statuc 2020-04-14 18:36:33 +01:00
spi-mux.c spi: Add generic SPI multiplexer 2020-02-12 23:56:18 +00:00
spi-mxic.c Merge branch 'for-5.4' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi into spi-5.5 2019-10-08 19:12:28 +01:00
spi-mxs.c spi: mxs: Drop GPIO includes 2020-03-17 13:20:16 +00:00
spi-npcm-fiu.c remove ioremap_nocache and devm_ioremap_nocache 2020-01-06 09:45:59 +01:00
spi-npcm-pspi.c Merge branch 'spi-5.6' into spi-next 2020-01-23 12:37:18 +00:00
spi-nxp-fspi.c spi: spi-nxp-fspi: Fix a NULL vs IS_ERR() check in probe 2020-03-12 15:09:58 +00:00
spi-oc-tiny.c spi: oc-tiny: Use GPIO descriptors 2019-12-27 01:08:11 +00:00
spi-omap-100k.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-omap-uwire.c
spi-omap2-mcspi.c spi: spi-omap2-mcspi: Support probe deferral for DMA channels 2020-02-06 15:53:57 +00:00
spi-orion.c spi: orion: Convert to use GPIO descriptors 2020-04-21 19:48:05 +01:00
spi-pic32-sqi.c spi: pic32-sqi: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:20:52 +01:00
spi-pic32.c spi: pic32: Retire dma_request_slave_channel_compat() 2019-11-22 19:53:41 +00:00
spi-pl022.c spi: pl022: Use dma_request_chan() directly for channel request 2019-11-15 12:14:19 +00:00
spi-ppc4xx.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-pxa2xx-dma.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-pxa2xx-pci.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
spi-pxa2xx.c spi: pxa2xx: Apply CS clk quirk to BXT 2020-04-30 15:22:58 +01:00
spi-pxa2xx.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-qcom-qspi.c spi: spi-qcom-qspi: Use device managed memory for clk_bulk_data 2020-01-13 15:04:40 +00:00
spi-qup.c spi: qup: call spi_qup_pm_resume_runtime before suspending 2020-02-21 13:48:08 +00:00
spi-rb4xx.c spi: rb4xx: update driver to be device tree aware 2020-05-22 14:13:17 +01:00
spi-rockchip.c spi: spi-rockchip: use num-cs property and ctlr->enable_gpiods 2020-05-15 18:50:06 +01:00
spi-rspi.c spi: rspi: Add support for active-high chip selects 2020-03-10 14:30:56 +00:00
spi-s3c24xx-fiq.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-s3c24xx-fiq.S treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-s3c24xx.c spi: spi-s3c24xx: Replace zero-length array with flexible-array member 2020-03-23 18:37:06 +00:00
spi-s3c64xx.c spi: s3c64xx: Use dma_request_chan() directly for channel request 2019-11-15 12:14:39 +00:00
spi-sc18is602.c spi: sc18is602: Fix a typo in MODULE_DESCRIPTION 2020-04-14 12:39:37 +01:00
spi-sh-hspi.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-sh-msiof.c spi: spi-sh-msiof: Fix checkpatch error Complex macros should use () 2020-04-14 18:36:34 +01:00
spi-sh-sci.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-sh.c spi: Remove dev_err() usage after platform_get_irq() 2019-08-02 12:15:43 +01:00
spi-sifive.c spi: sifive: disable clk when probe fails and remove 2019-11-04 13:26:11 +00:00
spi-sirf.c spi: sirf: Use dma_request_chan() instead dma_request_slave_channel() 2019-12-16 11:57:36 +00:00
spi-slave-mt27xx.c spi: mediatek: Use devm_platform_ioremap_resource() in mtk_spi_slave_probe() 2019-10-01 12:34:58 +01:00
spi-slave-system-control.c spi: slave: Fix missing break in switch 2018-10-03 16:23:10 +01:00
spi-slave-time.c
spi-sprd-adi.c spi: sprd: adi: Use IS_ENABLED() to validate configs 2020-04-14 18:36:32 +01:00
spi-sprd.c spi: sprd: Fix the incorrect SPI register 2019-12-04 12:14:13 +00:00
spi-st-ssc4.c spi: st-ssc4: add missed pm_runtime_disable 2019-11-18 12:59:11 +00:00
spi-stm32-qspi.c spi: stm32-qspi: Fix unbalanced pm_runtime_enable issue 2020-04-29 18:52:16 +01:00
spi-stm32.c spi: stm32: Add 'SPI_SIMPLEX_RX', 'SPI_3WIRE_RX' support for stm32f4 2020-05-25 15:56:16 +01:00
spi-sun4i.c spi: sun4i: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:22:29 +01:00
spi-sun6i.c spi: sun6i: Add support for GPIO chip select lines 2020-05-11 18:17:53 +01:00
spi-synquacer.c spi: Remove dev_err() usage after platform_get_irq() 2019-08-02 12:15:43 +01:00
spi-tegra20-sflash.c spi: tegra20-sflash: Fix runtime PM imbalance on error 2020-05-28 14:01:16 +01:00
spi-tegra20-slink.c spi: tegra20-slink: Fix runtime PM imbalance on error 2020-05-28 14:01:15 +01:00
spi-tegra114.c spi: tegra114: Fix runtime PM imbalance on error 2020-05-28 14:01:14 +01:00
spi-test.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
spi-ti-qspi.c spi: spi-ti-qspi: fix warning 2020-01-17 15:37:44 +00:00
spi-tle62x0.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
spi-topcliff-pch.c spi/topcliff-pch: Remove unneeded semicolon 2019-12-09 18:45:53 +00:00
spi-txx9.c spi: txx9: Convert to use GPIO descriptors 2019-10-30 14:14:32 +00:00
spi-uniphier.c spi: uniphier: Use devm_platform_get_and_ioremap_resource() to simplify code 2020-05-11 18:17:52 +01:00
spi-xcomm.c spi: use new spi_transfer_delay_exec helper where straightforward 2019-10-15 11:51:57 +01:00
spi-xilinx.c spi: xilinx: Add DT support for selecting transfer word width 2019-10-24 12:45:21 +01:00
spi-xlp.c spi: xlp: use devm_platform_ioremap_resource() to simplify code 2019-09-04 17:23:28 +01:00
spi-xtensa-xtfpga.c spi: xtensa-xtfpga: Use devm_platform_ioremap_resource() in xtfpga_spi_probe() 2019-10-01 12:35:18 +01:00
spi-zynq-qspi.c spi: zynq-qspi: Support two chip selects 2019-11-08 17:45:09 +00:00
spi-zynqmp-gqspi.c spi/zynqmp: remove entry that causes a cs glitch 2020-02-27 12:48:56 +00:00
spi.c spi: Remove note about transfer limit for spi_write_then_read() 2020-05-26 17:44:54 +01:00
spidev.c spi: spidev: Add support for Octal mode data transfers 2020-04-16 13:54:44 +01:00