From: Paolo Abeni <pabeni@redhat.com>
To: David Yang <mmyangfl@gmail.com>, netdev@vger.kernel.org
Cc: Andrew Lunn <andrew@lunn.ch>, Vladimir Oltean <olteanv@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next v9 3/3] net: dsa: motorcomm: Add LED support
Date: Thu, 30 Jul 2026 12:37:58 +0200 [thread overview]
Message-ID: <08ff5f82-c7cf-4d6b-97bc-debe2957331a@redhat.com> (raw)
In-Reply-To: <20260726162731.1005803-4-mmyangfl@gmail.com>
On 7/26/26 6:27 PM, David Yang wrote:
> +int yt921x_leds_setup(struct yt921x_priv *priv)
> +{
> + struct device *dev = to_device(priv);
> + struct dsa_switch *ds = &priv->ds;
> + struct dsa_port *dp;
> + u32 inv_ctrl = 0;
> + u32 inv_mask = 0;
> + u32 ctrl;
> + u32 mask;
> + int res;
> +
> + dsa_switch_for_each_port(dp, ds) {
> + int port = dp->index;
> +
> + if (!dp->dn)
> + continue;
> +
> + res = yt921x_leds_setup_port(priv, port, &inv_mask, &inv_ctrl);
> + if (res)
> + dev_warn(dev, "Failed to setup LEDs for port %d: %d\n",
> + port, res);
> + }
Sashiko noted that at this point the leds are already exposed to the
user-space and settings can be applied before the following take place.
Also please note net-next commit c82ff94592fb
/P
next prev parent reply other threads:[~2026-07-30 10:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-26 16:27 [PATCH net-next v9 0/3] net: dsa: motorcomm: Add LED support David Yang
2026-07-26 16:27 ` [PATCH net-next v9 1/3] net: dsa: motorcomm: Move to subdirectory David Yang
2026-07-26 16:27 ` [PATCH net-next v9 2/3] net: dsa: motorcomm: Split SMI module David Yang
2026-07-26 16:27 ` [PATCH net-next v9 3/3] net: dsa: motorcomm: Add LED support David Yang
2026-07-30 10:37 ` Paolo Abeni [this message]
2026-07-30 10:42 ` [PATCH net-next v9 0/3] " Paolo Abeni
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=08ff5f82-c7cf-4d6b-97bc-debe2957331a@redhat.com \
--to=pabeni@redhat.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mmyangfl@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox