Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Junzhong Pan" <panjunzhong@linux.spacemit.com>
Cc: conor+dt@kernel.org, robh@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v3 6/8] riscv: dts: spacemit: enable USB2.0 controllers on BananaPi F3
Date: Sun, 27 Sep 2026 11:49:33 +0000	[thread overview]
Message-ID: <20260927114933.ABD2B1F000FF@smtp.kernel.org> (raw)
In-Reply-To: <20260927-b4-spacemit-k1-usb2-v3-6-ce7095896039@linux.spacemit.com>

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Low] usb: missing usb-role-switch property for standard sysfs ABI
- [Low] dts: board file nodes not sorted alphabetically
--

commit 44aeea968dbe19365572cdf8df737d1b44de83c9
Author: Junzhong Pan <panjunzhong@linux.spacemit.com>

riscv: dts: spacemit: enable USB2.0 controllers on BananaPi F3

This commit enables the usb2_0 and usb2_1 nodes on the BananaPi F3 board.
It intends to allow role switching via sysfs for the Type-C port and 
support cellular modules on the Mini PCIe slot.

> diff --git a/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts
> index 58035d886bf67..ce36250e2debd 100644
> --- a/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts
> +++ b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts

[ ... ]

> @@ -383,10 +383,26 @@ &uart0 {
>  	status = "okay";
>  };
>  
> +&usbphy0 {
> +	status = "okay";
> +};
> +
> +&usbphy1 {
> +	status = "okay";
> +};
> +
>  &usbphy2 {
>  	status = "okay";
>  };
>  
> +&usb2_0 {

[Severity: Low]
Are the device tree board file nodes sorted alphabetically here?

Device tree board files mandate that node references be sorted alphabetically
by label to prevent merge conflicts. Based on ASCII sorting, 2 (0x32) comes
before p (0x70), so &usb2_0 and &usb2_1 should precede the &usbphy* nodes.

[Severity: Low]
Does this node omit the usb-role-switch property required to expose the
standard sysfs ABI?

The commit message notes that the user can switch the role in sysfs.
However, by omitting the usb-role-switch property, the driver defaults
to exposing its legacy, non-standard driver-specific sysfs attribute
(/sys/devices/platform/.../role) rather than registering with the
standard USB role switch framework (/sys/class/usb_role/).

Would it be better to include the usb-role-switch property so that
modern userspace tools can use the expected standard UAPI?

> +	status = "okay";
> +};
> +
> +&usb2_1 {
> +	status = "okay";
> +};
> +
>  &usb_dwc3 {
>  	dr_mode = "host";
>  	#address-cells = <1>;

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260927-b4-spacemit-k1-usb2-v3-0-ce7095896039@linux.spacemit.com?part=6

  reply	other threads:[~2026-09-27 11:49 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-27 11:40 [PATCH v3 0/8] Add SpacemiT K1 USB2.0 controllers support Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 1/8] dt-bindings: usb: ci-hdrc-usb2: add spacemit,k1-usb2 compatible Junzhong Pan
2026-10-06 15:09   ` Krzysztof Kozlowski
2026-09-27 11:40 ` [PATCH v3 2/8] usb: chipidea: usb2: use devm_clk_get_optional_enabled() Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 3/8] usb: chipidea: usb2: add optional reset support Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 4/8] usb: chipidea: usb2: add SpacemiT K1 support Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 5/8] riscv: dts: spacemit: add USB2.0 controller nodes for K1 Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 6/8] riscv: dts: spacemit: enable USB2.0 controllers on BananaPi F3 Junzhong Pan
2026-09-27 11:49   ` sashiko-bot [this message]
2026-09-28  1:50     ` Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 7/8] riscv: dts: spacemit: enable USB2.0 controllers on OrangePi RV2 Junzhong Pan
2026-09-27 11:40 ` [PATCH v3 8/8] riscv: defconfig: enable ChipIdea USB controller support Junzhong Pan
2026-09-28 22:58 ` [PATCH v3 0/8] Add SpacemiT K1 USB2.0 controllers support Yixun Lan
2026-09-28 23:03 ` Yixun Lan
2026-10-06 15:10   ` Krzysztof Kozlowski

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=20260927114933.ABD2B1F000FF@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=panjunzhong@linux.spacemit.com \
    --cc=robh@kernel.org \
    --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