Lines Matching refs:mac_dev
93 return csrrd32(priv->mac_dev, in sgmii_pcs_read()
100 csrwr32(value, priv->mac_dev, tse_csroffs(mdio_phy0) + regnum * 4); in sgmii_pcs_write()
118 csrwr32((mii_id & 0x1f), priv->mac_dev, in altera_tse_mdio_read()
122 return csrrd32(priv->mac_dev, in altera_tse_mdio_read()
133 csrwr32((mii_id & 0x1f), priv->mac_dev, in altera_tse_mdio_write()
137 csrwr32(value, priv->mac_dev, tse_csroffs(mdio_phy1) + regnum * 4); in altera_tse_mdio_write()
634 u32 cfg_reg = ioread32(&priv->mac_dev->command_config); in altera_tse_adjust_link()
674 iowrite32(cfg_reg, &priv->mac_dev->command_config); in altera_tse_adjust_link()
861 csrwr32(msb, priv->mac_dev, tse_csroffs(mac_addr_0)); in tse_update_mac_addr()
862 csrwr32(lsb, priv->mac_dev, tse_csroffs(mac_addr_1)); in tse_update_mac_addr()
876 dat = csrrd32(priv->mac_dev, tse_csroffs(command_config)); in reset_mac()
879 csrwr32(dat, priv->mac_dev, tse_csroffs(command_config)); in reset_mac()
883 if (tse_bit_is_clear(priv->mac_dev, tse_csroffs(command_config), in reset_mac()
890 dat = csrrd32(priv->mac_dev, tse_csroffs(command_config)); in reset_mac()
892 csrwr32(dat, priv->mac_dev, tse_csroffs(command_config)); in reset_mac()
907 priv->mac_dev, tse_csroffs(rx_section_empty)); in init_mac()
909 csrwr32(ALTERA_TSE_RX_SECTION_FULL, priv->mac_dev, in init_mac()
912 csrwr32(ALTERA_TSE_RX_ALMOST_EMPTY, priv->mac_dev, in init_mac()
915 csrwr32(ALTERA_TSE_RX_ALMOST_FULL, priv->mac_dev, in init_mac()
920 priv->mac_dev, tse_csroffs(tx_section_empty)); in init_mac()
922 csrwr32(ALTERA_TSE_TX_SECTION_FULL, priv->mac_dev, in init_mac()
925 csrwr32(ALTERA_TSE_TX_ALMOST_EMPTY, priv->mac_dev, in init_mac()
928 csrwr32(ALTERA_TSE_TX_ALMOST_FULL, priv->mac_dev, in init_mac()
936 csrwr32(frm_length, priv->mac_dev, tse_csroffs(frm_length)); in init_mac()
938 csrwr32(ALTERA_TSE_TX_IPG_LENGTH, priv->mac_dev, in init_mac()
944 tse_set_bit(priv->mac_dev, tse_csroffs(rx_cmd_stat), in init_mac()
947 tse_clear_bit(priv->mac_dev, tse_csroffs(tx_cmd_stat), in init_mac()
952 cmd = csrrd32(priv->mac_dev, tse_csroffs(command_config)); in init_mac()
967 csrwr32(cmd, priv->mac_dev, tse_csroffs(command_config)); in init_mac()
969 csrwr32(ALTERA_TSE_PAUSE_QUANTA, priv->mac_dev, in init_mac()
983 u32 value = csrrd32(priv->mac_dev, tse_csroffs(command_config)); in tse_set_mac()
990 csrwr32(value, priv->mac_dev, tse_csroffs(command_config)); in tse_set_mac()
1016 csrwr32(0, priv->mac_dev, tse_csroffs(hash_table) + i * 4); in altera_tse_set_mcfilter()
1032 csrwr32(1, priv->mac_dev, tse_csroffs(hash_table) + hash * 4); in altera_tse_set_mcfilter()
1044 csrwr32(1, priv->mac_dev, tse_csroffs(hash_table) + i * 4); in altera_tse_set_mcfilterall()
1056 tse_set_bit(priv->mac_dev, tse_csroffs(command_config), in tse_set_rx_mode_hashfilter()
1077 tse_set_bit(priv->mac_dev, tse_csroffs(command_config), in tse_set_rx_mode()
1080 tse_clear_bit(priv->mac_dev, tse_csroffs(command_config), in tse_set_rx_mode()
1447 (void __iomem **)&priv->mac_dev); in altera_tse_probe()
1580 priv->revision = ioread32(&priv->mac_dev->megacore_revision); in altera_tse_probe()