/drivers/net/ |
D | mdio.c | 29 int mdio45_probe(struct mdio_if_info *mdio, int prtad) in mdio45_probe() argument 37 stat2 = mdio->mdio_read(mdio->dev, prtad, mmd, MDIO_STAT2); in mdio45_probe() 43 devs1 = mdio->mdio_read(mdio->dev, prtad, mmd, MDIO_DEVS1); in mdio45_probe() 44 devs2 = mdio->mdio_read(mdio->dev, prtad, mmd, MDIO_DEVS2); in mdio45_probe() 48 mdio->prtad = prtad; in mdio45_probe() 49 mdio->mmds = devs1 | (devs2 << 16); in mdio45_probe() 69 int mdio_set_flag(const struct mdio_if_info *mdio, in mdio_set_flag() argument 73 int old_val = mdio->mdio_read(mdio->dev, prtad, devad, addr); in mdio_set_flag() 84 return mdio->mdio_write(mdio->dev, prtad, devad, addr, new_val); in mdio_set_flag() 97 int mdio45_links_ok(const struct mdio_if_info *mdio, u32 mmd_mask) in mdio45_links_ok() argument [all …]
|
/drivers/of/ |
D | of_mdio.c | 44 static int of_mdiobus_register_phy(struct mii_bus *mdio, struct device_node *child, in of_mdiobus_register_phy() argument 56 phy = phy_device_create(mdio, addr, phy_id, 0, NULL); in of_mdiobus_register_phy() 58 phy = get_phy_device(mdio, addr, is_c45); in of_mdiobus_register_phy() 65 if (mdio->irq) in of_mdiobus_register_phy() 66 mdio->irq[addr] = rc; in of_mdiobus_register_phy() 68 if (mdio->irq) in of_mdiobus_register_phy() 69 phy->irq = mdio->irq[addr]; in of_mdiobus_register_phy() 73 mdio->phy_ignore_ta_mask |= 1 << addr; in of_mdiobus_register_phy() 89 dev_dbg(&mdio->dev, "registered phy %s at address %i\n", in of_mdiobus_register_phy() 125 int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np) in of_mdiobus_register() argument [all …]
|
/drivers/net/ethernet/chelsio/cxgb/ |
D | cphy.h | 105 struct mdio_if_info mdio; member 113 int rc = cphy->mdio.mdio_read(cphy->mdio.dev, cphy->mdio.prtad, mmd, in cphy_mdio_read() 122 return cphy->mdio.mdio_write(cphy->mdio.dev, cphy->mdio.prtad, mmd, in cphy_mdio_write() 147 phy->mdio.prtad = phy_addr; in cphy_init() 148 phy->mdio.mmds = phy_ops->mmds; in cphy_init() 149 phy->mdio.mode_support = mdio_ops->mode_support; in cphy_init() 150 phy->mdio.mdio_read = mdio_ops->read; in cphy_init() 151 phy->mdio.mdio_write = mdio_ops->write; in cphy_init() 153 phy->mdio.dev = dev; in cphy_init()
|
/drivers/net/usb/ |
D | ax88172a.c | 31 struct mii_bus *mdio; member 103 priv->mdio = mdiobus_alloc(); in ax88172a_init_mdio() 104 if (!priv->mdio) { in ax88172a_init_mdio() 109 priv->mdio->priv = (void *)dev; in ax88172a_init_mdio() 110 priv->mdio->read = &asix_mdio_bus_read; in ax88172a_init_mdio() 111 priv->mdio->write = &asix_mdio_bus_write; in ax88172a_init_mdio() 112 priv->mdio->name = "Asix MDIO Bus"; in ax88172a_init_mdio() 114 snprintf(priv->mdio->id, MII_BUS_ID_SIZE, "usb-%03d:%03d", in ax88172a_init_mdio() 117 priv->mdio->irq = kzalloc(sizeof(int) * PHY_MAX_ADDR, GFP_KERNEL); in ax88172a_init_mdio() 118 if (!priv->mdio->irq) { in ax88172a_init_mdio() [all …]
|
/drivers/net/phy/ |
D | Makefile | 25 obj-$(CONFIG_MDIO_BITBANG) += mdio-bitbang.o 26 obj-$(CONFIG_MDIO_GPIO) += mdio-gpio.o 33 obj-$(CONFIG_MDIO_OCTEON) += mdio-octeon.o 37 obj-$(CONFIG_MDIO_BUS_MUX) += mdio-mux.o 38 obj-$(CONFIG_MDIO_BUS_MUX_GPIO) += mdio-mux-gpio.o 39 obj-$(CONFIG_MDIO_BUS_MUX_MMIOREG) += mdio-mux-mmioreg.o 40 obj-$(CONFIG_MDIO_SUN4I) += mdio-sun4i.o 41 obj-$(CONFIG_MDIO_MOXART) += mdio-moxart.o 42 obj-$(CONFIG_MDIO_BCM_UNIMAC) += mdio-bcm-unimac.o 44 obj-$(CONFIG_MDIO_BCM_IPROC) += mdio-bcm-iproc.o
|
D | mdio-gpio.c | 35 int mdc, mdio, mdo; member 60 pdata->mdio = ret; in mdio_gpio_of_get_data() 89 gpio_direction_output(bitbang->mdio, in mdio_dir() 92 gpio_direction_input(bitbang->mdio); in mdio_dir() 100 return gpio_get_value_cansleep(bitbang->mdio) ^ in mdio_get() 113 gpio_set_value_cansleep(bitbang->mdio, in mdio_set() 149 bitbang->mdio = pdata->mdio; in mdio_gpio_bus_init() 180 if (devm_gpio_request(dev, bitbang->mdio, "mdio")) in mdio_gpio_bus_init() 187 gpio_direction_input(bitbang->mdio); in mdio_gpio_bus_init()
|
D | mdio_bus.c | 198 static void of_mdiobus_link_phydev(struct mii_bus *mdio, in of_mdiobus_link_phydev() argument 204 if (dev->of_node || !mdio->dev.of_node) in of_mdiobus_link_phydev() 207 for_each_available_child_of_node(mdio->dev.of_node, child) { in of_mdiobus_link_phydev() 232 static inline void of_mdiobus_link_phydev(struct mii_bus *mdio, in of_mdiobus_link_phydev() argument
|
/drivers/net/ethernet/sfc/ |
D | mdio_10g.h | 27 return efx->mdio.mdio_read(efx->net_dev, efx->mdio.prtad, devad, addr); in efx_mdio_read() 33 efx->mdio.mdio_write(efx->net_dev, efx->mdio.prtad, devad, addr, value); in efx_mdio_write() 104 mdio_set_flag(&efx->mdio, efx->mdio.prtad, devad, addr, mask, state); in efx_mdio_set_flag()
|
D | mdio_10g.c | 178 return mdio45_links_ok(&efx->mdio, mmd_mask); in efx_mdio_links_ok() 268 WARN_ON(!(efx->mdio.mmds & MDIO_DEVS_AN)); in efx_mdio_an_reconfigure() 294 WARN_ON(!(efx->mdio.mmds & MDIO_DEVS_AN)); in efx_mdio_get_pause() 304 int devad = __ffs(efx->mdio.mmds); in efx_mdio_test_alive() 315 "no MDIO PHY present with ID %d\n", efx->mdio.prtad); in efx_mdio_test_alive() 318 rc = efx_mdio_check_mmds(efx, efx->mdio.mmds); in efx_mdio_test_alive()
|
D | qt202x_phy.c | 354 efx->mdio.mmds = QT202X_REQUIRED_DEVS; in qt202x_phy_probe() 355 efx->mdio.mode_support = MDIO_SUPPORTS_C45 | MDIO_EMULATE_C22; in qt202x_phy_probe() 418 &efx->mdio, efx->mdio.prtad, MDIO_MMD_PMAPMD, in qt202x_phy_reconfigure() 442 mdio45_ethtool_gset(&efx->mdio, ecmd); in qt202x_phy_get_settings()
|
D | mcdi_port.c | 364 efx->mdio.prtad = phy_data->port; in efx_mcdi_phy_probe() 365 efx->mdio.mmds = phy_data->mmd_mask & ~(1 << MC_CMD_MMD_CLAUSE22); in efx_mcdi_phy_probe() 366 efx->mdio.mode_support = 0; in efx_mcdi_phy_probe() 368 efx->mdio.mode_support |= MDIO_SUPPORTS_C22; in efx_mcdi_phy_probe() 370 efx->mdio.mode_support |= MDIO_SUPPORTS_C45 | MDIO_EMULATE_C22; in efx_mcdi_phy_probe() 521 ecmd->mdio_support = (efx->mdio.mode_support & in efx_mcdi_phy_get_settings() 999 efx->mdio.mode_support = MDIO_SUPPORTS_C45 | MDIO_EMULATE_C22; in efx_mcdi_port_probe() 1000 efx->mdio.mdio_read = efx_mcdi_mdio_read; in efx_mcdi_port_probe() 1001 efx->mdio.mdio_write = efx_mcdi_mdio_write; in efx_mcdi_port_probe()
|
D | tenxpress.c | 177 efx->mdio.mmds = TENXPRESS_REQUIRED_DEVS; in tenxpress_phy_probe() 178 efx->mdio.mode_support = MDIO_SUPPORTS_C45; in tenxpress_phy_probe() 458 mdio45_ethtool_gset_npage(&efx->mdio, ecmd, adv, lpa); in tenxpress_get_settings()
|
D | txc43128_phy.c | 335 efx->mdio.mmds = TXC_REQUIRED_DEVS; in txc43128_phy_probe() 336 efx->mdio.mode_support = MDIO_SUPPORTS_C45 | MDIO_EMULATE_C22; in txc43128_phy_probe() 545 mdio45_ethtool_gset(&efx->mdio, ecmd); in txc43128_get_settings()
|
/drivers/net/ethernet/chelsio/cxgb3/ |
D | aq100x.c | 75 phy->mdio.prtad, err); in aq100x_reset() 122 return mdio_set_flag(&phy->mdio, phy->mdio.prtad, in aq100x_power_down() 133 err = mdio_set_flag(&phy->mdio, phy->mdio.prtad, in aq100x_autoneg_enable() 146 err = mdio_set_flag(&phy->mdio, phy->mdio.prtad, in aq100x_autoneg_restart() 196 return mdio_set_flag(&phy->mdio, phy->mdio.prtad, in aq100x_set_loopback()
|
D | common.h | 556 struct mdio_if_info mdio; member 564 int rc = phy->mdio.mdio_read(phy->mdio.dev, phy->mdio.prtad, mmd, reg); in t3_mdio_read() 572 return phy->mdio.mdio_write(phy->mdio.dev, phy->mdio.prtad, mmd, in t3_mdio_write() 587 phy->mdio.prtad = phy_addr; in cphy_init() 588 phy->mdio.mmds = phy_ops->mmds; in cphy_init() 589 phy->mdio.mode_support = mdio_ops->mode_support; in cphy_init() 590 phy->mdio.mdio_read = mdio_ops->read; in cphy_init() 591 phy->mdio.mdio_write = mdio_ops->write; in cphy_init()
|
D | ael1002.c | 103 phy->mdio.prtad == 0 ? F_GPIO7_OUT_VAL : F_GPIO2_OUT_VAL; in ael100x_txon() 137 phy->mdio.prtad, dev_addr, word_addr); in ael_i2c_rd() 147 err = mdio_set_flag(&phy->mdio, phy->mdio.prtad, in ael1002_power_down() 886 phy->mdio.prtad = 1; in t3_qt2045_phy_prep() 900 int prtad = phy->mdio.prtad; in xaui_direct_get_link_status()
|
/drivers/net/ethernet/altera/ |
D | altera_tse_main.c | 136 struct mii_bus *mdio = NULL; in altera_tse_mdio_create() local 153 mdio = mdiobus_alloc(); in altera_tse_mdio_create() 154 if (mdio == NULL) { in altera_tse_mdio_create() 159 mdio->name = ALTERA_TSE_RESOURCE_NAME; in altera_tse_mdio_create() 160 mdio->read = &altera_tse_mdio_read; in altera_tse_mdio_create() 161 mdio->write = &altera_tse_mdio_write; in altera_tse_mdio_create() 162 snprintf(mdio->id, MII_BUS_ID_SIZE, "%s-%u", mdio->name, id); in altera_tse_mdio_create() 164 mdio->irq = kcalloc(PHY_MAX_ADDR, sizeof(int), GFP_KERNEL); in altera_tse_mdio_create() 165 if (mdio->irq == NULL) { in altera_tse_mdio_create() 170 mdio->irq[i] = PHY_POLL; in altera_tse_mdio_create() [all …]
|
/drivers/net/ethernet/ |
D | ethoc.c | 223 struct mii_bus *mdio; member 681 phy = priv->mdio->phy_map[priv->phy_id]; in ethoc_mdio_probe() 683 phy = phy_find_first(priv->mdio); in ethoc_mdio_probe() 760 struct mii_ioctl_data *mdio = if_mii(ifr); in ethoc_ioctl() local 767 if (mdio->phy_id >= PHY_MAX_ADDR) in ethoc_ioctl() 770 phy = priv->mdio->phy_map[mdio->phy_id]; in ethoc_ioctl() 1197 priv->mdio = mdiobus_alloc(); in ethoc_probe() 1198 if (!priv->mdio) { in ethoc_probe() 1203 priv->mdio->name = "ethoc-mdio"; in ethoc_probe() 1204 snprintf(priv->mdio->id, MII_BUS_ID_SIZE, "%s-%d", in ethoc_probe() [all …]
|
/drivers/net/ethernet/aeroflex/ |
D | greth.c | 1179 while (GRETH_REGLOAD(greth->regs->mdio) & GRETH_MII_BUSY) { in wait_for_mdio() 1194 GRETH_REGSAVE(greth->regs->mdio, ((phy & 0x1F) << 11) | ((reg & 0x1F) << 6) | 2); in greth_mdio_read() 1199 if (!(GRETH_REGLOAD(greth->regs->mdio) & GRETH_MII_NVALID)) { in greth_mdio_read() 1200 data = (GRETH_REGLOAD(greth->regs->mdio) >> 16) & 0xFFFF; in greth_mdio_read() 1215 GRETH_REGSAVE(greth->regs->mdio, in greth_mdio_write() 1284 phy = phy_find_first(greth->mdio); in greth_mdio_probe() 1329 greth->mdio = mdiobus_alloc(); in greth_mdio_init() 1330 if (!greth->mdio) { in greth_mdio_init() 1334 greth->mdio->name = "greth-mdio"; in greth_mdio_init() 1335 snprintf(greth->mdio->id, MII_BUS_ID_SIZE, "%s-%d", greth->mdio->name, greth->irq); in greth_mdio_init() [all …]
|
D | greth.h | 86 u32 mdio; member 127 struct mii_bus *mdio; member
|
/drivers/net/ethernet/broadcom/genet/ |
D | bcmmii.c | 560 struct mii_bus *mdio = priv->mii_bus; in bcmgenet_mii_pd_init() local 569 mdio->phy_mask = ~(1 << pd->phy_address); in bcmgenet_mii_pd_init() 571 mdio->phy_mask = 0; in bcmgenet_mii_pd_init() 573 ret = mdiobus_register(mdio); in bcmgenet_mii_pd_init() 580 phydev = mdio->phy_map[pd->phy_address]; in bcmgenet_mii_pd_init() 582 phydev = phy_find_first(mdio); in bcmgenet_mii_pd_init() 586 mdiobus_unregister(mdio); in bcmgenet_mii_pd_init()
|
/drivers/pinctrl/qcom/ |
D | pinctrl-ipq8064.c | 501 FUNCTION(mdio), 549 PINGROUP(0, mdio, NA, NA, NA, NA, NA, NA, NA, NA, NA), 550 PINGROUP(1, mdio, NA, NA, NA, NA, NA, NA, NA, NA, NA), 559 PINGROUP(10, gsbi4, spdif, sata, ssbi, mdio, spmi, NA, NA, NA, NA), 560 PINGROUP(11, gsbi4, pcie2_prsnt, pcie1_prsnt, pcie3_prsnt, ssbi, mdio, spmi, NA, NA, NA),
|
/drivers/net/ethernet/freescale/fs_enet/ |
D | mii-bitbang.c | 77 static inline void mdio(struct mdiobb_ctrl *ctrl, int what) in mdio() function 107 .set_mdio_data = mdio,
|
/drivers/net/ethernet/atheros/alx/ |
D | main.c | 1130 if (prtad != hw->mdio.prtad) in alx_mdio_read() 1149 if (prtad != hw->mdio.prtad) in alx_mdio_write() 1165 return mdio_mii_ioctl(&alx->hw.mdio, if_mii(ifr), cmd); in alx_ioctl() 1366 hw->mdio.prtad = 0; in alx_probe() 1367 hw->mdio.mmds = 0; in alx_probe() 1368 hw->mdio.dev = netdev; in alx_probe() 1369 hw->mdio.mode_support = MDIO_SUPPORTS_C45 | in alx_probe() 1372 hw->mdio.mdio_read = alx_mdio_read; in alx_probe() 1373 hw->mdio.mdio_write = alx_mdio_write; in alx_probe()
|
/drivers/net/ethernet/amd/xgbe/ |
D | Makefile | 4 xgbe-desc.o xgbe-ethtool.o xgbe-mdio.o \
|