[PATCH v7 0/5] spi: add SPI_MOSI_IDLE_LOW mode bit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Some spi controller switch the mosi line to high, whenever they are
idle. This may not be desired in all use cases. For example neopixel
leds can get confused and flicker due to misinterpreting the idle state.
Therefore, we introduce a new spi-mode bit, with which the idle behaviour
can be overwritten on a per device basis.

---

Link for versions:
  v1 and v2: https://lore.kernel.org/linux-spi/20230511135632.78344-1-bstruempfel@xxxxxxxxxxxxxx/
  v3: https://lore.kernel.org/linux-spi/20230517103007.26287-1-boerge.struempfel@xxxxxxxxx/T/#t
  v4: https://lore.kernel.org/linux-spi/CAEktqctboF3=ykVNtPsifcmHzF6dWwoEcVh+O4H1u-R=TT6gHg@xxxxxxxxxxxxxx/T/#t
  v5: https://lore.kernel.org/linux-spi/20230520190856.34720-1-boerge.struempfel@xxxxxxxxx/T/#t
  v6: https://lore.kernel.org/linux-spi/20230524091948.41779-1-boerge.struempfel@xxxxxxxxx/T/#t

Changes from V6:
  - Adjusted the patches for next/master

Changes from V5:
  - Added a patch to reorder the command line options for
    spidev_test in order to increase usability. The indentation
    fixes were also done in this patch.

Changes from V4:
  - Added the SPI_3WIRE_HIZ mode bit to spidev
  - Added the SPI_MOSI_IDLE_LOW mode bit to the spidev_test
    userspace tool and added the two other missing spi mode
    bits (SPI_3WIRE_HIZ and SPI_RX_CPHA_FLIP) to it as well.

Changes from V3:
  - Added missing paranthesis which caused builderrors

Changes from V2:
  - Removed the device-tree binding since this should not be managed by
    the DT but by the device itself.
  - Replaced all occurences of spi->chip_select with the corresponding
    macro spi_get_chipselect(spi,0)

Changes from V1:
  - Added patch, introducing the new devicetree binding flag
  - Split the generic spi part of the patch from the imx-spi specific
    part
  - Replaced SPI_CPOL and SPI_CPHA by the combined SPI_MODE_X_MASK bit
    in the imx-spi.c modebits.
  - Added the SPI_MOSI_IDLE_LOW bit to spidev

Boerge Struempfel (5):
  spi: add SPI_MOSI_IDLE_LOW mode bit
  spi: spi-imx: add support for SPI_MOSI_IDLE_LOW mode bit
  spi: spidev: add two new spi mode bits
  spi: spidev_test: Sorted the options into logical groups
  spi: spidev_test Add three missing spi mode bits

 drivers/spi/spi-imx.c        |   9 ++-
 drivers/spi/spidev.c         |   3 +-
 include/uapi/linux/spi/spi.h |   3 +-
 tools/spi/spidev_test.c      | 107 +++++++++++++++++++++--------------
 4 files changed, 76 insertions(+), 46 deletions(-)

-- 
2.40.1




[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux