Linux Hardware Monitor development
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Marius Cristea" <marius.cristea@microchip.com>
Cc: linux-hwmon@vger.kernel.org
Subject: Re: [PATCH v10 1/2] dt-bindings: hwmon: temperature: add support for EMC1812
Date: Wed, 29 Apr 2026 13:24:57 +0000	[thread overview]
Message-ID: <20260429132458.920C8C2BCB8@smtp.kernel.org> (raw)
In-Reply-To: <20260429-hw_mon-emc1812-v10-1-a8ca1d779502@microchip.com>

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Low] The restriction for channel 4 on the `microchip,emc1814` compatible uses `properties: channel@4: false`, which violates the dt-schema meta-schema and will cause `dt_binding_check` to fail.
- [Low] The device tree example uses an undefined phandle label `<&vdd>`, which will cause `dt_binding_check` to fail with a `dtc` compilation error.
--

commit 6d9c42d650361ba383a1097abf05acff51bac85d
Author: Marius Cristea <marius.cristea@microchip.com>

dt-bindings: hwmon: temperature: add support for EMC1812

This commit adds the devicetree schema for the Microchip EMC1812/13/14/15/33
Multichannel Low-Voltage Remote Diode Sensor Family. It specifies the properties
for each hardware variant, including differences in channel count and features
like anti-parallel diodes.

> diff --git a/Documentation/devicetree/bindings/hwmon/microchip,emc1812.yaml b/Documentation/devicetree/bindings/hwmon/microchip,emc1812.yaml
> new file mode 100644
> index 000000000000..1a273621db82
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/hwmon/microchip,emc1812.yaml
[ ... ]
> +  # EMC1814: 1 Internal, 3 External Channels, Supports APD,
> +  # parasitic-res-on-channel1-2: on both channel 1 & 2
> +  # parasitic-res-on-channel3-4: for channel 3
> +  - if:
> +      properties:
> +        compatible:
> +          const: microchip,emc1814
> +    then:
> +      properties:
> +        channel@4: false

Should this restriction be placed under patternProperties instead of
properties?

In dt-schema, keys under properties must not contain the @ symbol used for
device tree unit addresses. Using channel@4: false under properties will result
in a meta-schema validation regression during make dt_binding_check.

To properly forbid the node, it could be written under patternProperties,
such as "^channel@4$": false.

[ ... ]
> +examples:
> +  - |
> +    i2c {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        temperature-sensor@4c {
> +            compatible = "microchip,emc1813";
> +            reg = <0x4c>;
> +
> +            #address-cells = <1>;
> +            #size-cells = <0>;
> +
> +            microchip,parasitic-res-on-channel1-2;
> +
> +            vdd-supply = <&vdd>;

Does this example need a node defining the vdd label?

The assignment uses the phandle <&vdd>, but the label is not defined anywhere in
the example block. When make dt_binding_check extracts and compiles the
generated DTS, this will result in a dtc compilation regression because the
phandle cannot be resolved.

Adding a dummy regulator node with the vdd: label would fix this.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260429-hw_mon-emc1812-v10-0-a8ca1d779502@microchip.com?part=1

  reply	other threads:[~2026-04-29 13:24 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-29 12:58 [PATCH v10 0/2] Add support for Microchip EMC1812 Marius Cristea
2026-04-29 12:58 ` [PATCH v10 1/2] dt-bindings: hwmon: temperature: add support for EMC1812 Marius Cristea
2026-04-29 13:24   ` sashiko-bot [this message]
2026-05-06 15:34     ` Rob Herring
2026-05-06 15:37   ` Rob Herring (Arm)
2026-04-29 12:58 ` [PATCH v10 2/2] " Marius Cristea
2026-04-29 18:35   ` sashiko-bot
2026-04-30 23:33     ` Guenter Roeck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260429132458.920C8C2BCB8@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=marius.cristea@microchip.com \
    --cc=sashiko@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox