Home
last modified time | relevance | path

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

1234567

/Linux-v4.19/drivers/net/phy/
Dfixed_phy.c57 static int fixed_mdio_read(struct mii_bus *bus, int phy_addr, int reg_num) in fixed_mdio_read() argument
63 if (fp->addr == phy_addr) { in fixed_mdio_read()
85 static int fixed_mdio_write(struct mii_bus *bus, int phy_addr, int reg_num, in fixed_mdio_write() argument
118 int fixed_phy_add(unsigned int irq, int phy_addr, in fixed_phy_add() argument
137 fmb->mii_bus->irq[phy_addr] = irq; in fixed_phy_add()
139 fp->addr = phy_addr; in fixed_phy_add()
164 static void fixed_phy_del(int phy_addr) in fixed_phy_del() argument
170 if (fp->addr == phy_addr) { in fixed_phy_del()
175 ida_simple_remove(&phy_fixed_ida, phy_addr); in fixed_phy_del()
188 int phy_addr; in fixed_phy_register() local
[all …]
Dphy-core.c235 static void mmd_phy_indirect(struct mii_bus *bus, int phy_addr, int devad, in mmd_phy_indirect() argument
239 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, devad); in mmd_phy_indirect()
242 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, regnum); in mmd_phy_indirect()
245 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, in mmd_phy_indirect()
273 int phy_addr = phydev->mdio.addr; in phy_read_mmd() local
276 mmd_phy_indirect(bus, phy_addr, devad, regnum); in phy_read_mmd()
279 val = __mdiobus_read(bus, phy_addr, MII_MMD_DATA); in phy_read_mmd()
312 int phy_addr = phydev->mdio.addr; in phy_write_mmd() local
315 mmd_phy_indirect(bus, phy_addr, devad, regnum); in phy_write_mmd()
318 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, val); in phy_write_mmd()
/Linux-v4.19/arch/mips/cavium-octeon/executive/
Dcvmx-bootmem.c483 int __cvmx_bootmem_phy_free(uint64_t phy_addr, uint64_t size, uint32_t flags) in __cvmx_bootmem_phy_free() argument
491 (unsigned long long)phy_addr, (unsigned long long)size); in __cvmx_bootmem_phy_free()
509 if (cur_addr == 0 || phy_addr < cur_addr) { in __cvmx_bootmem_phy_free()
511 if (cur_addr && phy_addr + size > cur_addr) in __cvmx_bootmem_phy_free()
513 else if (phy_addr + size == cur_addr) { in __cvmx_bootmem_phy_free()
515 cvmx_bootmem_phy_set_next(phy_addr, in __cvmx_bootmem_phy_free()
518 cvmx_bootmem_phy_set_size(phy_addr, in __cvmx_bootmem_phy_free()
521 cvmx_bootmem_desc->head_addr = phy_addr; in __cvmx_bootmem_phy_free()
525 cvmx_bootmem_phy_set_next(phy_addr, cur_addr); in __cvmx_bootmem_phy_free()
526 cvmx_bootmem_phy_set_size(phy_addr, size); in __cvmx_bootmem_phy_free()
[all …]
/Linux-v4.19/drivers/net/ethernet/samsung/sxgbe/
Dsxgbe_mdio.c148 int err, phy_addr; in sxgbe_mdio_register() local
182 for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) { in sxgbe_mdio_register()
183 struct phy_device *phy = mdiobus_get_phy(mdio_bus, phy_addr); in sxgbe_mdio_register()
193 irqlist[phy_addr] = mdio_data->probed_phy_irq; in sxgbe_mdio_register()
201 if (priv->plat->phy_addr == -1) in sxgbe_mdio_register()
202 priv->plat->phy_addr = phy_addr; in sxgbe_mdio_register()
204 act = (priv->plat->phy_addr == phy_addr); in sxgbe_mdio_register()
218 phy->phy_id, phy_addr, irq_str, in sxgbe_mdio_register()
/Linux-v4.19/drivers/net/ethernet/dlink/
Ddl2k.c92 static int mii_read (struct net_device *dev, int phy_addr, int reg_num);
93 static int mii_write (struct net_device *dev, int phy_addr, int reg_num,
317 np->phy_addr = 1; in find_miiphy()
322 np->phy_addr = i; in find_miiphy()
548 mii_write(dev, np->phy_addr, 31, 0x0001); in rio_hw_init()
549 mii_write(dev, np->phy_addr, 27, 0x01e0); in rio_hw_init()
550 mii_write(dev, np->phy_addr, 31, 0x0002); in rio_hw_init()
551 mii_write(dev, np->phy_addr, 27, 0xeb8e); in rio_hw_init()
552 mii_write(dev, np->phy_addr, 31, 0x0000); in rio_hw_init()
553 mii_write(dev, np->phy_addr, 30, 0x005e); in rio_hw_init()
[all …]
/Linux-v4.19/drivers/staging/mt7621-eth/
Dmdio_mt7620.c40 u32 _mt7620_mii_write(struct mt7620_gsw *gsw, u32 phy_addr, in _mt7620_mii_write() argument
50 (phy_addr << GSW_MDIO_ADDR_SHIFT) | write_data, in _mt7620_mii_write()
60 u32 _mt7620_mii_read(struct mt7620_gsw *gsw, int phy_addr, int phy_reg) in _mt7620_mii_read() argument
69 (phy_addr << GSW_MDIO_ADDR_SHIFT), in _mt7620_mii_read()
81 int mt7620_mdio_write(struct mii_bus *bus, int phy_addr, int phy_reg, u16 val) in mt7620_mdio_write() argument
86 return _mt7620_mii_write(gsw, phy_addr, phy_reg, val); in mt7620_mdio_write()
89 int mt7620_mdio_read(struct mii_bus *bus, int phy_addr, int phy_reg) in mt7620_mdio_read() argument
94 return _mt7620_mii_read(gsw, phy_addr, phy_reg); in mt7620_mdio_read()
Dgsw_mt7620.h262 int mt7620_mdio_write(struct mii_bus *bus, int phy_addr, int phy_reg, u16 val);
263 int mt7620_mdio_read(struct mii_bus *bus, int phy_addr, int phy_reg);
272 u32 _mt7620_mii_write(struct mt7620_gsw *gsw, u32 phy_addr,
274 u32 _mt7620_mii_read(struct mt7620_gsw *gsw, int phy_addr, int phy_reg);
/Linux-v4.19/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()
/Linux-v4.19/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
820 cphy_init(phy, adapter, phy_addr, &ael2020_ops, mdio_ops, in t3_ael2020_phy_prep()
871 int phy_addr, const struct mdio_ops *mdio_ops) in t3_qt2045_phy_prep() argument
875 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 …]
/Linux-v4.19/arch/arm/mach-mv78xx0/
Ddb78x00-bp-setup.c24 .phy_addr = MV643XX_ETH_PHY_ADDR(8),
28 .phy_addr = MV643XX_ETH_PHY_ADDR(9),
32 .phy_addr = MV643XX_ETH_PHY_ADDR(10),
36 .phy_addr = MV643XX_ETH_PHY_ADDR(11),
Drd78x00-masa-setup.c23 .phy_addr = MV643XX_ETH_PHY_ADDR(8),
27 .phy_addr = MV643XX_ETH_PHY_ADDR(9),
/Linux-v4.19/drivers/net/ethernet/dec/tulip/
Ddmfe.c254 u8 phy_addr; member
628 db->phy_addr = 1; in dmfe_init_dm910x()
767 dmfe_phy_write(ioaddr, db->phy_addr, 0, 0x8000, db->chip_id); in dmfe_stop()
1151 dmfe_phy_write(ioaddr, db->phy_addr, 0, 0x1000, db->chip_id); in dmfe_timer()
1227 dmfe_phy_read (db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_timer()
1229 db->phy_addr, 1, db->chip_id) & 0x4) ? 1 : 0; in dmfe_timer()
1244 dmfe_phy_write(db->ioaddr, db->phy_addr, in dmfe_timer()
1646 phy_mode = dmfe_phy_read(db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_sense_speed()
1647 phy_mode = dmfe_phy_read(db->ioaddr, db->phy_addr, 1, db->chip_id); in dmfe_sense_speed()
1652 db->phy_addr, 7, db->chip_id) & 0xf000; in dmfe_sense_speed()
[all …]
Duli526x.c171 u8 phy_addr; member
528 db->phy_addr = 1; in uli526x_init()
534 db->phy_addr = phy_tmp; in uli526x_init()
545 phy_reg_reset = phy->read(db, db->phy_addr, 0); in uli526x_init()
547 phy->write(db, db->phy_addr, 0, phy_reg_reset); in uli526x_init()
554 while (timeout-- && phy->read(db, db->phy_addr, 0) & 0x8000) in uli526x_init()
673 db->phy.write(db, db->phy_addr, 0, 0x8000); in uli526x_stop()
952 cmd->base.phy_address = db->phy_addr; in ULi_ethtool_get_link_ksettings()
1070 if ((phy->read(db, db->phy_addr, 5) & 0x01e0)!=0) in uli526x_timer()
1083 phy->write(db, db->phy_addr, 0, 0x1000); in uli526x_timer()
[all …]
/Linux-v4.19/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,
/Linux-v4.19/drivers/net/ethernet/stmicro/stmmac/
Dstmmac_pci.c35 int phy_addr; member
65 return func_data->phy_addr; in stmmac_pci_find_phy_addr()
107 plat->phy_addr = 0; in stmmac_default_data()
124 .phy_addr = 1,
136 .phy_addr = 1,
140 .phy_addr = 1,
208 plat->phy_addr = ret; in quark_default_data()
Dchain_mode.c108 static void init_dma_chain(void *des, dma_addr_t phy_addr, in init_dma_chain() argument
116 dma_addr_t dma_phy = phy_addr; in init_dma_chain()
125 p->basic.des3 = cpu_to_le32((unsigned int)phy_addr); in init_dma_chain()
134 p->des3 = cpu_to_le32((unsigned int)phy_addr); in init_dma_chain()
/Linux-v4.19/drivers/net/ethernet/sis/
Dsis900.c149 int phy_addr; member
240 static u16 sis900_reset_phy(struct net_device *net_dev, int phy_addr);
241 static void sis900_auto_negotiate(struct net_device *net_dev, int phy_addr);
600 int phy_addr; in sis900_mii_probe() local
605 for (phy_addr = 0; phy_addr < 32; phy_addr++) { in sis900_mii_probe()
612 mii_status = mdio_read(net_dev, phy_addr, MII_STATUS); in sis900_mii_probe()
618 dev_name, phy_addr); in sis900_mii_probe()
633 mii_phy->phy_id0 = mdio_read(net_dev, phy_addr, MII_PHY_ID0); in sis900_mii_probe()
634 mii_phy->phy_id1 = mdio_read(net_dev, phy_addr, MII_PHY_ID1); in sis900_mii_probe()
635 mii_phy->phy_addr = phy_addr; in sis900_mii_probe()
[all …]
/Linux-v4.19/drivers/crypto/qat/qat_common/
Dadf_admin.c146 dma_addr_t phy_addr; member
248 &admin->phy_addr, GFP_KERNEL); in adf_init_admin_comms()
262 admin->virt_addr, admin->phy_addr); in adf_init_admin_comms()
268 reg_val = (u64)admin->phy_addr; in adf_init_admin_comms()
287 admin->virt_addr, admin->phy_addr); in adf_exit_admin_comms()
/Linux-v4.19/drivers/net/ethernet/amd/
Dau1000_eth.c289 static int au1000_mdio_read(struct net_device *dev, int phy_addr, int reg) in au1000_mdio_read() argument
306 MAC_SET_MII_SELECT_PHY(phy_addr) | MAC_MII_READ; in au1000_mdio_read()
321 static void au1000_mdio_write(struct net_device *dev, int phy_addr, in au1000_mdio_write() argument
339 MAC_SET_MII_SELECT_PHY(phy_addr) | MAC_MII_WRITE; in au1000_mdio_write()
345 static int au1000_mdiobus_read(struct mii_bus *bus, int phy_addr, int regnum) in au1000_mdiobus_read() argument
354 return au1000_mdio_read(dev, phy_addr, regnum); in au1000_mdiobus_read()
357 static int au1000_mdiobus_write(struct mii_bus *bus, int phy_addr, int regnum, in au1000_mdiobus_write() argument
367 au1000_mdio_write(dev, phy_addr, regnum, value); in au1000_mdiobus_write()
496 int phy_addr; in au1000_mii_probe() local
501 if (aup->phy_addr) in au1000_mii_probe()
[all …]
/Linux-v4.19/drivers/staging/netlogic/
Dxlr_net.c168 return mdiobus_get_phy(priv->mii_bus, priv->phy_addr); in xlr_get_phydev()
629 static int xlr_phy_write(u32 *base_addr, int phy_addr, int regnum, u16 val) in xlr_phy_write() argument
639 xlr_nae_wreg(base_addr, R_MII_MGMT_ADDRESS, (phy_addr << 8) | regnum); in xlr_phy_write()
659 static int xlr_phy_read(u32 *base_addr, int phy_addr, int regnum) in xlr_phy_read() argument
671 (phy_addr << 8) | (regnum << 0)); in xlr_phy_read()
696 static int xlr_mii_write(struct mii_bus *bus, int phy_addr, int regnum, u16 val) in xlr_mii_write() argument
701 ret = xlr_phy_write(priv->mii_addr, phy_addr, regnum, val); in xlr_mii_write()
703 phy_addr, regnum, val, ret); in xlr_mii_write()
707 static int xlr_mii_read(struct mii_bus *bus, int phy_addr, int regnum) in xlr_mii_read() argument
712 ret = xlr_phy_read(priv->mii_addr, phy_addr, regnum); in xlr_mii_read()
[all …]
Dplatform_net.c122 ndata1.phy_addr[mac] = mac + 4 + 0x10; in gmac_controller2_init()
168 ndata0.phy_addr[0] = 0; in xls_gmac_init()
183 ndata0.phy_addr[mac] = mac + 0x10; in xls_gmac_init()
224 ndata0.phy_addr[mac] = mac; in xlr_gmac_init()
/Linux-v4.19/arch/mips/cavium-octeon/
Docteon-platform.c461 static void __init octeon_fdt_set_phy(int eth, int phy_addr) in octeon_fdt_set_phy() argument
489 if (phy_addr < 0 || phy < 0) { in octeon_fdt_set_phy()
501 if (phy_addr >= 256 && alt_phy > 0) { in octeon_fdt_set_phy()
516 phy_addr &= 0xff; in octeon_fdt_set_phy()
530 if (phy_addr == be32_to_cpup(reg)) in octeon_fdt_set_phy()
533 fdt_setprop_inplace_cell(initial_boot_params, phy, "reg", phy_addr); in octeon_fdt_set_phy()
535 snprintf(new_name, sizeof(new_name), "ethernet-phy@%x", phy_addr); in octeon_fdt_set_phy()
593 int phy_addr; in octeon_fdt_pip_port() local
610 phy_addr = cvmx_helper_board_get_mii_address(ipd_port); in octeon_fdt_pip_port()
611 octeon_fdt_set_phy(eth, phy_addr); in octeon_fdt_pip_port()
[all …]
/Linux-v4.19/drivers/net/ethernet/intel/i40evf/
Di40e_prototype.h101 u16 reg, u8 phy_addr, u16 *value);
103 u16 reg, u8 phy_addr, u16 value);
105 u8 phy_addr, u16 *value);
107 u8 phy_addr, u16 value);

1234567