mbox series

[v7,0/7] Add support for AD4000 series of ADCs

Message ID cover.1720810545.git.marcelo.schmitt@analog.com (mailing list archive)
Headers show
Series Add support for AD4000 series of ADCs | expand

Message

Marcelo Schmitt July 12, 2024, 7:20 p.m. UTC
This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
support configurable MOSI line idle states.
It then introduces the ad4000 driver which uses the MOSI idle configuration to
provide improved support for the AD4000 series of ADCs.
Documentation is added describing the new extension to the SPI protocol.
The currently supported wiring modes for AD4000 devices were documented under
IIO documentation directory.

Change log v6 -> v7:
[Device tree]
No changes to device tree from v6 to v7.
[SPI]
spi.c: Removed blank line added in code not related to MOSI idle feature.
spi: bitbang: Rewrapped commit message.
spi: bitbang: Rebased bitbang patch on top of spi for-next branch.
[IIO]
ad4000: Checked gain-milli read from dt and made it match one of supported gains or fail.
ad4000: Added blank lines to improve code readability.
ad4000: return 0; when known that no errors occurred.

Link to v6: https://lore.kernel.org/linux-iio/cover.1719686465.git.marcelo.schmitt@analog.com/
Link to v5: https://lore.kernel.org/linux-iio/cover.1719351923.git.marcelo.schmitt@analog.com/
Link to v4: https://lore.kernel.org/linux-iio/cover.1718749981.git.marcelo.schmitt@analog.com/
Link to v3: https://lore.kernel.org/linux-iio/cover.1717539384.git.marcelo.schmitt@analog.com/
Link to v2: https://lore.kernel.org/linux-iio/cover.1712585500.git.marcelo.schmitt@analog.com/
Link to v1: https://lore.kernel.org/linux-iio/cover.1711131830.git.marcelo.schmitt@analog.com/


Prerequisite patches to apply this series to IIO testing branch:

c3358a746e078d0f9048732c90fdab4f37c00e0d "spi: bitbang: Convert unsigned to unsigned int"
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?id=c3358a746e078d0f9048732c90fdab4f37c00e0d

f261172d39f358dcecce13c310690d3937e0cca6 "spi: bitbang: Use typedef for txrx_*() callbacks"
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?id=f261172d39f358dcecce13c310690d3937e0cca6

6ecdb0aa4dca62d236a659426e11e6cf302e8f18 "spi: axi-spi-engine: Add SPI_CS_HIGH support"
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?h=for-6.11&id=6ecdb0aa4dca62d236a659426e11e6cf302e8f18


Prerequisite patches to apply the series to SPI for-next brach:

ef60f9ca26d33d0f8e1a709771c61d3e96f64559 "docs: iio: add documentation for adis16480 driver"
https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git/commit/?h=testing&id=ef60f9ca26d33d0f8e1a709771c61d3e96f64559


Thanks,
Marcelo

Marcelo Schmitt (7):
  spi: Enable controllers to extend the SPI protocol with MOSI idle
    configuration
  spi: bitbang: Implement support for MOSI idle state configuration
  spi: spi-gpio: Add support for MOSI idle state configuration
  spi: spi-axi-spi-engine: Add support for MOSI idle configuration
  dt-bindings: iio: adc: Add AD4000
  iio: adc: Add support for AD4000
  Documentation: Add AD4000 documentation

 .../bindings/iio/adc/adi,ad4000.yaml          | 197 +++++
 Documentation/iio/ad4000.rst                  | 131 ++++
 Documentation/iio/index.rst                   |   1 +
 Documentation/spi/spi-summary.rst             |  83 ++
 MAINTAINERS                                   |   9 +
 drivers/iio/adc/Kconfig                       |  12 +
 drivers/iio/adc/Makefile                      |   1 +
 drivers/iio/adc/ad4000.c                      | 722 ++++++++++++++++++
 drivers/spi/spi-axi-spi-engine.c              |  15 +-
 drivers/spi/spi-bitbang.c                     |  24 +
 drivers/spi/spi-gpio.c                        |  12 +-
 drivers/spi/spi.c                             |   6 +
 include/linux/spi/spi_bitbang.h               |   1 +
 include/uapi/linux/spi/spi.h                  |   5 +-
 14 files changed, 1213 insertions(+), 6 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/adc/adi,ad4000.yaml
 create mode 100644 Documentation/iio/ad4000.rst
 create mode 100644 drivers/iio/adc/ad4000.c


