From: sashiko-bot@kernel.org
To: "Xincheng Ji" <jixincheng@ultrarisc.com>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH v4 7/7] riscv: dts: ultrarisc: Add Milk-V Titan board device tree
Date: Mon, 19 Oct 2026 08:08:29 +0000 [thread overview]
Message-ID: <sashiko-outbox-176776@kernel.org> (raw)
In-Reply-To: <20261019-ultrarisc-dts-v4-7-3979747cda2e@ultrarisc.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] riscv: dts: ultrarisc: deprecated LED label overrides color and function
--
commit b602c792a6efba56c2935012c89e05f8d6efaf40
Author: Jia Wang <wangjia@ultrarisc.com>
riscv: dts: ultrarisc: Add Milk-V Titan board device tree
This commit adds the device tree and pinctrl definitions for the Milk-V
Titan ITX motherboard based on the UltraRISC DP1000 SoC.
Link: https://milkv.io/docs/titan/overview
> diff --git a/arch/riscv/boot/dts/ultrarisc/dp1000-milkv-titan.dts b/arch/riscv/boot/dts/ultrarisc/dp1000-milkv-titan.dts
> new file mode 100644
> index 0000000000000..59edd8157221a
> --- /dev/null
> +++ b/arch/riscv/boot/dts/ultrarisc/dp1000-milkv-titan.dts
> @@ -0,0 +1,203 @@
[ ... ]
> +ðernet {
> + phy-handle = <&phy0>;
> + /*
> + * The PCB does not add RGMII TX or RX clock delays. The DP1000
> + * integration adds fixed delays in both directions.
> + */
> + phy-mode = "rgmii-id";
> +
> + status = "okay";
> +
> + mdio {
> + compatible = "snps,dwmac-mdio";
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + phy0: phy@0 {
> + reg = <0>;
> +
> + leds {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + led@1 {
> + label = "eth-link";
> + reg = <1>;
> + color = <LED_COLOR_ID_YELLOW>;
> + function = LED_FUNCTION_INDICATOR;
> + default-state = "keep";
> + linux,default-trigger = "netdev";
> + };
> +
> + led@2 {
> + label = "eth-activity";
> + reg = <2>;
> + color = <LED_COLOR_ID_GREEN>;
> + function = LED_FUNCTION_ACTIVITY;
> + default-state = "keep";
> + linux,default-trigger = "netdev";
> + };
> + };
> + };
> + };
> +};
[Severity: Medium]
Should the label properties be dropped from led@1 and led@2 here?
When the PHY driver probes phy0, the call chain:
of_phy_leds() ->
of_phy_led() ->
devm_led_classdev_register_ext() ->
led_classdev_register_ext() ->
led_compose_name() ->
led_parse_fwnode_props()
checks for the deprecated label property first in
drivers/leds/led-core.c:led_parse_fwnode_props():
if (fwnode_property_present(fwnode, "label")) {
ret = fwnode_property_read_string(fwnode, "label", &props->label);
if (ret)
dev_err(dev, "Error parsing 'label' property (%d)\n", ret);
return;
}
Because led_parse_fwnode_props() returns early when label is present, the
color and function properties on led@1 and led@2 are never parsed and are
completely ignored at runtime.
In addition, Documentation/devicetree/bindings/leds/common.yaml deprecates
label for new bindings in favor of color and function.
Would it make sense to remove label from both nodes so that the LED core
uses color and function to compose the standard LED names?
完美!
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261019-ultrarisc-dts-v4-0-3979747cda2e@ultrarisc.com?part=7
next prev parent reply other threads:[~2026-10-19 8:08 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-19 7:55 [PATCH v4 0/7] riscv: Add device tree support for UltraRISC DP1000 Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 1/7] dt-bindings: vendor-prefixes: Add shenrongda Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 2/7] dt-bindings: riscv: cpus: Add UltraRISC CP100 compatible Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 3/7] dt-bindings: riscv: Add UltraRISC DP1000 board compatibles Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 4/7] dt-bindings: timer: Add UltraRISC DP1000 CLINT Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 5/7] riscv: dts: ultrarisc: Add initial device tree for UltraRISC DP1000 Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 6/7] riscv: dts: ultrarisc: Add Shenzhen Rongda M0 board device tree Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` [PATCH v4 7/7] riscv: dts: ultrarisc: Add Milk-V Titan " Xincheng Ji
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 7:55 ` Xincheng Ji via B4 Relay
2026-10-19 8:08 ` sashiko-bot [this message]
2026-10-20 1:43 ` Xincheng Ji
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=sashiko-outbox-176776@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jixincheng@ultrarisc.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 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.