Home
last modified time | relevance | path

Searched refs:phy_addr (Results 1 – 25 of 131) sorted by relevance

123456

/drivers/net/phy/
Dfixed_phy.c73 static int fixed_mdio_read(struct mii_bus *bus, int phy_addr, int reg_num) in fixed_mdio_read() argument
79 if (fp->addr == phy_addr) { in fixed_mdio_read()
100 static int fixed_mdio_write(struct mii_bus *bus, int phy_addr, int reg_num, in fixed_mdio_write() argument
133 static int fixed_phy_add_gpiod(unsigned int irq, int phy_addr, in fixed_phy_add_gpiod() argument
150 fmb->mii_bus->irq[phy_addr] = irq; in fixed_phy_add_gpiod()
152 fp->addr = phy_addr; in fixed_phy_add_gpiod()
163 int fixed_phy_add(unsigned int irq, int phy_addr, in fixed_phy_add() argument
166 return fixed_phy_add_gpiod(irq, phy_addr, status, NULL); in fixed_phy_add()
172 static void fixed_phy_del(int phy_addr) in fixed_phy_del() argument
178 if (fp->addr == phy_addr) { in fixed_phy_del()
[all …]
Dphy-core.c446 static void mmd_phy_indirect(struct mii_bus *bus, int phy_addr, int devad, in mmd_phy_indirect() argument
450 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, devad); in mmd_phy_indirect()
453 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, regnum); in mmd_phy_indirect()
456 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, in mmd_phy_indirect()
483 int phy_addr = phydev->mdio.addr; in __phy_read_mmd() local
485 mmd_phy_indirect(bus, phy_addr, devad, regnum); in __phy_read_mmd()
488 val = __mdiobus_read(bus, phy_addr, MII_MMD_DATA); in __phy_read_mmd()
539 int phy_addr = phydev->mdio.addr; in __phy_write_mmd() local
541 mmd_phy_indirect(bus, phy_addr, devad, regnum); in __phy_write_mmd()
544 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, val); in __phy_write_mmd()
/drivers/net/ethernet/dlink/
Ddl2k.c84 static int mii_read (struct net_device *dev, int phy_addr, int reg_num);
85 static int mii_write (struct net_device *dev, int phy_addr, int reg_num,
309 np->phy_addr = 1; in find_miiphy()
314 np->phy_addr = i; in find_miiphy()
541 mii_write(dev, np->phy_addr, 31, 0x0001); in rio_hw_init()
542 mii_write(dev, np->phy_addr, 27, 0x01e0); in rio_hw_init()
543 mii_write(dev, np->phy_addr, 31, 0x0002); in rio_hw_init()
544 mii_write(dev, np->phy_addr, 27, 0xeb8e); in rio_hw_init()
545 mii_write(dev, np->phy_addr, 31, 0x0000); in rio_hw_init()
546 mii_write(dev, np->phy_addr, 30, 0x005e); in rio_hw_init()
[all …]
/drivers/net/ethernet/samsung/sxgbe/
Dsxgbe_mdio.c145 int err, phy_addr; in sxgbe_mdio_register() local
179 for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) { in sxgbe_mdio_register()
180 struct phy_device *phy = mdiobus_get_phy(mdio_bus, phy_addr); in sxgbe_mdio_register()
190 irqlist[phy_addr] = mdio_data->probed_phy_irq; in sxgbe_mdio_register()
198 if (priv->plat->phy_addr == -1) in sxgbe_mdio_register()
199 priv->plat->phy_addr = phy_addr; in sxgbe_mdio_register()
201 act = (priv->plat->phy_addr == phy_addr); in sxgbe_mdio_register()
215 phy->phy_id, phy_addr, irq_str, in sxgbe_mdio_register()
/drivers/net/ethernet/chelsio/cxgb3/
Daq100x.c266 int t3_aq100x_phy_prep(struct cphy *phy, struct adapter *adapter, int phy_addr, in t3_aq100x_phy_prep() argument
272 cphy_init(phy, adapter, phy_addr, &aq100x_ops, mdio_ops, in t3_aq100x_phy_prep()
281 gpio = phy_addr ? F_GPIO10_OUT_VAL : F_GPIO6_OUT_VAL; in t3_aq100x_phy_prep()
298 phy_addr, err, v); in t3_aq100x_phy_prep()
308 phy_addr, v); in t3_aq100x_phy_prep()
316 CH_WARN(adapter, "PHY%d: reset took %ums\n", phy_addr, wait); in t3_aq100x_phy_prep()
322 phy_addr, v); in t3_aq100x_phy_prep()
339 phy_addr); in t3_aq100x_phy_prep()
350 phy_addr, v, v2); in t3_aq100x_phy_prep()
Dael1002.c213 int phy_addr, const struct mdio_ops *mdio_ops) in t3_ael1002_phy_prep() argument
215 cphy_init(phy, adapter, phy_addr, &ael1002_ops, mdio_ops, in t3_ael1002_phy_prep()
239 int phy_addr, const struct mdio_ops *mdio_ops) in t3_ael1006_phy_prep() argument
241 cphy_init(phy, adapter, phy_addr, &ael1006_ops, mdio_ops, in t3_ael1006_phy_prep()
510 int phy_addr, const struct mdio_ops *mdio_ops) in t3_ael2005_phy_prep() argument
512 cphy_init(phy, adapter, phy_addr, &ael2005_ops, mdio_ops, in t3_ael2005_phy_prep()
815 int t3_ael2020_phy_prep(struct cphy *phy, struct adapter *adapter, int phy_addr, in t3_ael2020_phy_prep() argument
818 cphy_init(phy, adapter, phy_addr, &ael2020_ops, mdio_ops, in t3_ael2020_phy_prep()
866 int phy_addr, const struct mdio_ops *mdio_ops) in t3_qt2045_phy_prep() argument
870 cphy_init(phy, adapter, phy_addr, &qt2045_ops, mdio_ops, in t3_qt2045_phy_prep()
[all …]
Dcommon.h157 int (*read)(struct net_device *dev, int phy_addr, int mmd_addr,
159 int (*write)(struct net_device *dev, int phy_addr, int mmd_addr,
578 int phy_addr, const struct cphy_ops *phy_ops, in cphy_init() argument
587 phy->mdio.prtad = phy_addr; in cphy_init()
758 int phy_addr, const struct mdio_ops *mdio_ops);
760 int phy_addr, const struct mdio_ops *mdio_ops);
762 int phy_addr, const struct mdio_ops *mdio_ops);
764 int phy_addr, const struct mdio_ops *mdio_ops);
766 int phy_addr, const struct mdio_ops *mdio_ops);
767 int t3_qt2045_phy_prep(struct cphy *phy, struct adapter *adapter, int phy_addr,
[all …]
/drivers/net/ethernet/arc/
Demac_mdio.c56 static int arc_mdio_read(struct mii_bus *bus, int phy_addr, int reg_num) in arc_mdio_read() argument
63 0x60020000 | (phy_addr << 23) | (reg_num << 18)); in arc_mdio_read()
72 phy_addr, reg_num, value); in arc_mdio_read()
88 static int arc_mdio_write(struct mii_bus *bus, int phy_addr, in arc_mdio_write() argument
95 phy_addr, reg_num, value); in arc_mdio_write()
98 0x50020000 | (phy_addr << 23) | (reg_num << 18) | value); in arc_mdio_write()
/drivers/net/ethernet/dec/tulip/
Ddmfe.c244 u8 phy_addr; member
615 db->phy_addr = 1; in dmfe_init_dm910x()
754 dmfe_phy_write(ioaddr, db->phy_addr, 0, 0x8000, db->chip_id); in dmfe_stop()
1137 dmfe_phy_write(ioaddr, db->phy_addr, 0, 0x1000, db->chip_id); in dmfe_timer()
1213 dmfe_phy_read (db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_timer()
1215 db->phy_addr, 1, db->chip_id) & 0x4) ? 1 : 0; in dmfe_timer()
1230 dmfe_phy_write(db->ioaddr, db->phy_addr, in dmfe_timer()
1632 phy_mode = dmfe_phy_read(db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_sense_speed()
1633 phy_mode = dmfe_phy_read(db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_sense_speed()
1638 db->phy_addr, 7, db->chip_id) & 0xf000; in dmfe_sense_speed()
[all …]
Duli526x.c161 u8 phy_addr; member
516 db->phy_addr = 1; in uli526x_init()
522 db->phy_addr = phy_tmp; in uli526x_init()
533 phy_reg_reset = phy->read(db, db->phy_addr, 0); in uli526x_init()
535 phy->write(db, db->phy_addr, 0, phy_reg_reset); in uli526x_init()
542 while (timeout-- && phy->read(db, db->phy_addr, 0) & 0x8000) in uli526x_init()
661 db->phy.write(db, db->phy_addr, 0, 0x8000); in uli526x_stop()
941 cmd->base.phy_address = db->phy_addr; in ULi_ethtool_get_link_ksettings()
1058 if ((phy->read(db, db->phy_addr, 5) & 0x01e0)!=0) in uli526x_timer()
1071 phy->write(db, db->phy_addr, 0, 0x1000); in uli526x_timer()
[all …]
/drivers/net/ethernet/aquantia/atlantic/
Daq_phy.c28 u16 phy_addr = aq_hw->phy_id << 5 | mmd; in aq_mdio_read_word() local
36 ((phy_addr & HW_ATL_MDIO_PHY_ADDRESS_MSK) << in aq_mdio_read_word()
44 ((phy_addr & HW_ATL_MDIO_PHY_ADDRESS_MSK) << in aq_mdio_read_word()
54 u16 phy_addr = aq_hw->phy_id << 5 | mmd; in aq_mdio_write_word() local
62 ((phy_addr & HW_ATL_MDIO_PHY_ADDRESS_MSK) << in aq_mdio_write_word()
72 ((phy_addr & HW_ATL_MDIO_PHY_ADDRESS_MSK) << in aq_mdio_write_word()
/drivers/net/ethernet/sis/
Dsis900.c149 int phy_addr; member
242 static u16 sis900_reset_phy(struct net_device *net_dev, int phy_addr);
243 static void sis900_auto_negotiate(struct net_device *net_dev, int phy_addr);
604 int phy_addr; in sis900_mii_probe() local
609 for (phy_addr = 0; phy_addr < 32; phy_addr++) { in sis900_mii_probe()
616 mii_status = mdio_read(net_dev, phy_addr, MII_STATUS); in sis900_mii_probe()
622 dev_name, phy_addr); in sis900_mii_probe()
637 mii_phy->phy_id0 = mdio_read(net_dev, phy_addr, MII_PHY_ID0); in sis900_mii_probe()
638 mii_phy->phy_id1 = mdio_read(net_dev, phy_addr, MII_PHY_ID1); in sis900_mii_probe()
639 mii_phy->phy_addr = phy_addr; in sis900_mii_probe()
[all …]
/drivers/net/ethernet/amd/
Dau1000_eth.c269 static int au1000_mdio_read(struct net_device *dev, int phy_addr, int reg) in au1000_mdio_read() argument
286 MAC_SET_MII_SELECT_PHY(phy_addr) | MAC_MII_READ; in au1000_mdio_read()
301 static void au1000_mdio_write(struct net_device *dev, int phy_addr, in au1000_mdio_write() argument
319 MAC_SET_MII_SELECT_PHY(phy_addr) | MAC_MII_WRITE; in au1000_mdio_write()
325 static int au1000_mdiobus_read(struct mii_bus *bus, int phy_addr, int regnum) in au1000_mdiobus_read() argument
334 return au1000_mdio_read(dev, phy_addr, regnum); in au1000_mdiobus_read()
337 static int au1000_mdiobus_write(struct mii_bus *bus, int phy_addr, int regnum, in au1000_mdiobus_write() argument
347 au1000_mdio_write(dev, phy_addr, regnum, value); in au1000_mdiobus_write()
476 int phy_addr; in au1000_mii_probe() local
481 if (aup->phy_addr) in au1000_mii_probe()
[all …]
/drivers/net/ethernet/chelsio/cxgb/
Dcphy.h45 int (*read)(struct net_device *dev, int phy_addr, int mmd_addr,
47 int (*write)(struct net_device *dev, int phy_addr, int mmd_addr,
140 int phy_addr, const struct cphy_ops *phy_ops, in cphy_init() argument
147 phy->mdio.prtad = phy_addr; in cphy_init()
159 struct cphy *(*create)(struct net_device *dev, int phy_addr,
/drivers/staging/netlogic/
Dxlr_net.c140 return mdiobus_get_phy(priv->mii_bus, priv->phy_addr); in xlr_get_phydev()
597 static int xlr_phy_write(u32 *base_addr, int phy_addr, int regnum, u16 val) in xlr_phy_write() argument
607 xlr_nae_wreg(base_addr, R_MII_MGMT_ADDRESS, (phy_addr << 8) | regnum); in xlr_phy_write()
627 static int xlr_phy_read(u32 *base_addr, int phy_addr, int regnum) in xlr_phy_read() argument
639 (phy_addr << 8) | (regnum << 0)); in xlr_phy_read()
664 static int xlr_mii_write(struct mii_bus *bus, int phy_addr, int regnum, u16 val) in xlr_mii_write() argument
669 ret = xlr_phy_write(priv->mii_addr, phy_addr, regnum, val); in xlr_mii_write()
671 phy_addr, regnum, val, ret); in xlr_mii_write()
675 static int xlr_mii_read(struct mii_bus *bus, int phy_addr, int regnum) in xlr_mii_read() argument
680 ret = xlr_phy_read(priv->mii_addr, phy_addr, regnum); in xlr_mii_read()
[all …]
Dplatform_net.c94 ndata1.phy_addr[mac] = mac + 4 + 0x10; in gmac_controller2_init()
142 ndata0.phy_addr[0] = 0; in xls_gmac_init()
157 ndata0.phy_addr[mac] = mac + 0x10; in xls_gmac_init()
199 ndata0.phy_addr[mac] = mac; in xlr_gmac_init()
/drivers/crypto/qat/qat_common/
Dadf_admin.c101 dma_addr_t phy_addr; member
234 &admin->phy_addr, GFP_KERNEL); in adf_init_admin_comms()
248 admin->virt_addr, admin->phy_addr); in adf_init_admin_comms()
261 reg_val = (u64)admin->phy_addr; in adf_init_admin_comms()
281 admin->virt_addr, admin->phy_addr); in adf_exit_admin_comms()
/drivers/net/mdio/
Dmdio-ipq8064.c53 ipq8064_mdio_read(struct mii_bus *bus, int phy_addr, int reg_offset) in ipq8064_mdio_read() argument
64 miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) | in ipq8064_mdio_read()
79 ipq8064_mdio_write(struct mii_bus *bus, int phy_addr, int reg_offset, u16 data) in ipq8064_mdio_write() argument
90 miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) | in ipq8064_mdio_write()
/drivers/net/ethernet/stmicro/stmmac/
Dchain_mode.c98 static void init_dma_chain(void *des, dma_addr_t phy_addr, in init_dma_chain() argument
106 dma_addr_t dma_phy = phy_addr; in init_dma_chain()
115 p->basic.des3 = cpu_to_le32((unsigned int)phy_addr); in init_dma_chain()
124 p->des3 = cpu_to_le32((unsigned int)phy_addr); in init_dma_chain()
/drivers/net/ethernet/hisilicon/hns3/hns3pf/
Dhclge_mdio.c132 if (hdev->hw.mac.phy_addr == PHY_INEXISTENT) { in hclge_mac_mdio_config()
136 } else if (hdev->hw.mac.phy_addr >= PHY_MAX_ADDR) { in hclge_mac_mdio_config()
138 hdev->hw.mac.phy_addr); in hclge_mac_mdio_config()
154 mdio_bus->phy_mask = ~(1 << mac->phy_addr); in hclge_mac_mdio_config()
162 phydev = mdiobus_get_phy(mdio_bus, mac->phy_addr); in hclge_mac_mdio_config()
/drivers/net/ethernet/qualcomm/emac/
Demac-phy.c111 u32 phy_addr; in emac_phy_config() local
119 &phy_addr); in emac_phy_config()
126 adpt->phydev = mdiobus_get_phy(mii_bus, phy_addr); in emac_phy_config()
/drivers/i2c/busses/
Di2c-at91.h175 int at91_twi_probe_master(struct platform_device *pdev, u32 phy_addr,
180 int at91_twi_probe_slave(struct platform_device *pdev, u32 phy_addr,
186 u32 phy_addr, struct at91_twi_dev *dev) in at91_twi_probe_slave() argument
Di2c-stm32.c13 dma_addr_t phy_addr, in stm32_i2c_dma_request() argument
36 dma_sconfig.dst_addr = phy_addr + txdr_offset; in stm32_i2c_dma_request()
58 dma_sconfig.src_addr = phy_addr + rxdr_offset; in stm32_i2c_dma_request()
Di2c-at91-core.c202 u32 phy_addr; in at91_twi_probe() local
213 phy_addr = mem->start; in at91_twi_probe()
248 rc = at91_twi_probe_slave(pdev, phy_addr, dev); in at91_twi_probe()
250 rc = at91_twi_probe_master(pdev, phy_addr, dev); in at91_twi_probe()
/drivers/net/ethernet/socionext/
Dnetsec.c308 u32 phy_addr; member
466 static int netsec_phy_read(struct mii_bus *bus, int phy_addr, int reg_addr);
469 int phy_addr, int reg, u16 val) in netsec_phy_write() argument
477 phy_addr << NETSEC_GMAC_GAR_REG_SHIFT_PA | in netsec_phy_write()
494 netsec_phy_read(bus, phy_addr, MII_PHYSID1); in netsec_phy_write()
499 static int netsec_phy_read(struct mii_bus *bus, int phy_addr, int reg_addr) in netsec_phy_read() argument
506 phy_addr << NETSEC_GMAC_GAR_REG_SHIFT_PA | in netsec_phy_read()
1719 data = netsec_phy_read(priv->mii_bus, priv->phy_addr, MII_BMCR); in netsec_netdev_init()
1720 netsec_phy_write(priv->mii_bus, priv->phy_addr, MII_BMCR, in netsec_netdev_init()
1728 netsec_phy_write(priv->mii_bus, priv->phy_addr, MII_BMCR, data); in netsec_netdev_init()
[all …]

123456