[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4b8413d0-272f-4e43-a699-5b3134cfbeab@lunn.ch>
Date: Wed, 28 Feb 2024 17:55:37 +0100
From: Andrew Lunn <andrew@...n.ch>
To: Patryk <pbiel7@...il.com>
Cc: netdev@...r.kernel.org
Subject: Re: Question regarding handling PHY
On Wed, Feb 28, 2024 at 05:29:00PM +0100, Patryk wrote:
> Hi, I've got a question regarding phy drivers. Supposed that I want to
> use an ethernet phy device - in general - do I need a specific driver
> to handle this, or is it handled by some generic eth phy layer that
> can configure (through MDIO) and exchange data (through XMII) in a
> generic, vendor-agnostic way?
phylib has a collection of PHY drivers for specific phys. If the board
you have uses one of those PHYs there is nothing you need to
do. phylib also has a basic generic fall back driver based on what PHY
registers are defined in 802.3. For simple PHY devices, that might be
sufficient to get a working link, but not much more. If you want to
use all the features of the PHY, or it has non-standard registers, a
PHY driver will be needed.
The interface to the MAC is PHY vendor-agnostic. The MAC it just told
how to configure its side of the MII interface. It has no idea what
the PHY on the other end of the MII interface is, or even if there is
a PHY at the other end, since you can connect a MAC to another MAC,
e.g. an Ethernet switch.
Andrew
Powered by blists - more mailing lists