base-commit: 986da024b99a72e64f6bdb3f3f0e52af024b1f50
prerequisite-patch-id: 76a35c35c2af889be2ff20052da02df561b3d71b
prerequisite-patch-id: ce5abb83d4f04e72c69d0df4ded79077065cd649
prerequisite-patch-id: b30f54a92e47dbad33ca7450089c7b19610e9cf2

Comments

Jonathan Cameron July 20, 2024, 1:10 p.m. UTC | #1
On Fri, 12 Jul 2024 16:20:00 -0300
Marcelo Schmitt <marcelo.schmitt@analog.com> wrote:

> This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
> support configurable MOSI line idle states.
> It then introduces the ad4000 driver which uses the MOSI idle configuration to
> provide improved support for the AD4000 series of ADCs.
> Documentation is added describing the new extension to the SPI protocol.
> The currently supported wiring modes for AD4000 devices were documented under
> IIO documentation directory.
> 
Hi Marcelo,

All looks good to me. 
So at this point, as long as Mark is happy with the SPI changes, I think we are
waiting for Mark to pick the SPI parts and tag that so I can merge
that into the IIO tree with the driver.  I assume Mark won't
do that until after rc1.  All the dependencies are upstream already but mid
merge window isn't a good point to use as a base for anything!

Give this a poke after rc2 or so if you don't see progress.

Thanks,

Jonathan
Mark Brown July 29, 2024, 6:02 p.m. UTC | #2
On Fri, 12 Jul 2024 16:20:00 -0300, Marcelo Schmitt wrote:
> This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
> support configurable MOSI line idle states.
> It then introduces the ad4000 driver which uses the MOSI idle configuration to
> provide improved support for the AD4000 series of ADCs.
> Documentation is added describing the new extension to the SPI protocol.
> The currently supported wiring modes for AD4000 devices were documented under
> IIO documentation directory.
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next

Thanks!

[1/7] spi: Enable controllers to extend the SPI protocol with MOSI idle configuration
      commit: f58872f45c36ded048bccc22701b0986019c24d8
[2/7] spi: bitbang: Implement support for MOSI idle state configuration
      commit: 320f6693097bf89d67f9cabad24a2b911e23073f
[3/7] spi: spi-gpio: Add support for MOSI idle state configuration
      commit: 927d382c7efbcc2206c31fa2f672fa264c0f1d5b
[4/7] spi: spi-axi-spi-engine: Add support for MOSI idle configuration
      commit: a62073f4b2164028fc7c5ae45ceba10c9326cd91
[5/7] dt-bindings: iio: adc: Add AD4000
      commit: 96472f18a4affdaff5013a836c48375f1eddb4a4

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark
Jonathan Cameron July 29, 2024, 8:15 p.m. UTC | #3
On Mon, 29 Jul 2024 19:02:29 +0100
Mark Brown <broonie@kernel.org> wrote:

> On Fri, 12 Jul 2024 16:20:00 -0300, Marcelo Schmitt wrote:
> > This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
> > support configurable MOSI line idle states.
> > It then introduces the ad4000 driver which uses the MOSI idle configuration to
> > provide improved support for the AD4000 series of ADCs.
> > Documentation is added describing the new extension to the SPI protocol.
> > The currently supported wiring modes for AD4000 devices were documented under
> > IIO documentation directory.
> > 
> > [...]  
> 
> Applied to
> 
>    https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next
> 
> Thanks!
> 
> [1/7] spi: Enable controllers to extend the SPI protocol with MOSI idle configuration
>       commit: f58872f45c36ded048bccc22701b0986019c24d8
> [2/7] spi: bitbang: Implement support for MOSI idle state configuration
>       commit: 320f6693097bf89d67f9cabad24a2b911e23073f
> [3/7] spi: spi-gpio: Add support for MOSI idle state configuration
>       commit: 927d382c7efbcc2206c31fa2f672fa264c0f1d5b
> [4/7] spi: spi-axi-spi-engine: Add support for MOSI idle configuration
>       commit: a62073f4b2164028fc7c5ae45ceba10c9326cd91
> [5/7] dt-bindings: iio: adc: Add AD4000
>       commit: 96472f18a4affdaff5013a836c48375f1eddb4a4
Ah. I replied to wrong message.

I suspect you didn't intend to pick up patch 5.

Any chance of a tag I can pull to support patches 5-7?
I need the HIGH flag in patch 1 only.
If not I'll replace it with a numeric value + comments, and queue up a patch for
next cycle to switch to the define.

Jonathan



