lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 27 Jun 2023 08:31:47 +0200
From:   Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To:     Seven Lee <wtli@...oton.com>, broonie@...nel.org
Cc:     lgirdwood@...il.com, robh+dt@...nel.org,
        krzysztof.kozlowski+dt@...aro.org, conor+dt@...nel.org,
        alsa-devel@...a-project.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org, YHCHuang@...oton.com,
        KCHSU0@...oton.com, CTLIN0@...oton.com, SJLIN0@...oton.com,
        scott6986@...il.com, supercraig0719@...il.com, dardar923@...il.com
Subject: Re: [PATCH] ASoC: dt-bindings: nau8821: Convert to dtschema

On 26/06/2023 12:46, Seven Lee wrote:
> Convert the NAU8821 audio CODEC bindings to DT schema.
> 
> Signed-off-by: Seven Lee <wtli@...oton.com>
> ---

Thank you for your patch. There is something to discuss/improve.

> +
> +  nuvoton,jkdet-pull-up:
> +    description: Pull-up JKDET pin. If set then JKDET pin is pull up,
> +      otherwise pull down.
> +    type: boolean
> +
> +  nuvoton,jkdet-polarity:
> +    description: JKDET pin polarity.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    enum:
> +      - 0 # active high
> +      - 1 # active low
> +    default: 1
> +
> +  nuvoton,micbias-voltage:
> +    description: MICBIAS output level select.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    enum:
> +      - 0 # VDDA
> +      - 1 # VDDA * 1
> +      - 2 # VDDA * 1.1
> +      - 3 # VDDA * 1.2
> +      - 4 # VDDA * 1.3
> +      - 5 # VDDA * 1.4
> +      - 6 # VDDA * 1.53
> +      - 7 # VDDA * 1.53
> +    default: 6
> +
> +  nuvoton,vref-impedance:
> +    description: VMID Tie-off impedance select.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    enum:
> +      - 0 # open(default)

Drop "(default)"

> +      - 1 # 25KOhms
> +      - 2 # 125KOhms
> +      - 3 # 2.5KOhms
> +    default: 2

You wrote that default is 0

> +
> +  nuvoton,jack-insert-debounce:
> +    description: number from 0 to 7 that sets debounce time to 2^(n+2)ms.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    maximum: 7
> +    default: 7
> +
> +  nuvoton,jack-eject-debounce:
> +    description: number from 0 to 7 that sets debounce time to 2^(n+2)ms.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    maximum: 7
> +    default: 0
> +
> +  nuvoton,dmic-clk-threshold:
> +    description: DMIC clock speed expected value. Unit is Hz.
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    default: 3072000
> +

You miss nuvoton,key_enable. If this is intentional, mention and shortly
explain deviations from pure conversion in the commit msg.

> +  '#sound-dai-cells':
> +    const: 0
> +
> +required:
> +  - compatible
> +  - reg
> +
> +unevaluatedProperties: false
> +
> +examples:
> +  - |
> +    #include <dt-bindings/gpio/gpio.h>
> +    #include <dt-bindings/interrupt-controller/irq.h>
> +    i2c {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +        codec@1b {
> +            #sound-dai-cells = <0>;
> +            compatible = "nuvoton,nau8821";
> +            reg = <0x1b>;

compatible is first property, reg is second. Therefore put
sound-dai-cells somewhere further.



Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