From mboxrd@z Thu Jan 1 00:00:00 1970 From: Graeme Russ Date: Thu, 22 Sep 2011 13:12:44 +1000 Subject: [U-Boot] Question: Information regarding MII and PHY In-Reply-To: References: Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello again, On Thu, Sep 22, 2011 at 11:20 AM, Graeme Russ wrote: > I'm looking at adding a new Gigabit Ethernet driver (Realtek > RTL8211CL) to U-Boot. The datasheet, in addition to register OK, the RTL8211CL is just the transceiver (PHY?) - The MAC is actually part of an Intel PCH (Platform Controller Hub). From what I can gather MII is the standard interface between the MAC (Intel PCH) and the transceiver/PHY (RTL8211CL) (they actually communicate using RGMII - Reduced Gigabit Media Independent Interface) > descriptions, mentions MII/GMII and PHY support (but not much on the > specifics). Now in U-Boot there appears to be a common set of code > relating to PHY and MII. There appears to be a mix of Ethernet drivers > that use MII/PHY and drivers that do not, but I cannot seems to quite > get me head around it all. One weird thing is that there does not > appear to be any granular inclusion of PHY drivers - > /include/config_phylib_all_drivers.h defines them all when > CONFIG_PHYLIB is defined, but I could not find any boards that defined > just one PHY driver. I also cannot find how MII/PHY functions interact > with PCI for PCI based cards. I now see why there is no relationship between MII/PHY and PCI as they are not connected to the PCI bus - Communication with the PHY is done through the MAC. So is it the case that 'PHY Drivers' in U-Boot provide access to the PHY (Transceiver) _through_ the MAC and in order to use the PHY drivers, the MAC driver (i.e. the Ethernet driver) needs to provide hooks to pass PHY requests from U-Boot over the (RG)MII interface? Or am I even more confused? > In short, I'm very confused - Can anyone give me any pointers to how > it all fits together Thanks, Graeme