From: <Parthiban.Veerasooran@microchip.com>
To: <prabhakar.csengg@gmail.com>, <andrew@lunn.ch>,
<hkallweit1@gmail.com>, <linux@armlinux.org.uk>,
<davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
<pabeni@redhat.com>, <Horatiu.Vultur@microchip.com>,
<geert+renesas@glider.be>, <vladimir.oltean@nxp.com>,
<vadim.fedorenko@linux.dev>
Cc: <netdev@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<linux-renesas-soc@vger.kernel.org>, <biju.das.jz@bp.renesas.com>,
<fabrizio.castro.jz@renesas.com>,
<prabhakar.mahadev-lad.rj@bp.renesas.com>
Subject: Re: [PATCH net-next v3 2/3] net: phy: mscc: Consolidate probe functions into a common helper
Date: Tue, 11 Nov 2025 09:50:45 +0000 [thread overview]
Message-ID: <40e744b5-cc17-4b33-8d0b-1e9987eece7c@microchip.com> (raw)
In-Reply-To: <20251111091047.831005-3-prabhakar.mahadev-lad.rj@bp.renesas.com>
Hi,
On 11/11/25 2:40 pm, Prabhakar wrote:
> +static int vsc85xx_probe_common(struct phy_device *phydev,
> + const struct vsc85xx_probe_config *cfg,
> + const u32 *default_led_mode)
> +{
> + struct vsc8531_private *vsc8531;
> + int ret;
> +
> + vsc8531 = devm_kzalloc(&phydev->mdio.dev, sizeof(*vsc8531), GFP_KERNEL);
> + if (!vsc8531)
> + return -ENOMEM;
> +
> + phydev->priv = vsc8531;
> +
> + /* Check rate magic if needed (only for non-package PHYs) */
> + if (cfg->check_rate_magic) {
> + ret = vsc85xx_edge_rate_magic_get(phydev);
> + if (ret < 0)
> + return ret;
> +
> + vsc8531->rate_magic = ret;
> + }
> +
> + /* Set up package if needed */
> + if (cfg->use_package) {
> + vsc8584_get_base_addr(phydev);
> + devm_phy_package_join(&phydev->mdio.dev, phydev,
> + vsc8531->base_addr, cfg->shared_size);
Don't you need to check the return value here?
Best regards,
Parthiban V
> + }
> +
> + /* Configure LED settings */
> + vsc8531->nleds = cfg->nleds;
> + vsc8531->supp_led_modes = cfg->supp_led_modes;
next prev parent reply other threads:[~2025-11-11 9:50 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-11 9:10 [PATCH net-next v3 0/3] net: phy: mscc: Add support for PHY LED control Prabhakar
2025-11-11 9:10 ` [PATCH net-next v3 1/3] net: phy: mscc: Simplify LED mode update using phy_modify() Prabhakar
2025-11-11 9:10 ` [PATCH net-next v3 2/3] net: phy: mscc: Consolidate probe functions into a common helper Prabhakar
2025-11-11 9:50 ` Parthiban.Veerasooran [this message]
2025-11-11 9:56 ` Lad, Prabhakar
2025-11-11 13:25 ` Andrew Lunn
2025-11-11 15:25 ` Lad, Prabhakar
2025-11-11 13:23 ` Andrew Lunn
2025-11-12 8:49 ` Geert Uytterhoeven
2025-11-12 13:53 ` Lad, Prabhakar
2025-11-11 9:10 ` [PATCH net-next v3 3/3] net: phy: mscc: Add support for PHY LED control Prabhakar
2025-11-11 9:54 ` Parthiban.Veerasooran
2025-11-11 9:58 ` Lad, Prabhakar
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=40e744b5-cc17-4b33-8d0b-1e9987eece7c@microchip.com \
--to=parthiban.veerasooran@microchip.com \
--cc=Horatiu.Vultur@microchip.com \
--cc=andrew@lunn.ch \
--cc=biju.das.jz@bp.renesas.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=fabrizio.castro.jz@renesas.com \
--cc=geert+renesas@glider.be \
--cc=hkallweit1@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=prabhakar.csengg@gmail.com \
--cc=prabhakar.mahadev-lad.rj@bp.renesas.com \
--cc=vadim.fedorenko@linux.dev \
--cc=vladimir.oltean@nxp.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