phydev->link_timeout = PHY_AN_TIMEOUT;break;casePHY_AN: err = phy_read_status(phydev);if(err <0)break;/* If the link is down, give up on negotiation for now */if(!phydev->link) { phydev->state = PHY_NOLINK; netif_carrier_off(phydev->attached_dev); phydev->adjust_link(...
在PHY设备的注册中(读PHY ID)、PHY的初始化、自协商、中断、状态、能力获取等流程中经常可以看到phy_read和phy_write两个函数(下一节要讲的PHY驱动),这两个函数的实现就依赖于控制器设备mii_bus的读写。 phy_read和phy_write定义在linux-4.9.225\include\linux\phy.h中,如下: staticinlineintphy_read(struct...
其中通用 phy 驱动会调用函数 genphy_read_abilities 来读取状态寄存器来确定 phy 芯片的能力: genphy_read_abilities `-| { | val = phy_read(phydev, MII_BMSR);// 读取 mdio 0x01 寄存器来确定 phy 的 10/100M 能力 | linkmode_mod_bit(ETHTOOL_LINK_MODE_Autoneg_BIT, phydev->supported, val ...
(*read_status)(struct phy_device *phydev); int (*ack_interrupt)(struct phy_device *phydev); int (*config_intr)(struct phy_device *phydev); int (*did_interrupt)(struct phy_device *phydev); void (*remove)(struct phy_device *phydev); int (*match_phy_device)(struct phy_device *...
ReadCycle: 0->1 触发MDIO读时序 2.3 MIIMADD 地址寄存器 PHYaddr:PHY地址,共5bit,系统最多联31个PHY(地址0为保留) REGaddr:寄存器地址,共5bit,一个PHY上最多32个寄存器地址(可以使用shadow value技术,访问更多的寄存器) 2.4 MIIMCON 控制寄存器 PHYcontrol:在写流程时,这里存放要写入寄存器的值 ...
0 = PHY not able to perform half duplex 100BASE-T2 RO 1.8 Extended Status 1 = Extended status information in Register 15 0 = No extended status information in Register 15 RO 1.7 Reserved ignore when read RO 1.6 MF Preamble Suppression 1 = PHY will accept management frames ...
int(*read_status)(struct phy_device *phydev); int(*ack_interrupt)(struct phy_device *phydev); int(*config_intr)(struct phy_device *phydev); int(*did_interrupt)(struct phy_device *phydev); void(*remove)(struct phy_device *phydev); ...
PHY是IEEE802.3中定义的一个标准模块,STA(station management entity,管理实体,一般为MAC或CPU)通过SMI(Serial Manage Interface)对PHY的行为、状态进行管理和控制,而具体管理和控制动作是通过读写PHY内部的寄存器实现的。PHY寄存器的地址空间为5位,从0到31最多可以定义32个寄存器(随着芯片功能不断增加,很多PHY芯片采用...
33、write as zero, ignore on read ro 4.13remote fault 0=dont transmit remote fault information1=transmit remote fault informationr/w 4.12:5technology ability field technologies supported by local phy to advertiser/w 4.4:0selector field the type of message being sent by auto-negotiationr/w bit...
https://e2e.ti.com/support/interface-group/interface/f/interface-forum/662017/about-phy-solution-that-support-utp-to-fiber-mode 主题中讨论的其他部件:TLK105 尊敬的支持团队: 我们是否有支持低于规格的G PHY解决方案:一个10M/100M/1G Base-T端口,一个RGMII,一个SGMII,支持SERDES (SGMII/光纤),支持UTP...