/kernel/linux/linux-5.10/drivers/net/phy/ |
D | fixed_phy.c | 73 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 …]
|
D | phy-core.c | 445 static void mmd_phy_indirect(struct mii_bus *bus, int phy_addr, int devad, in mmd_phy_indirect() argument 449 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, devad); in mmd_phy_indirect() 452 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, regnum); in mmd_phy_indirect() 455 __mdiobus_write(bus, phy_addr, MII_MMD_CTRL, in mmd_phy_indirect() 482 int phy_addr = phydev->mdio.addr; in __phy_read_mmd() local 484 mmd_phy_indirect(bus, phy_addr, devad, regnum); in __phy_read_mmd() 487 val = __mdiobus_read(bus, phy_addr, MII_MMD_DATA); in __phy_read_mmd() 538 int phy_addr = phydev->mdio.addr; in __phy_write_mmd() local 540 mmd_phy_indirect(bus, phy_addr, devad, regnum); in __phy_write_mmd() 543 __mdiobus_write(bus, phy_addr, MII_MMD_DATA, val); in __phy_write_mmd()
|
/kernel/linux/linux-5.10/arch/mips/cavium-octeon/executive/ |
D | cvmx-bootmem.c | 430 int __cvmx_bootmem_phy_free(uint64_t phy_addr, uint64_t size, uint32_t flags) in __cvmx_bootmem_phy_free() argument 438 (unsigned long long)phy_addr, (unsigned long long)size); in __cvmx_bootmem_phy_free() 456 if (cur_addr == 0 || phy_addr < cur_addr) { in __cvmx_bootmem_phy_free() 458 if (cur_addr && phy_addr + size > cur_addr) in __cvmx_bootmem_phy_free() 460 else if (phy_addr + size == cur_addr) { in __cvmx_bootmem_phy_free() 462 cvmx_bootmem_phy_set_next(phy_addr, in __cvmx_bootmem_phy_free() 465 cvmx_bootmem_phy_set_size(phy_addr, in __cvmx_bootmem_phy_free() 468 cvmx_bootmem_desc->head_addr = phy_addr; in __cvmx_bootmem_phy_free() 472 cvmx_bootmem_phy_set_next(phy_addr, cur_addr); in __cvmx_bootmem_phy_free() 473 cvmx_bootmem_phy_set_size(phy_addr, size); in __cvmx_bootmem_phy_free() [all …]
|
/kernel/linux/linux-5.10/drivers/net/ethernet/samsung/sxgbe/ |
D | sxgbe_mdio.c | 145 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()
|
/kernel/linux/linux-5.10/drivers/net/ethernet/dlink/ |
D | dl2k.c | 84 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 …]
|
/kernel/linux/linux-5.10/drivers/net/ethernet/arc/ |
D | emac_mdio.c | 56 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()
|
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb3/ |
D | aq100x.c | 266 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()
|
D | ael1002.c | 213 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 …]
|
D | common.h | 157 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 …]
|
/kernel/linux/linux-5.10/arch/arm/mach-mv78xx0/ |
D | db78x00-bp-setup.c | 24 .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),
|
D | rd78x00-masa-setup.c | 23 .phy_addr = MV643XX_ETH_PHY_ADDR(8), 27 .phy_addr = MV643XX_ETH_PHY_ADDR(9),
|
/kernel/linux/linux-5.10/drivers/net/ethernet/aquantia/atlantic/ |
D | aq_phy.c | 28 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()
|
/kernel/linux/linux-5.10/drivers/net/ethernet/dec/tulip/ |
D | dmfe.c | 244 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 …]
|
D | uli526x.c | 161 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 …]
|
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb/ |
D | cphy.h | 45 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,
|
/kernel/linux/linux-5.10/drivers/net/ethernet/sis/ |
D | sis900.c | 149 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 …]
|
/kernel/linux/linux-5.10/drivers/net/ethernet/amd/ |
D | au1000_eth.c | 269 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 …]
|
/kernel/linux/linux-5.10/drivers/crypto/qat/qat_common/ |
D | adf_admin.c | 105 dma_addr_t phy_addr; member 237 &admin->phy_addr, GFP_KERNEL); in adf_init_admin_comms() 251 admin->virt_addr, admin->phy_addr); in adf_init_admin_comms() 257 reg_val = (u64)admin->phy_addr; in adf_init_admin_comms() 276 admin->virt_addr, admin->phy_addr); in adf_exit_admin_comms()
|
/kernel/linux/linux-5.10/drivers/net/mdio/ |
D | mdio-ipq8064.c | 53 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()
|
/kernel/linux/linux-5.10/drivers/staging/netlogic/ |
D | xlr_net.c | 140 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 …]
|
D | platform_net.c | 94 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()
|
/kernel/linux/linux-5.10/drivers/net/ethernet/stmicro/stmmac/ |
D | chain_mode.c | 98 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()
|
/kernel/linux/linux-5.10/drivers/net/ethernet/hisilicon/hns3/hns3pf/ |
D | hclge_mdio.c | 132 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()
|
/kernel/linux/linux-5.10/arch/mips/cavium-octeon/ |
D | octeon-platform.c | 480 static void __init octeon_fdt_set_phy(int eth, int phy_addr) in octeon_fdt_set_phy() argument 508 if (phy_addr < 0 || phy < 0) { in octeon_fdt_set_phy() 520 if (phy_addr >= 256 && alt_phy > 0) { in octeon_fdt_set_phy() 535 phy_addr &= 0xff; in octeon_fdt_set_phy() 549 if (phy_addr == be32_to_cpup(reg)) in octeon_fdt_set_phy() 552 fdt_setprop_inplace_cell(initial_boot_params, phy, "reg", phy_addr); in octeon_fdt_set_phy() 554 snprintf(new_name, sizeof(new_name), "ethernet-phy@%x", phy_addr); in octeon_fdt_set_phy() 651 int phy_addr; in octeon_fdt_pip_port() local 669 phy_addr = cvmx_helper_board_get_mii_address(ipd_port); in octeon_fdt_pip_port() 670 octeon_fdt_set_phy(eth, phy_addr); in octeon_fdt_pip_port() [all …]
|
/kernel/linux/linux-5.10/drivers/net/ethernet/qualcomm/emac/ |
D | emac-phy.c | 111 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()
|