From: sashiko-bot@kernel.org
To: "Srinivas Kandagatla" <srinivas.kandagatla@oss.qualcomm.com>
Cc: robh@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH 1/3] dt-bindings: soundwire: qcom: describe multi-master
Date: Fri, 11 Sep 2026 08:38:43 +0000 [thread overview]
Message-ID: <20260911083843.829071F000FF@smtp.kernel.org> (raw)
In-Reply-To: <d7b3d0618f20d18f714217d9604a7c09a3539578.1789114385.git.srinivas.kandagatla@oss.qualcomm.com>
Thank you for your contribution! Sashiko AI review found 4 potential issue(s) to consider:
- [High] Missing `-cells` property definition for `qcom,multi-master-peer` causing dt-schema validation failures.
- [High] Undeclared `qcom,ports-ch-mask` property referenced in conditional block breaks `dt_binding_check`.
- [Medium] Single-master configuration block fails to explicitly forbid multi-master properties, silently allowing incomplete multi-master nodes.
- [Medium] Commit message explicitly lists two properties but the code adds three.
--
commit f97a4adf5082bcb22d04e3fb5cc90da2b743d260
Author: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
dt-bindings: soundwire: qcom: describe multi-master
This commit adds properties to describe multi-master mode in v3.1.0+ Qualcomm
SoundWire IPs. It defines roles and peer relationships for logical buses using
multiple DATA lanes.
> v3.1.0+ Qualcomm SoundWire IPs can be paired to expose one logical
> bus with more than two DATA lanes. Add the two properties that
> describe such a pair:
>
> qcom,multi-master-mode role in the pair ("primary" or "dependent")
> qcom,multi-master-peer <phandle, bus-port-offset> to the other IP
[Severity: Medium]
This isn't a bug, but there is a slight inconsistency in the commit message.
It mentions adding two properties, while the patch actually introduces three
properties, adding num-lanes as well. Should the commit message be updated to
reflect the third property?
> diff --git a/Documentation/devicetree/bindings/soundwire/qcom,soundwire.yaml b/Documentation/devicetree/bindings/soundwire/qcom,soundwire.yaml
> index 8e6973fa229c9..34ce8caec0a86 100644
> --- a/Documentation/devicetree/bindings/soundwire/qcom,soundwire.yaml
> +++ b/Documentation/devicetree/bindings/soundwire/qcom,soundwire.yaml
[ ... ]
> + qcom,multi-master-peer:
> + description:
> + Peers in multi-master mode. Each entry is a
> + <peer-phandle, bus-port-offset> pair. Peer N's DPn slots
> + 1, 2, 3, ... occupy bus ports (offset+1), (offset+2), ...
> + $ref: /schemas/types.yaml#/definitions/phandle-array
> + items:
> + items:
> + - description: peer phandle
> + - description: bus port offset (last primary-local port)
> + minItems: 1
[Severity: High]
Because qcom,multi-master-peer is defined as a phandle-array, doesn't the
referenced target node need a corresponding #qcom,multi-master-peer-cells
property for dt-schema to parse the arguments?
Since the schema uses unevaluatedProperties: false and does not define
#qcom,multi-master-peer-cells globally, it creates a situation where adding
the cells property fails schema validation, but omitting it causes dtbs_check
to fail. Can this be resolved by declaring the -cells property in this schema?
[ ... ]
> allOf:
> - $ref: soundwire-controller.yaml#
>
> + # Single-master (no qcom,multi-master-mode): needs port config.
> + - if:
> + not:
> + required:
> + - qcom,multi-master-mode
> + then:
> + required:
> + - '#sound-dai-cells'
> + - qcom,ports-offset1
> + - qcom,ports-offset2
[Severity: Medium]
If a user writes an incomplete multi-master device tree node and forgets to
include the qcom,multi-master-mode property, will it silently pass validation
here as a single-master configuration?
Since qcom,multi-master-peer and num-lanes are globally declared,
unevaluatedProperties: false won't catch them. Would it be safer to explicitly
forbid the multi-master properties in this single-master block by setting
qcom,multi-master-peer: false and num-lanes: false?
[ ... ]
> + # Multi-master dependent: contributes DATA lanes
> + - if:
> + properties:
> + qcom,multi-master-mode:
> + const: dependent
> + required:
> + - qcom,multi-master-mode
> + then:
> + properties:
> + compatible:
> + contains:
> + const: qcom,soundwire-v3.1.0
> + '#sound-dai-cells': false
> + qcom,din-ports: false
> + qcom,dout-ports: false
> + qcom,ports-word-length: false
> + qcom,ports-sinterval-low: false
> + qcom,ports-sinterval: false
> + qcom,ports-offset1: false
> + qcom,ports-offset2: false
> + qcom,ports-lane-control: false
> + qcom,ports-block-pack-mode: false
> + qcom,ports-hstart: false
> + qcom,ports-hstop: false
> + qcom,ports-block-group-count: false
> + qcom,ports-ch-mask: false
[Severity: High]
Does qcom,ports-ch-mask need to be globally declared in the top-level
properties block?
The dtschema meta-schema requires all properties evaluated in
if/then/properties blocks to be declared globally, and qcom,ports-ch-mask does
not seem to be present in this file or inherited from soundwire-controller.yaml.
Won't this cause make dt_binding_check to fail with an undeclared property
error?
--
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1789114385.git.srinivas.kandagatla@oss.qualcomm.com?part=1
next prev parent reply other threads:[~2026-09-11 8:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-11 8:21 [PATCH 0/3] soundwire: qcom: add multi-master support Srinivas Kandagatla
2026-09-11 8:21 ` [PATCH 1/3] dt-bindings: soundwire: qcom: describe multi-master Srinivas Kandagatla
2026-09-11 8:38 ` sashiko-bot [this message]
2026-09-11 8:21 ` [PATCH 2/3] soundwire: qcom: add multi-master support Srinivas Kandagatla
2026-09-11 8:43 ` sashiko-bot
2026-09-11 8:21 ` [PATCH 3/3] soundwire: qcom: program MM_SYNC for multi-master Srinivas Kandagatla
2026-09-11 8:36 ` 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=20260911083843.829071F000FF@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=srinivas.kandagatla@oss.qualcomm.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.