A new compatible is added to reflect the specialized version of the HDL
that is not covered by the IIO backend paradigm: We use the parallel
interface to write the ADC's registers, and accessing this interface
requires to use ADI_AXI_REG_CONFIG_RD,ADI_AXI_REG_CONFIG_WR and
ADI_AXI_REG_CONFIG_CTRL in a custom fashion.
Signed-off-by: Guillaume Stols <gstols@baylibre.com>
---
Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
index e1f450b80db2..43bc0440c678 100644
--- a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
@@ -17,13 +17,20 @@ description: |
interface for the actual ADC, while this IP core will interface
to the data-lines of the ADC and handle the streaming of data into
memory via DMA.
+ In some cases, the AXI ADC interface is used to perform specialized
+ operation to a particular ADC, e.g access the physical bus through
+ some special register to write ADC registers.
+ In this case, a different compatible is used, and the driver behaves
+ slightly differently according to the special needs.
https://wiki.analog.com/resources/fpga/docs/axi_adc_ip
+ http://analogdevicesinc.github.io/hdl/library/axi_ad7606x/index.html
properties:
compatible:
enum:
- adi,axi-adc-10.0.a
+ - adi,axi-ad7606x
reg:
maxItems: 1
--
2.34.1
On 11/21/24 4:18 AM, Guillaume Stols wrote:
> A new compatible is added to reflect the specialized version of the HDL
> that is not covered by the IIO backend paradigm: We use the parallel
It still is being used as an IIO backend, so I would leave out the
phrase "that is not covered by the IIO backend paradigm".
> interface to write the ADC's registers, and accessing this interface
> requires to use ADI_AXI_REG_CONFIG_RD,ADI_AXI_REG_CONFIG_WR and
> ADI_AXI_REG_CONFIG_CTRL in a custom fashion.
>
> Signed-off-by: Guillaume Stols <gstols@baylibre.com>
> ---
> Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
> index e1f450b80db2..43bc0440c678 100644
> --- a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
> +++ b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml
> @@ -17,13 +17,20 @@ description: |
> interface for the actual ADC, while this IP core will interface
> to the data-lines of the ADC and handle the streaming of data into
> memory via DMA.
> + In some cases, the AXI ADC interface is used to perform specialized
> + operation to a particular ADC, e.g access the physical bus through
> + some special register to write ADC registers.
> + In this case, a different compatible is used, and the driver behaves
Quick, delete the word "driver" before Krzysztof sees it. :-p
Joking aside, the devicetree only describes how things are wired up,
it doesn't care how the driver uses the information. So we avoid
mentioning anything about drivers in the bindings.
> + slightly differently according to the special needs.
>
> https://wiki.analog.com/resources/fpga/docs/axi_adc_ip
> + http://analogdevicesinc.github.io/hdl/library/axi_ad7606x/index.html
>
> properties:
> compatible:
> enum:
> - adi,axi-adc-10.0.a
> + - adi,axi-ad7606x
>
> reg:
> maxItems: 1
>
Since this new compatible also provides a bus in addition to the io-backend,
I think we need some additional bindings to describe the child nodes for the
ADC devices attached to the bus.
I don't think there are any generic parallel-controller bindings like there
are for SPI controllers, so we can't $ref: /schemas/spi/spi-controller.yaml#
like we did for the similar case of adi,axi-ad3552r recently.
But maybe something like this:
properties:
...
"#address-cells":
const: 1
"#size-cells":
const: 0
patternProperties:
"^adc@[0-9a-f]+$":
type: object
additionalProperties: true
properties:
reg:
maxItems: 1
required:
- compatible
- reg
On Thu, Nov 21, 2024 at 10:57:44AM -0600, David Lechner wrote: > On 11/21/24 4:18 AM, Guillaume Stols wrote: > > A new compatible is added to reflect the specialized version of the HDL > > that is not covered by the IIO backend paradigm: We use the parallel > > It still is being used as an IIO backend, so I would leave out the > phrase "that is not covered by the IIO backend paradigm". > > > interface to write the ADC's registers, and accessing this interface > > requires to use ADI_AXI_REG_CONFIG_RD,ADI_AXI_REG_CONFIG_WR and > > ADI_AXI_REG_CONFIG_CTRL in a custom fashion. > > > > Signed-off-by: Guillaume Stols <gstols@baylibre.com> > > --- > > Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml | 7 +++++++ > > 1 file changed, 7 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > index e1f450b80db2..43bc0440c678 100644 > > --- a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > +++ b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > @@ -17,13 +17,20 @@ description: | > > interface for the actual ADC, while this IP core will interface > > to the data-lines of the ADC and handle the streaming of data into > > memory via DMA. > > + In some cases, the AXI ADC interface is used to perform specialized > > + operation to a particular ADC, e.g access the physical bus through > > + some special register to write ADC registers. > > + In this case, a different compatible is used, and the driver behaves > > Quick, delete the word "driver" before Krzysztof sees it. :-p And also perhaps worth mentioning under the --- line that the x in the compatible is not a wildcard, for similar reasons ;)
On Thu, 21 Nov 2024 19:53:53 +0000 Conor Dooley <conor@kernel.org> wrote: > On Thu, Nov 21, 2024 at 10:57:44AM -0600, David Lechner wrote: > > On 11/21/24 4:18 AM, Guillaume Stols wrote: > > > A new compatible is added to reflect the specialized version of the HDL > > > that is not covered by the IIO backend paradigm: We use the parallel > > > > It still is being used as an IIO backend, so I would leave out the > > phrase "that is not covered by the IIO backend paradigm". > > > > > interface to write the ADC's registers, and accessing this interface > > > requires to use ADI_AXI_REG_CONFIG_RD,ADI_AXI_REG_CONFIG_WR and > > > ADI_AXI_REG_CONFIG_CTRL in a custom fashion. > > > > > > Signed-off-by: Guillaume Stols <gstols@baylibre.com> > > > --- > > > Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml | 7 +++++++ > > > 1 file changed, 7 insertions(+) > > > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > index e1f450b80db2..43bc0440c678 100644 > > > --- a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > +++ b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > @@ -17,13 +17,20 @@ description: | > > > interface for the actual ADC, while this IP core will interface > > > to the data-lines of the ADC and handle the streaming of data into > > > memory via DMA. > > > + In some cases, the AXI ADC interface is used to perform specialized > > > + operation to a particular ADC, e.g access the physical bus through > > > + some special register to write ADC registers. > > > + In this case, a different compatible is used, and the driver behaves > > > > Quick, delete the word "driver" before Krzysztof sees it. :-p > > And also perhaps worth mentioning under the --- line that the x in the > compatible is not a wildcard, for similar reasons ;) Well it is, just one that is used for the IP naming to cover all the different ADCs it works with. "The AXI AD7606x IP core can be used to interface the AD7606B, AD7606C-16, AD7606C-18, AD7605-4, AD7606, AD7606-6, AD7606-4, AD7607, AD7608 and AD7609 devices using an FPGA." Given that's what ADI calls the IP though we are stuck with it - however 'wrong' they may be :) But agreed, something to call out to keep me away from the x as well! Jonathan
On Tue, Nov 26, 2024 at 05:59:31PM +0000, Jonathan Cameron wrote: > On Thu, 21 Nov 2024 19:53:53 +0000 > Conor Dooley <conor@kernel.org> wrote: > > > On Thu, Nov 21, 2024 at 10:57:44AM -0600, David Lechner wrote: > > > On 11/21/24 4:18 AM, Guillaume Stols wrote: > > > > A new compatible is added to reflect the specialized version of the HDL > > > > that is not covered by the IIO backend paradigm: We use the parallel > > > > > > It still is being used as an IIO backend, so I would leave out the > > > phrase "that is not covered by the IIO backend paradigm". > > > > > > > interface to write the ADC's registers, and accessing this interface > > > > requires to use ADI_AXI_REG_CONFIG_RD,ADI_AXI_REG_CONFIG_WR and > > > > ADI_AXI_REG_CONFIG_CTRL in a custom fashion. > > > > > > > > Signed-off-by: Guillaume Stols <gstols@baylibre.com> > > > > --- > > > > Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml | 7 +++++++ > > > > 1 file changed, 7 insertions(+) > > > > > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > > index e1f450b80db2..43bc0440c678 100644 > > > > --- a/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > > +++ b/Documentation/devicetree/bindings/iio/adc/adi,axi-adc.yaml > > > > @@ -17,13 +17,20 @@ description: | > > > > interface for the actual ADC, while this IP core will interface > > > > to the data-lines of the ADC and handle the streaming of data into > > > > memory via DMA. > > > > + In some cases, the AXI ADC interface is used to perform specialized > > > > + operation to a particular ADC, e.g access the physical bus through > > > > + some special register to write ADC registers. > > > > + In this case, a different compatible is used, and the driver behaves > > > > > > Quick, delete the word "driver" before Krzysztof sees it. :-p > > > > And also perhaps worth mentioning under the --- line that the x in the > > compatible is not a wildcard, for similar reasons ;) > > Well it is, just one that is used for the IP naming to cover all > the different ADCs it works with. In "our" terms, when talking about bindings, is not a wildcard. As you say below, the x refers to a specific IP that works with several different ADCs, rather than attempting to use a single compatible for multiple different IPs. > "The AXI AD7606x IP core can be used to interface the AD7606B, AD7606C-16, > AD7606C-18, AD7605-4, AD7606, AD7606-6, AD7606-4, AD7607, AD7608 and AD7609 devices using an FPGA." > > Given that's what ADI calls the IP though we are stuck with it - however > 'wrong' they may be :) > > But agreed, something to call out to keep me away from the x as well! > > Jonathan >
© 2016 - 2026 Red Hat, Inc.