linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] DW apb_ssi V4 support for Kendryte K210 RISC-V SoC
@ 2020-11-26  2:00 Damien Le Moal
  2020-11-26  2:00 ` [PATCH v2 1/3] spi: dw: Add support for 32-bits max xfer size Damien Le Moal
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Damien Le Moal @ 2020-11-26  2:00 UTC (permalink / raw)
  To: Serge Semin, Mark Brown, linux-spi, Rob Herring, devicetree; +Cc: Sean Anderson

The Canaan Kendryte K210 RISC-V SoC includes a DesignWare apb_ssi V4
SPI controller implemented with a maximum data frame size of 32-bits
(SSI_MAX_XFER_SIZE=32 synthesis parameter).

This series of patches adds support for this SoC by implementing support
for the 32-bits xfer size configuration. This is done in patch 1.

Patch 2 introduces a workaround for a HW bug on this SoC which triggers
RX FIFO overrun errors when the RX FIFO fills up to its maximum detected
depth of 32. The patch manually reduces the fifo depth to 31.

Patch 3 documents the new compatible string "canaan,k210-spi" used to
identify this SoC.

Changes from v1:
* Fixed patch 1 as suggested by Serge: change capability flag name to
  DW_SPI_CAP_DFS32 and fixed the capability detection to use the regular
  position of the dfs filed rather than the new position with DFS32.
  Also enable DW_SPI_CAP_DFS32 for SPI slaves.
* Added Serge's Acked-by tag to patch 2 and 3.

Damien Le Moal (3):
  spi: dw: Add support for 32-bits max xfer size
  spi: dw: Add support for the Canaan K210 SoC SPI
  dt-bindings: spi: dw-apb-ssi: Add Canaan K210 SPI controller

 .../bindings/spi/snps,dw-apb-ssi.yaml         |  2 +
 drivers/spi/spi-dw-core.c                     | 44 ++++++++++++++++---
 drivers/spi/spi-dw-mmio.c                     | 16 +++++++
 drivers/spi/spi-dw.h                          |  5 +++
 4 files changed, 60 insertions(+), 7 deletions(-)

-- 
2.28.0


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

end of thread, other threads:[~2020-12-05 15:48 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-26  2:00 [PATCH v2 0/3] DW apb_ssi V4 support for Kendryte K210 RISC-V SoC Damien Le Moal
2020-11-26  2:00 ` [PATCH v2 1/3] spi: dw: Add support for 32-bits max xfer size Damien Le Moal
2020-12-05 13:42   ` Serge Semin
2020-11-26  2:00 ` [PATCH v2 2/3] spi: dw: Add support for the Canaan K210 SoC SPI Damien Le Moal
2020-11-26  2:00 ` [PATCH v2 3/3] dt-bindings: spi: dw-apb-ssi: Add Canaan K210 SPI controller Damien Le Moal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).