int (*config_init)(struct phy_device *phydev); //配置初始化 int (*probe)(struct phy_device *phydev); //探测到 probe方法 int (*suspend)(struct phy_device *phydev); //唤醒 int (*resume)(struct phy_device *phydev); //挂起 int (*config_aneg)(struct phy_device *phydev); //支援...
.flags = PHY_HAS_INTERRUPT, .config_aneg = &genphy_config_aneg, .config_init = &rtl8211f_config_init, .read_status = &genphy_read_status, .ack_interrupt = &rtl8211f_ack_interrupt, .config_intr = &rtl8211f_config_intr, .suspend = genphy_suspend, .resume = genphy_resume, }, }...
int(*config_init)(struct phy_device *phydev); int(*probe)(struct phy_device *phydev); int(*suspend)(struct phy_device *phydev); int(*resume)(struct phy_device *phydev); int(*config_aneg)(struct phy_device *phydev); int(*aneg_done)(struct phy_device *phydev); int(*read_status...
.config_aneg=&genphy_config_aneg, .config_init=&rtl8211f_config_init, .read_status=&genphy_read_status, .ack_interrupt=&rtl8211f_ack_interrupt, .config_intr=&rtl8211f_config_intr, .suspend=genphy_suspend, .resume=genphy_resume, }, }; module_phy_driver(realtek_drvs);//注册PHY驱动 s...
2.若phy_device存在,则进行net_device与phy_device的相互关联(phy_device->attached_dev、net_device->phydev),并调用phy_driver->config_init完成对phy device的初始化; 3.启动phy_device的状态机对应的延迟队列。 phy_disconnect分析 phy_disconnect的操作刚好与phy_connect接口的操作相反,主要提供的功能如下: ...
struct phy_driver { struct mdio_driver_common mdiodrv; u32 phy_id; char *name; u32 phy_id_mask; u32 features; u32 flags; const void *driver_data; int (*soft_reset)(struct phy_device *phydev); int (*config_init)(struct phy_device *phydev); int (*probe)(struct phy_device *...
1问题分析 问题描述1:以太网初始化报错 No phy found 在执行ifconfig eth0 up命令时,出现"No phy found"异常log。问题分析:出现"No phy found",常见原因是供给phy使用的25M时钟异常,导致phy工作不正常,gmac驱动通过mdio接口也读不到phy的设备信息。或者MDIO引脚配置不正确或者phy地址不正确,再就是MDIO没做...
struct phy_driver{struct mdio_driver_common mdiodrv;u32 phy_id;char*name;u32 phy_id_mask;u32 features;u32 flags;constvoid*driver_data;int(*soft_reset)(struct phy_device*phydev);int(*config_init)(struct phy_device*phydev);int(*probe)(struct phy_device*phydev);int(*suspend)(struct ...
static int rtl820x_config_init(struct phy_device *phydev) { int val; u32 features; u16 page; u16 regval; /* Make sure PHY is ON */ genphy_resume(phydev); /* For now, I'll claim that the generic driver supports * all possible port types */ ...
28.调用函数config_init对所述硬件设备进行初始化。 29.进一步的,所述步骤:执行用户输入的指令,具体包括: 30.若有输入指令,则进行指令判断并观察对应的指令是否执行; 31.若无输入指令,则直接调用函数read_status重新判断是否有输入指令。 32.进一步的,所述指令包括模拟ifconfig down行为、模拟ifconfig up行为、模拟...