This source file includes following definitions.
- asix_soft_reset
1
2
3
4
5
6 #include <linux/kernel.h>
7 #include <linux/errno.h>
8 #include <linux/init.h>
9 #include <linux/module.h>
10 #include <linux/mii.h>
11 #include <linux/phy.h>
12
13 #define PHY_ID_ASIX_AX88796B 0x003b1841
14
15 MODULE_DESCRIPTION("Asix PHY driver");
16 MODULE_AUTHOR("Michael Schmitz <schmitzmic@gmail.com>");
17 MODULE_LICENSE("GPL");
18
19
20
21
22
23
24
25
26
27
28
29
30 static int asix_soft_reset(struct phy_device *phydev)
31 {
32 int ret;
33
34
35 ret = phy_write(phydev, MII_BMCR, 0);
36 if (ret < 0)
37 return ret;
38
39 return genphy_soft_reset(phydev);
40 }
41
42 static struct phy_driver asix_driver[] = { {
43 .phy_id = PHY_ID_ASIX_AX88796B,
44 .name = "Asix Electronics AX88796B",
45 .phy_id_mask = 0xfffffff0,
46
47 .soft_reset = asix_soft_reset,
48 } };
49
50 module_phy_driver(asix_driver);
51
52 static struct mdio_device_id __maybe_unused asix_tbl[] = {
53 { PHY_ID_ASIX_AX88796B, 0xfffffff0 },
54 { }
55 };
56
57 MODULE_DEVICE_TABLE(mdio, asix_tbl);