From: sashiko-bot@kernel.org
To: "Salih Erim" <salih.erim@amd.com>
Cc: conor+dt@kernel.org, robh@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v4 1/5] dt-bindings: iio: adc: add xlnx,versal-sysmon binding
Date: Sat, 06 Jun 2026 05:27:36 +0000 [thread overview]
Message-ID: <20260606052737.438441F00893@smtp.kernel.org> (raw)
In-Reply-To: <20260606051707.535281-2-salih.erim@amd.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] Schema Validation Flaw: Ineffective `minimum` and `maximum` constraints on `reg` arrays.
--
commit 68825d18816914117a9f77e82be41b25ec550f42
Author: Salih Erim <salih.erim@amd.com>
dt-bindings: iio: adc: add xlnx,versal-sysmon binding
Add devicetree binding for the AMD/Xilinx Versal System Monitor (SysMon).
The hardware supports up to 160 supply voltage measurement points and up to
64 temperature satellites. The channels are described as child nodes under
container nodes.
> diff --git a/Documentation/devicetree/bindings/iio/adc/xlnx,versal-sysmon.yaml b/Documentation/devicetree/bindings/iio/adc/xlnx,versal-sysmon.yaml
> new file mode 100644
> index 0000000000000..1ad58e3d61631
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/xlnx,versal-sysmon.yaml
[ ... ]
> + voltage-channels:
> + type: object
> + description:
> + Container for voltage measurement channels.
[ ... ]
> + patternProperties:
> + '^channel@([0-9a-f]|[1-9][0-9a-f])$':
> + $ref: adc.yaml
[ ... ]
> + properties:
> + reg:
> + minimum: 0
> + maximum: 159
[Severity: Low]
Because the reg property is evaluated as an array in dt-schema, applying
minimum and maximum directly to it will be silently ignored by the JSON schema
validator.
Should these constraints be placed under an items array, or can they be
dropped entirely since the patternProperties regex already implicitly restricts
the range?
> + description:
> + Voltage measurement register index assigned by the hardware
> + design tool.
> +
> + required:
> + - reg
[ ... ]
> + temperature-channels:
> + type: object
> + description:
> + Container for temperature satellite measurement channels.
[ ... ]
> + patternProperties:
> + '^channel@([1-9a-f]|[1-3][0-9a-f]|40)$':
> + $ref: adc.yaml
[ ... ]
> + properties:
> + reg:
> + minimum: 1
> + maximum: 64
[Severity: Low]
Similarly here, are these constraints ineffective because JSON schema ignores
numeric constraints on non-numeric types like the reg array?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260606051707.535281-1-salih.erim@amd.com?part=1
next prev parent reply other threads:[~2026-06-06 5:27 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-06 5:17 [PATCH v4 0/5] iio: adc: add AMD/Xilinx Versal SysMon driver Salih Erim
2026-06-06 5:17 ` [PATCH v4 1/5] dt-bindings: iio: adc: add xlnx,versal-sysmon binding Salih Erim
2026-06-06 5:27 ` sashiko-bot [this message]
2026-06-06 5:17 ` [PATCH v4 2/5] iio: adc: add Versal SysMon driver Salih Erim
2026-06-06 5:17 ` [PATCH v4 3/5] iio: adc: versal-sysmon: add I2C driver Salih Erim
2026-06-06 5:27 ` sashiko-bot
2026-06-06 5:17 ` [PATCH v4 4/5] iio: adc: versal-sysmon: add threshold event support Salih Erim
2026-06-06 5:31 ` sashiko-bot
2026-06-06 5:17 ` [PATCH v4 5/5] iio: adc: versal-sysmon: add oversampling support Salih Erim
2026-06-06 5:30 ` sashiko-bot
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=20260606052737.438441F00893@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=robh@kernel.org \
--cc=salih.erim@amd.com \
--cc=sashiko-reviews@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