> 
> All being well this means that it will be integrated into the linux-next
> tree (usually sometime in the next 24 hours) and sent to Linus during
> the next merge window (or sooner if it is a bug fix), however if
> problems are discovered then the patch may be dropped or reverted.
> 
> You may get further e-mails resulting from automated or manual testing
> and review of the tree, please engage with people reporting problems and
> send followup patches addressing any issues that are reported if needed.
> 
> If any updates are required or you are submitting further changes they
> should be sent as incremental updates against current git, existing
> patches will not be replaced.
> 
> Please add any relevant lists and maintainers to the CCs when replying
> to this mail.
> 
> Thanks,
> Mark
>
Mark Brown July 31, 2024, 12:04 a.m. UTC | #4
On Fri, Jul 12, 2024 at 04:20:00PM -0300, Marcelo Schmitt wrote:
> This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
> support configurable MOSI line idle states.

The following changes since commit 8400291e289ee6b2bf9779ff1c83a291501f017b:

  Linux 6.11-rc1 (2024-07-28 14:19:55 -0700)

are available in the Git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git tags/spi-mosi-config

for you to fetch changes up to 96472f18a4affdaff5013a836c48375f1eddb4a4:

  dt-bindings: iio: adc: Add AD4000 (2024-07-29 01:19:55 +0100)

----------------------------------------------------------------
spi: Support MOSI idle configuration

Add support for configuring the idle state of the MOSI signal in
controllers.

----------------------------------------------------------------
Marcelo Schmitt (5):
      spi: Enable controllers to extend the SPI protocol with MOSI idle configuration
      spi: bitbang: Implement support for MOSI idle state configuration
      spi: spi-gpio: Add support for MOSI idle state configuration
      spi: spi-axi-spi-engine: Add support for MOSI idle configuration
      dt-bindings: iio: adc: Add AD4000

 .../devicetree/bindings/iio/adc/adi,ad4000.yaml    | 197 +++++++++++++++++++++
 Documentation/spi/spi-summary.rst                  |  83 +++++++++
 MAINTAINERS                                        |   7 +
 drivers/spi/spi-axi-spi-engine.c                   |  15 +-
 drivers/spi/spi-bitbang.c                          |  24 +++
 drivers/spi/spi-gpio.c                             |  12 +-
 drivers/spi/spi.c                                  |   6 +
 include/linux/spi/spi_bitbang.h                    |   1 +
 include/uapi/linux/spi/spi.h                       |   5 +-
 9 files changed, 344 insertions(+), 6 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/adc/adi,ad4000.yaml
Jonathan Cameron Aug. 3, 2024, 9:56 a.m. UTC | #5
On Wed, 31 Jul 2024 01:04:54 +0100
Mark Brown <broonie@kernel.org> wrote:

> On Fri, Jul 12, 2024 at 04:20:00PM -0300, Marcelo Schmitt wrote:
> > This patch series extends the SPI bitbang, gpio, and spi-engine controllers to
> > support configurable MOSI line idle states.  
> 
> The following changes since commit 8400291e289ee6b2bf9779ff1c83a291501f017b:
> 
>   Linux 6.11-rc1 (2024-07-28 14:19:55 -0700)
> 
> are available in the Git repository at:
> 
>   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git tags/spi-mosi-config
Thanks.

Merged that tag into IIO and applied patches 6 and 7.

Jonathan

> 
> for you to fetch changes up to 96472f18a4affdaff5013a836c48375f1eddb4a4:
> 
>   dt-bindings: iio: adc: Add AD4000 (2024-07-29 01:19:55 +0100)
> 
> ----------------------------------------------------------------
> spi: Support MOSI idle configuration
> 
> Add support for configuring the idle state of the MOSI signal in
> controllers.
> 
> ----------------------------------------------------------------
> Marcelo Schmitt (5):
>       spi: Enable controllers to extend the SPI protocol with MOSI idle configuration
>       spi: bitbang: Implement support for MOSI idle state configuration
>       spi: spi-gpio: Add support for MOSI idle state configuration
>       spi: spi-axi-spi-engine: Add support for MOSI idle configuration
>       dt-bindings: iio: adc: Add AD4000
> 
>  .../devicetree/bindings/iio/adc/adi,ad4000.yaml    | 197 +++++++++++++++++++++
>  Documentation/spi/spi-summary.rst                  |  83 +++++++++
>  MAINTAINERS                                        |   7 +
>  drivers/spi/spi-axi-spi-engine.c                   |  15 +-
>  drivers/spi/spi-bitbang.c                          |  24 +++
>  drivers/spi/spi-gpio.c                             |  12 +-
>  drivers/spi/spi.c                                  |   6 +
>  include/linux/spi/spi_bitbang.h                    |   1 +
>  include/uapi/linux/spi/spi.h                       |   5 +-
>  9 files changed, 344 insertions(+), 6 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/iio/adc/adi,ad4000.yaml