Lines Matching refs:emac
19 void emac_update_hardware_stats(struct prueth_emac *emac) in emac_update_hardware_stats() argument
21 struct prueth *prueth = emac->prueth; in emac_update_hardware_stats()
22 int slice = prueth_emac_slice(emac); in emac_update_hardware_stats()
39 emac->stats[i] += val; in emac_update_hardware_stats()
41 emac->stats[i] -= tx_pkt_cnt * 8; in emac_update_hardware_stats()
47 struct prueth_emac *emac = container_of(work, struct prueth_emac, in emac_stats_work_handler() local
49 emac_update_hardware_stats(emac); in emac_stats_work_handler()
51 queue_delayed_work(system_long_wq, &emac->stats_work, in emac_stats_work_handler()
52 msecs_to_jiffies((STATS_TIME_LIMIT_1G_MS * 1000) / emac->speed)); in emac_stats_work_handler()
55 int emac_get_stat_by_name(struct prueth_emac *emac, char *stat_name) in emac_get_stat_by_name() argument
61 return emac->stats[icssg_all_stats[i].offset / sizeof(u32)]; in emac_get_stat_by_name()
64 netdev_err(emac->ndev, "Invalid stats %s\n", stat_name); in emac_get_stat_by_name()