Re: [PATCH v2 1/9] dt-bindings: renesas,sh-msiof: Add MSIOF I2S Sound support

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

 



On Fri, Apr 11, 2025 at 01:03:27AM +0000, Kuninori Morimoto wrote:
> Renesas MSIOF (Clock-Synchronized Serial Interface with FIFO) can work as
> both SPI and I2S. MSIOF-I2S will use Audio Graph Card/Card2 driver which
> uses Of-Graph in DT.
> 
> MSIOF-SPI/I2S are using same DT compatible properties.
> MSIOF-I2S         uses Of-Graph for Audio-Graph-Card/Card2,
> MSIOF-SPI doesn't use  Of-Graph.
> 
> Adds schema for MSIOF-I2S (= Sound).
> Because MSIOF is no longer SPI specific device, remove spi specific schema
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx>
> ---
>  .../bindings/spi/renesas,sh-msiof.yaml        | 23 +++++++++++++------
>  1 file changed, 16 insertions(+), 7 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/spi/renesas,sh-msiof.yaml b/Documentation/devicetree/bindings/spi/renesas,sh-msiof.yaml
> index 49649fc3f95a..9f73120e97c1 100644
> --- a/Documentation/devicetree/bindings/spi/renesas,sh-msiof.yaml
> +++ b/Documentation/devicetree/bindings/spi/renesas,sh-msiof.yaml
> @@ -4,14 +4,11 @@
>  $id: http://devicetree.org/schemas/spi/renesas,sh-msiof.yaml#
>  $schema: http://devicetree.org/meta-schemas/core.yaml#
>  
> -title: Renesas MSIOF SPI controller
> +title: Renesas MSIOF SPI / I2S controller
>  
>  maintainers:
>    - Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
>  
> -allOf:
> -  - $ref: spi-controller.yaml#

if:
  properties:
    $nodename:
      pattern: '^spi@'
then:
  $ref: spi-controller.yaml#

Or just always use 'spi' node name even if used for i2s.

> -
>  properties:
>    compatible:
>      oneOf:
> @@ -70,6 +67,12 @@ properties:
>            - description: CPU registers
>            - description: DMA engine registers
>  
> +  "#address-cells":
> +    enum: [0, 1]
> +
> +  "#size-cells":
> +    const: 0
> +

Then drop these.

>    interrupts:
>      maxItems: 1
>  
> @@ -146,14 +149,20 @@ properties:
>      $ref: /schemas/types.yaml#/definitions/uint32
>      default: 64
>  
> +  # for MSIOF-I2S
> +  port:
> +    $ref: ../sound/audio-graph-port.yaml#/definitions/port-base
> +    unevaluatedProperties: false
> +    patternProperties:
> +      "^endpoint(@[0-9a-f]+)?":
> +        $ref: audio-graph-port.yaml#/definitions/endpoint-base

The correct way is:

port:
  $ref: audio-graph-port.yaml#
  unevaluatedProperties: false

> +
>  required:
>    - compatible
>    - reg
>    - interrupts
>    - clocks
>    - power-domains
> -  - '#address-cells'
> -  - '#size-cells'
>  
>  if:
>    not:
> @@ -173,7 +182,7 @@ examples:
>      #include <dt-bindings/interrupt-controller/arm-gic.h>
>      #include <dt-bindings/power/r8a7791-sysc.h>
>  
> -    msiof0: spi@e6e20000 {
> +    msiof0: serial-engine@e6e20000 {
>          compatible = "renesas,msiof-r8a7791", "renesas,rcar-gen2-msiof";
>          reg = <0xe6e20000 0x0064>;
>          interrupts = <GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>;
> -- 
> 2.43.0
> 




[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux