From: Jens Emil Schulz Ostergaard <jensemil.schulzostergaard@microchip.com>
To: Maxime Chevallier <maxime.chevallier@bootlin.com>,
Andrew Lunn <andrew@lunn.ch>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"David S. Miller" <davem@davemloft.net>,
"Eric Dumazet" <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>,
"Paolo Abeni" <pabeni@redhat.com>,
Horatiu Vultur <horatiu.vultur@microchip.com>,
<o.rempel@pengutronix.de>,
Steen Hegelund <Steen.Hegelund@microchip.com>,
Daniel Machon <daniel.machon@microchip.com>
Cc: <netdev@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next] net: phy: micrel: Add support for lan9645x internal phy
Date: Fri, 23 Jan 2026 14:40:46 +0100 [thread overview]
Message-ID: <e401c44526f7b618fb18acf65c599828c9d5efbe.camel@microchip.com> (raw)
In-Reply-To: <d5177d67-7b61-4459-befe-999dc052ca2b@bootlin.com>
Hi Maxime,
On Fri, 2026-01-23 at 09:57 +0100, Maxime Chevallier wrote:
>
> Hi Jens,
>
> On 23/01/2026 08:50, Jens Emil Schulz Østergaard wrote:
> > LAN9645X is a family of switch chips with 5 internal copper phys.
> > The
> > internal PHY is based on parts of LAN8832. This is a low-power,
> > single
> > port triple-speed (10BASE-T/100BASE-TX/1000BASE-T) ethernet
> > physical
> > layer transceiver (PHY) that supports transmission and reception of
> > data
> > on standard CAT-5, as well as CAT-5e and CAT-6 Unshielded Twisted
> > Pair (UTP) cables.
> >
> > Add support for the internal PHY of the lan9645x chip family.
> >
> > Reviewed-by: Steen Hegelund <Steen.Hegelund@microchip.com>
> > Reviewed-by: Daniel Machon <daniel.machon@microchip.com>
> > Signed-off-by: Jens Emil Schulz Østergaard
> > <jensemil.schulzostergaard@microchip.com>
> > ---
>
> [...]
>
> > +static int lan9645x_config_intr(struct phy_device *phydev)
> > +{
> > + int err;
> > +
> > + /* enable / disable interrupts */
> > + if (phydev->interrupts == PHY_INTERRUPT_ENABLED) {
> > + /* This is an internal PHY of lan9645x and is not
> > possible to
> > + * change the polarity of irq sources in the OIC
> > (CPU_INTR)
> > + * found in lan9645x. Therefore change the polarity
> > of the
> > + * interrupt in the PHY from being active low instead
> > of active
> > + * high.
> > + */
> > + phy_write(phydev, LAN8804_CONTROL,
> > + LAN8804_CONTROL_INTR_POLARITY);
> > +
> > + /* By default interrupt buffer is open-drain in which
> > case the
> > + * interrupt can be active only low. Therefore change
> > the
> > + * interrupt buffer to be push-pull to be able to
> > change
> > + * interrupt polarity.
> > + */
> > + phy_write(phydev, LAN8804_OUTPUT_CONTROL,
> > + LAN8804_OUTPUT_CONTROL_INTR_BUFFER);
>
> Small nit from me, you're missing error checks on the 2 above reads.
>
> Thanks,
>
> Maxime
>
Thank you, I will add error checks in the next version.
Thanks,
Emil
next prev parent reply other threads:[~2026-01-23 13:41 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-23 7:50 [PATCH net-next] net: phy: micrel: Add support for lan9645x internal phy Jens Emil Schulz Østergaard
2026-01-23 8:57 ` Maxime Chevallier
2026-01-23 13:40 ` Jens Emil Schulz Ostergaard [this message]
2026-01-23 9:55 ` Oleksij Rempel
2026-01-23 15:12 ` Jens Emil Schulz Ostergaard
2026-01-23 16:11 ` Andrew Lunn
2026-01-27 8:49 ` Jens Emil Schulz Ostergaard
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=e401c44526f7b618fb18acf65c599828c9d5efbe.camel@microchip.com \
--to=jensemil.schulzostergaard@microchip.com \
--cc=Steen.Hegelund@microchip.com \
--cc=andrew@lunn.ch \
--cc=daniel.machon@microchip.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=horatiu.vultur@microchip.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=maxime.chevallier@bootlin.com \
--cc=netdev@vger.kernel.org \
--cc=o.rempel@pengutronix.de \
--cc=pabeni@redhat.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