[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <0b754e84-45d0-4d3e-aa14-564ab5528b98@microchip.com>
Date: Mon, 25 Aug 2025 09:03:35 +0000
From: <Parthiban.Veerasooran@...rochip.com>
To: <Horatiu.Vultur@...rochip.com>, <andrew@...n.ch>, <hkallweit1@...il.com>,
<linux@...linux.org.uk>, <davem@...emloft.net>, <edumazet@...gle.com>,
<kuba@...nel.org>, <pabeni@...hat.com>, <richardcochran@...il.com>
CC: <netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net-next v2 2/2] net: phy: micrel: Add PTP support for
lan8842
Hi Horatiu,
On 25/08/25 12:01 pm, Horatiu Vultur wrote:
> + /* As the lan8814 and lan8842 has the same IP for the PTP block, the
> + * only difference is the number of the GPIOs, then make sure that the
> + * lan8842 initialized also the shared data pointer as this is used in
> + * all the PTP functions for lan8814. The lan8842 doesn't have multiple
> + * PHYs in the same package.
> + */
> + addr = lanphy_read_page_reg(phydev, LAN8814_PAGE_COMMON_REGS,
> + LAN8842_STRAP_REG);
> + addr &= LAN8842_STRAP_REG_PHYADDR_MASK;
> + if (addr < 0)
> + return addr;
> +
> + devm_phy_package_join(&phydev->mdio.dev, phydev, addr,
> + sizeof(struct lan8814_shared_priv));
Shouldn't you check the return value of devm_phy_package_join()?
Apologies — I missed to comment in my previous review.
Best regards,
Parthiban V
> + if (phy_package_init_once(phydev)) {
> + ret = lan8842_ptp_probe_once(phydev);
> + if (ret)
> + return ret;
> + }
> +
> + lan8814_ptp_init(phydev);
> +
> return 0;
> }
Powered by blists - more mailing lists