Re: [PATCH 1/2] dt-bindings: thermal: loongson,ls2k-thermal: Fix binding check issues

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

 



On Tue, Oct 31, 2023 at 07:05:49PM +0800, Binbin Zhou wrote:
> Add the missing 'thermal-sensor-cells' property which is required for
> every thermal sensor as it's used when using phandles.
> And add the thermal-sensor.yaml reference.
> 
> Fixes: 72684d99a854 ("thermal: dt-bindings: add loongson-2 thermal")
> Signed-off-by: Binbin Zhou <zhoubinbin@xxxxxxxxxxx>
> ---
>  .../bindings/thermal/loongson,ls2k-thermal.yaml        | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/thermal/loongson,ls2k-thermal.yaml b/Documentation/devicetree/bindings/thermal/loongson,ls2k-thermal.yaml
> index 7538469997f9..b634f57cd011 100644
> --- a/Documentation/devicetree/bindings/thermal/loongson,ls2k-thermal.yaml
> +++ b/Documentation/devicetree/bindings/thermal/loongson,ls2k-thermal.yaml
> @@ -10,6 +10,9 @@ maintainers:
>    - zhanghongchen <zhanghongchen@xxxxxxxxxxx>
>    - Yinbo Zhu <zhuyinbo@xxxxxxxxxxx>
>  
> +allOf:
> +  - $ref: /schemas/thermal/thermal-sensor.yaml#
> +
>  properties:
>    compatible:
>      oneOf:
> @@ -26,12 +29,16 @@ properties:
>    interrupts:
>      maxItems: 1
>  
> +  '#thermal-sensor-cells':
> +    const: 1
> +
>  required:
>    - compatible
>    - reg
>    - interrupts
> +  - '#thermal-sensor-cells'

Why does it need to be a required property now though?
Adding new required properties is technically an ABI break.

Cheers,
Conor.

>  
> -additionalProperties: false
> +unevaluatedProperties: false
>  
>  examples:
>    - |
> @@ -41,4 +48,5 @@ examples:
>          reg = <0x1fe01500 0x30>;
>          interrupt-parent = <&liointc0>;
>          interrupts = <7 IRQ_TYPE_LEVEL_LOW>;
> +        #thermal-sensor-cells = <1>;
>      };
> -- 
> 2.39.3
> 

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux