Home
last modified time | relevance | path

Searched refs:cpsw (Results 1 - 19 of 19) sorted by relevance

/kernel/linux/linux-5.10/drivers/net/ethernet/ti/
H A Dcpsw_new.c35 #include "cpsw.h"
51 struct cpsw_common *cpsw; member
63 static int cpsw_slave_index_priv(struct cpsw_common *cpsw, in cpsw_slave_index_priv() argument
72 static bool cpsw_is_switch_en(struct cpsw_common *cpsw) in cpsw_is_switch_en() argument
74 return !cpsw->data.dual_emac; in cpsw_is_switch_en()
79 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); in cpsw_set_promiscious() local
83 if (cpsw_is_switch_en(cpsw)) in cpsw_set_promiscious()
90 for (i = 0; i < cpsw->data.slaves; i++) in cpsw_set_promiscious()
91 if (cpsw->slaves[i].ndev && in cpsw_set_promiscious()
92 (cpsw in cpsw_set_promiscious()
126 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mc() local
252 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_rx_mode() local
287 struct cpsw_common *cpsw; cpsw_rx_handler() local
408 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_vlan_ale_entry() local
448 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_add_vid() local
498 struct cpsw_common *cpsw = priv->cpsw; cpsw_restore() local
510 cpsw_init_stp_ale_entry(struct cpsw_common *cpsw) cpsw_init_stp_ale_entry() argument
519 cpsw_init_host_port_switch(struct cpsw_common *cpsw) cpsw_init_host_port_switch() argument
538 cpsw_init_host_port_dual_mac(struct cpsw_common *cpsw) cpsw_init_host_port_dual_mac() argument
556 struct cpsw_common *cpsw = priv->cpsw; cpsw_init_host_port() local
597 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_add_dual_emac_def_ale_entries() local
623 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_add_switch_def_ale_entries() local
657 struct cpsw_common *cpsw = priv->cpsw; cpsw_adjust_link() local
726 struct cpsw_common *cpsw = priv->cpsw; cpsw_slave_open() local
796 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_stop() local
834 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_open() local
925 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_start_xmit() local
986 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_mac_address() local
1022 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_kill_vid() local
1090 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_ndo_poll_controller() local
1127 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_port_parent_id() local
1160 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_drvinfo() local
1172 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_pauseparam() local
1229 cpsw_probe_dt(struct cpsw_common *cpsw) cpsw_probe_dt() argument
1362 cpsw_remove_dt(struct cpsw_common *cpsw) cpsw_remove_dt() argument
1380 cpsw_create_ports(struct cpsw_common *cpsw) cpsw_create_ports() argument
1453 cpsw_unregister_ports(struct cpsw_common *cpsw) cpsw_unregister_ports() argument
1465 cpsw_register_ports(struct cpsw_common *cpsw) cpsw_register_ports() argument
1491 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_port_dev_check() local
1499 cpsw_port_offload_fwd_mark_update(struct cpsw_common *cpsw) cpsw_port_offload_fwd_mark_update() argument
1522 struct cpsw_common *cpsw = priv->cpsw; cpsw_netdevice_port_link() local
1544 struct cpsw_common *cpsw = priv->cpsw; cpsw_netdevice_port_unlink() local
1588 cpsw_register_notifiers(struct cpsw_common *cpsw) cpsw_register_notifiers() argument
1605 cpsw_unregister_notifiers(struct cpsw_common *cpsw) cpsw_unregister_notifiers() argument
1618 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_switch_mode_get() local
1634 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_switch_mode_set() local
1752 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_ale_ctrl_get() local
1771 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_ale_ctrl_set() local
1804 cpsw_register_devlink(struct cpsw_common *cpsw) cpsw_register_devlink() argument
1840 cpsw_unregister_devlink(struct cpsw_common *cpsw) cpsw_unregister_devlink() argument
1867 struct cpsw_common *cpsw; cpsw_probe() local
2059 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove() local
2082 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_suspend() local
2106 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_resume() local
[all...]
H A Dcpsw_ethtool.c18 #include "cpsw.h"
157 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); in cpsw_get_coalesce() local
159 coal->rx_coalesce_usecs = cpsw->coal_intvl; in cpsw_get_coalesce()
171 struct cpsw_common *cpsw = priv->cpsw; in cpsw_set_coalesce() local
175 int_ctrl = readl(&cpsw->wr_regs->int_control); in cpsw_set_coalesce()
176 prescale = cpsw->bus_freq_mhz * 4; in cpsw_set_coalesce()
204 writel(num_interrupts, &cpsw->wr_regs->rx_imax); in cpsw_set_coalesce()
205 writel(num_interrupts, &cpsw->wr_regs->tx_imax); in cpsw_set_coalesce()
212 writel(int_ctrl, &cpsw in cpsw_set_coalesce()
222 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_sset_count() local
253 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_strings() local
275 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_ethtool_stats() local
316 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_wol() local
329 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_wol() local
340 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_regs_len() local
349 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_regs() local
360 struct cpsw_common *cpsw = priv->cpsw; cpsw_ethtool_op_begin() local
384 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_channels() local
400 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_link_ksettings() local
414 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_link_ksettings() local
426 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_eee() local
438 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_eee() local
450 struct cpsw_common *cpsw = priv->cpsw; cpsw_nway_reset() local
461 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_suspend_data_pass() local
487 struct cpsw_common *cpsw = priv->cpsw; cpsw_resume_data_pass() local
510 cpsw_check_ch_settings(struct cpsw_common *cpsw, struct ethtool_channels *ch) cpsw_check_ch_settings() argument
535 struct cpsw_common *cpsw = priv->cpsw; cpsw_update_channels_res() local
582 cpsw_fail(struct cpsw_common *cpsw) cpsw_fail() argument
599 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_channels_common() local
660 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_ringparam() local
672 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_ringparam() local
716 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_ts_info() local
[all...]
H A Dcpsw_priv.c24 #include "cpsw.h"
33 int (*cpsw_slave_index)(struct cpsw_common *cpsw, struct cpsw_priv *priv);
35 void cpsw_intr_enable(struct cpsw_common *cpsw) in cpsw_intr_enable() argument
37 writel_relaxed(0xFF, &cpsw->wr_regs->tx_en); in cpsw_intr_enable()
38 writel_relaxed(0xFF, &cpsw->wr_regs->rx_en); in cpsw_intr_enable()
40 cpdma_ctlr_int_ctrl(cpsw->dma, true); in cpsw_intr_enable()
43 void cpsw_intr_disable(struct cpsw_common *cpsw) in cpsw_intr_disable() argument
45 writel_relaxed(0, &cpsw->wr_regs->tx_en); in cpsw_intr_disable()
46 writel_relaxed(0, &cpsw->wr_regs->rx_en); in cpsw_intr_disable()
48 cpdma_ctlr_int_ctrl(cpsw in cpsw_intr_disable()
87 struct cpsw_common *cpsw = dev_id; cpsw_tx_interrupt() local
103 struct cpsw_common *cpsw = dev_id; cpsw_rx_interrupt() local
119 struct cpsw_common *cpsw = dev_id; cpsw_misc_interrupt() local
131 struct cpsw_common *cpsw = napi_to_cpsw(napi_tx); cpsw_tx_mq_poll() local
163 struct cpsw_common *cpsw = napi_to_cpsw(napi_tx); cpsw_tx_poll() local
181 struct cpsw_common *cpsw = napi_to_cpsw(napi_rx); cpsw_rx_mq_poll() local
213 struct cpsw_common *cpsw = napi_to_cpsw(napi_rx); cpsw_rx_poll() local
233 struct cpsw_common *cpsw = priv->cpsw; cpsw_rx_vlan_encap() local
292 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_tx_timeout() local
308 cpsw_get_common_speed(struct cpsw_common *cpsw) cpsw_get_common_speed() argument
319 cpsw_need_resplit(struct cpsw_common *cpsw) cpsw_need_resplit() argument
346 cpsw_split_res(struct cpsw_common *cpsw) cpsw_split_res() argument
431 cpsw_init_common(struct cpsw_common *cpsw, void __iomem *ss_regs, int ale_ageout, phys_addr_t desc_mem_phys, int descs_pool_size) cpsw_init_common() argument
554 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_v1() local
578 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_v2() local
618 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_set() local
681 struct cpsw_common *cpsw = ndev_to_cpsw(dev); cpsw_hwtstamp_get() local
711 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_ioctl() local
732 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_tx_maxrate() local
790 struct cpsw_common *cpsw = priv->cpsw; cpsw_shp_is_off() local
806 struct cpsw_common *cpsw = priv->cpsw; cpsw_fifo_shp_on() local
822 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_fifo_bw() local
882 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_fifo_rlimit() local
934 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_cbs() local
996 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mqprio() local
1079 struct cpsw_common *cpsw = priv->cpsw; cpsw_mqprio_resume() local
1101 struct cpsw_common *cpsw = priv->cpsw; cpsw_fill_rx_channels() local
1144 cpsw_create_page_pool(struct cpsw_common *cpsw, int size) cpsw_create_page_pool() argument
1164 cpsw_create_rx_pool(struct cpsw_common *cpsw, int ch) cpsw_create_rx_pool() argument
1181 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndev_create_xdp_rxq() local
1210 cpsw_destroy_xdp_rxqs(struct cpsw_common *cpsw) cpsw_destroy_xdp_rxqs() argument
1229 cpsw_create_xdp_rxqs(struct cpsw_common *cpsw) cpsw_create_xdp_rxqs() argument
1291 struct cpsw_common *cpsw = priv->cpsw; cpsw_xdp_tx_frame() local
1328 struct cpsw_common *cpsw = priv->cpsw; cpsw_run_xdp() local
[all...]
H A Dcpsw.c41 #include "cpsw.h"
52 MODULE_PARM_DESC(debug_level, "cpsw debug level (NETIF_MSG bits)");
56 MODULE_PARM_DESC(ale_ageout, "cpsw ale ageout interval (seconds)");
69 struct cpsw_common *cpsw = (priv)->cpsw; \
71 if (cpsw->data.dual_emac) \
72 (func)((cpsw)->slaves + priv->emac_port, ##arg);\
74 for (n = cpsw->data.slaves, \
75 slave = cpsw->slaves; \
80 static int cpsw_slave_index_priv(struct cpsw_common *cpsw, in cpsw_slave_index_priv() argument
96 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_promiscious() local
182 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mc() local
311 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_rx_mode() local
349 struct cpsw_common *cpsw = ndev_to_cpsw(xmeta->ndev); cpsw_rx_handler() local
468 struct cpsw_common *cpsw = priv->cpsw; _cpsw_adjust_link() local
530 struct cpsw_common *cpsw = priv->cpsw; cpsw_adjust_link() local
552 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_dual_emac_def_ale_entries() local
574 struct cpsw_common *cpsw = priv->cpsw; cpsw_slave_open() local
659 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_default_vlan() local
687 struct cpsw_common *cpsw = priv->cpsw; cpsw_init_host_port() local
719 cpsw_slave_stop(struct cpsw_slave *slave, struct cpsw_common *cpsw) cpsw_slave_stop() argument
763 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_open() local
882 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_stop() local
912 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_start_xmit() local
973 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_mac_address() local
1013 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_vlan_ale_entry() local
1059 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_add_vid() local
1097 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_kill_vid() local
1134 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_xdp_xmit() local
1160 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_ndo_poll_controller() local
1192 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_drvinfo() local
1420 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove_dt() local
1449 struct cpsw_common *cpsw = priv->cpsw; cpsw_probe_dual_emac() local
1522 struct cpsw_common *cpsw; cpsw_probe() local
1750 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove() local
1774 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_suspend() local
1794 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_resume() local
[all...]
H A Dcpsw_switchdev.c15 #include "cpsw.h"
30 struct cpsw_common *cpsw = priv->cpsw; in cpsw_port_stp_state_set() local
55 ret = cpsw_ale_control_set(cpsw->ale, priv->emac_port, in cpsw_port_stp_state_set()
67 struct cpsw_common *cpsw = priv->cpsw; in cpsw_port_attr_br_flags_set() local
78 cpsw_ale_set_unreg_mcast(cpsw->ale, BIT(priv->emac_port), in cpsw_port_attr_br_flags_set()
126 struct cpsw_common *cpsw = priv->cpsw; in cpsw_get_pvid() local
133 if (cpsw in cpsw_get_pvid()
148 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_pvid() local
174 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_vlan_add() local
221 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_vlan_del() local
310 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_mdb_add() local
336 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_mdb_del() local
427 struct cpsw_common *cpsw = priv->cpsw; cpsw_switchdev_event_work() local
564 cpsw_switchdev_register_notifiers(struct cpsw_common *cpsw) cpsw_switchdev_register_notifiers() argument
585 cpsw_switchdev_unregister_notifiers(struct cpsw_common *cpsw) cpsw_switchdev_unregister_notifiers() argument
[all...]
H A DMakefile6 obj-$(CONFIG_TI_CPSW) += cpsw-common.o
7 obj-$(CONFIG_TI_DAVINCI_EMAC) += cpsw-common.o
8 obj-$(CONFIG_TI_CPSW_SWITCHDEV) += cpsw-common.o
15 obj-$(CONFIG_TI_CPSW_PHY_SEL) += cpsw-phy-sel.o
18 ti_cpsw-y := cpsw.o davinci_cpdma.o cpsw_ale.o cpsw_priv.o cpsw_sl.o cpsw_ethtool.o
27 obj-$(CONFIG_TI_K3_AM65_CPSW_NUSS) += ti-am65-cpsw-nuss.o
28 ti-am65-cpsw-nuss-y := am65-cpsw-nuss.o cpsw_sl.o am65-cpsw-ethtool.o cpsw_ale.o k3-cppi-desc-pool.o am65-cpsw
[all...]
H A Dcpsw_priv.h382 struct cpsw_common *cpsw; member
387 #define ndev_to_cpsw(ndev) (((struct cpsw_priv *)netdev_priv(ndev))->cpsw)
390 extern int (*cpsw_slave_index)(struct cpsw_common *cpsw,
429 int cpsw_init_common(struct cpsw_common *cpsw, void __iomem *ss_regs,
432 void cpsw_split_res(struct cpsw_common *cpsw);
434 void cpsw_intr_enable(struct cpsw_common *cpsw);
435 void cpsw_intr_disable(struct cpsw_common *cpsw);
437 int cpsw_create_xdp_rxqs(struct cpsw_common *cpsw);
438 void cpsw_destroy_xdp_rxqs(struct cpsw_common *cpsw);
455 int cpsw_need_resplit(struct cpsw_common *cpsw);
[all...]
H A Dcpsw_switchdev.h12 int cpsw_switchdev_register_notifiers(struct cpsw_common *cpsw);
13 void cpsw_switchdev_unregister_notifiers(struct cpsw_common *cpsw);
/kernel/linux/linux-6.6/drivers/net/ethernet/ti/
H A Dcpsw_new.c37 #include "cpsw.h"
53 struct cpsw_common *cpsw; member
65 static int cpsw_slave_index_priv(struct cpsw_common *cpsw, in cpsw_slave_index_priv() argument
74 static bool cpsw_is_switch_en(struct cpsw_common *cpsw) in cpsw_is_switch_en() argument
76 return !cpsw->data.dual_emac; in cpsw_is_switch_en()
81 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); in cpsw_set_promiscious() local
85 if (cpsw_is_switch_en(cpsw)) in cpsw_set_promiscious()
92 for (i = 0; i < cpsw->data.slaves; i++) in cpsw_set_promiscious()
93 if (cpsw->slaves[i].ndev && in cpsw_set_promiscious()
94 (cpsw in cpsw_set_promiscious()
128 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mc() local
254 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_rx_mode() local
289 struct cpsw_common *cpsw; cpsw_rx_handler() local
402 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_vlan_ale_entry() local
442 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_add_vid() local
490 struct cpsw_common *cpsw = priv->cpsw; cpsw_restore() local
504 cpsw_init_stp_ale_entry(struct cpsw_common *cpsw) cpsw_init_stp_ale_entry() argument
513 cpsw_init_host_port_switch(struct cpsw_common *cpsw) cpsw_init_host_port_switch() argument
532 cpsw_init_host_port_dual_mac(struct cpsw_common *cpsw) cpsw_init_host_port_dual_mac() argument
550 struct cpsw_common *cpsw = priv->cpsw; cpsw_init_host_port() local
591 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_add_dual_emac_def_ale_entries() local
617 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_add_switch_def_ale_entries() local
651 struct cpsw_common *cpsw = priv->cpsw; cpsw_adjust_link() local
720 struct cpsw_common *cpsw = priv->cpsw; cpsw_slave_open() local
793 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_stop() local
831 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_open() local
920 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_start_xmit() local
981 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_mac_address() local
1015 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_kill_vid() local
1081 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_ndo_poll_controller() local
1116 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_port_parent_id() local
1149 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_drvinfo() local
1161 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_pauseparam() local
1218 cpsw_probe_dt(struct cpsw_common *cpsw) cpsw_probe_dt() argument
1347 cpsw_remove_dt(struct cpsw_common *cpsw) cpsw_remove_dt() argument
1365 cpsw_create_ports(struct cpsw_common *cpsw) cpsw_create_ports() argument
1439 cpsw_unregister_ports(struct cpsw_common *cpsw) cpsw_unregister_ports() argument
1451 cpsw_register_ports(struct cpsw_common *cpsw) cpsw_register_ports() argument
1477 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_port_dev_check() local
1485 cpsw_port_offload_fwd_mark_update(struct cpsw_common *cpsw) cpsw_port_offload_fwd_mark_update() argument
1509 struct cpsw_common *cpsw = priv->cpsw; cpsw_netdevice_port_link() local
1537 struct cpsw_common *cpsw = priv->cpsw; cpsw_netdevice_port_unlink() local
1585 cpsw_register_notifiers(struct cpsw_common *cpsw) cpsw_register_notifiers() argument
1602 cpsw_unregister_notifiers(struct cpsw_common *cpsw) cpsw_unregister_notifiers() argument
1615 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_switch_mode_get() local
1631 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_switch_mode_set() local
1749 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_ale_ctrl_get() local
1768 struct cpsw_common *cpsw = dl_priv->cpsw; cpsw_dl_ale_ctrl_set() local
1801 cpsw_register_devlink(struct cpsw_common *cpsw) cpsw_register_devlink() argument
1829 cpsw_unregister_devlink(struct cpsw_common *cpsw) cpsw_unregister_devlink() argument
1855 struct cpsw_common *cpsw; cpsw_probe() local
2045 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove() local
2066 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_suspend() local
2090 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_resume() local
[all...]
H A Dcpsw.c41 #include "cpsw.h"
52 MODULE_PARM_DESC(debug_level, "cpsw debug level (NETIF_MSG bits)");
56 MODULE_PARM_DESC(ale_ageout, "cpsw ale ageout interval (seconds)");
69 struct cpsw_common *cpsw = (priv)->cpsw; \
71 if (cpsw->data.dual_emac) \
72 (func)((cpsw)->slaves + priv->emac_port, ##arg);\
74 for (n = cpsw->data.slaves, \
75 slave = cpsw->slaves; \
80 static int cpsw_slave_index_priv(struct cpsw_common *cpsw, in cpsw_slave_index_priv() argument
96 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_promiscious() local
182 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mc() local
311 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_rx_mode() local
349 struct cpsw_common *cpsw = ndev_to_cpsw(xmeta->ndev); cpsw_rx_handler() local
460 struct cpsw_common *cpsw = priv->cpsw; _cpsw_adjust_link() local
522 struct cpsw_common *cpsw = priv->cpsw; cpsw_adjust_link() local
544 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_dual_emac_def_ale_entries() local
566 struct cpsw_common *cpsw = priv->cpsw; cpsw_slave_open() local
653 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_default_vlan() local
681 struct cpsw_common *cpsw = priv->cpsw; cpsw_init_host_port() local
713 cpsw_slave_stop(struct cpsw_slave *slave, struct cpsw_common *cpsw) cpsw_slave_stop() argument
757 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_open() local
874 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_stop() local
904 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_start_xmit() local
965 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_mac_address() local
1003 struct cpsw_common *cpsw = priv->cpsw; cpsw_add_vlan_ale_entry() local
1049 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_add_vid() local
1085 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_vlan_rx_kill_vid() local
1120 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_xdp_xmit() local
1144 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_ndo_poll_controller() local
1176 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_drvinfo() local
1400 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove_dt() local
1429 struct cpsw_common *cpsw = priv->cpsw; cpsw_probe_dual_emac() local
1504 struct cpsw_common *cpsw; cpsw_probe() local
1729 struct cpsw_common *cpsw = platform_get_drvdata(pdev); cpsw_remove() local
1751 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_suspend() local
1771 struct cpsw_common *cpsw = dev_get_drvdata(dev); cpsw_resume() local
[all...]
H A Dcpsw_ethtool.c18 #include "cpsw.h"
159 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); in cpsw_get_coalesce() local
161 coal->rx_coalesce_usecs = cpsw->coal_intvl; in cpsw_get_coalesce()
175 struct cpsw_common *cpsw = priv->cpsw; in cpsw_set_coalesce() local
179 int_ctrl = readl(&cpsw->wr_regs->int_control); in cpsw_set_coalesce()
180 prescale = cpsw->bus_freq_mhz * 4; in cpsw_set_coalesce()
208 writel(num_interrupts, &cpsw->wr_regs->rx_imax); in cpsw_set_coalesce()
209 writel(num_interrupts, &cpsw->wr_regs->tx_imax); in cpsw_set_coalesce()
216 writel(int_ctrl, &cpsw in cpsw_set_coalesce()
226 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_sset_count() local
257 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_strings() local
279 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_ethtool_stats() local
320 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_wol() local
333 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_wol() local
344 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_regs_len() local
353 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_regs() local
364 struct cpsw_common *cpsw = priv->cpsw; cpsw_ethtool_op_begin() local
386 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_channels() local
402 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_link_ksettings() local
416 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_link_ksettings() local
428 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_eee() local
440 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_eee() local
452 struct cpsw_common *cpsw = priv->cpsw; cpsw_nway_reset() local
463 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_suspend_data_pass() local
489 struct cpsw_common *cpsw = priv->cpsw; cpsw_resume_data_pass() local
512 cpsw_check_ch_settings(struct cpsw_common *cpsw, struct ethtool_channels *ch) cpsw_check_ch_settings() argument
537 struct cpsw_common *cpsw = priv->cpsw; cpsw_update_channels_res() local
584 cpsw_fail(struct cpsw_common *cpsw) cpsw_fail() argument
601 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_channels_common() local
664 struct cpsw_common *cpsw = priv->cpsw; cpsw_get_ringparam() local
678 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_set_ringparam() local
722 struct cpsw_common *cpsw = ndev_to_cpsw(ndev); cpsw_get_ts_info() local
[all...]
H A Dcpsw_priv.c25 #include "cpsw.h"
34 int (*cpsw_slave_index)(struct cpsw_common *cpsw, struct cpsw_priv *priv);
36 void cpsw_intr_enable(struct cpsw_common *cpsw) in cpsw_intr_enable() argument
38 writel_relaxed(0xFF, &cpsw->wr_regs->tx_en); in cpsw_intr_enable()
39 writel_relaxed(0xFF, &cpsw->wr_regs->rx_en); in cpsw_intr_enable()
41 cpdma_ctlr_int_ctrl(cpsw->dma, true); in cpsw_intr_enable()
44 void cpsw_intr_disable(struct cpsw_common *cpsw) in cpsw_intr_disable() argument
46 writel_relaxed(0, &cpsw->wr_regs->tx_en); in cpsw_intr_disable()
47 writel_relaxed(0, &cpsw->wr_regs->rx_en); in cpsw_intr_disable()
49 cpdma_ctlr_int_ctrl(cpsw in cpsw_intr_disable()
88 struct cpsw_common *cpsw = dev_id; cpsw_tx_interrupt() local
104 struct cpsw_common *cpsw = dev_id; cpsw_rx_interrupt() local
120 struct cpsw_common *cpsw = dev_id; cpsw_misc_interrupt() local
132 struct cpsw_common *cpsw = napi_to_cpsw(napi_tx); cpsw_tx_mq_poll() local
164 struct cpsw_common *cpsw = napi_to_cpsw(napi_tx); cpsw_tx_poll() local
182 struct cpsw_common *cpsw = napi_to_cpsw(napi_rx); cpsw_rx_mq_poll() local
214 struct cpsw_common *cpsw = napi_to_cpsw(napi_rx); cpsw_rx_poll() local
234 struct cpsw_common *cpsw = priv->cpsw; cpsw_rx_vlan_encap() local
293 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_tx_timeout() local
309 cpsw_get_common_speed(struct cpsw_common *cpsw) cpsw_get_common_speed() argument
320 cpsw_need_resplit(struct cpsw_common *cpsw) cpsw_need_resplit() argument
347 cpsw_split_res(struct cpsw_common *cpsw) cpsw_split_res() argument
432 cpsw_init_common(struct cpsw_common *cpsw, void __iomem *ss_regs, int ale_ageout, phys_addr_t desc_mem_phys, int descs_pool_size) cpsw_init_common() argument
556 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_v1() local
580 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_v2() local
620 struct cpsw_common *cpsw = priv->cpsw; cpsw_hwtstamp_set() local
679 struct cpsw_common *cpsw = ndev_to_cpsw(dev); cpsw_hwtstamp_get() local
709 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_ioctl() local
736 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndo_set_tx_maxrate() local
792 struct cpsw_common *cpsw = priv->cpsw; cpsw_shp_is_off() local
808 struct cpsw_common *cpsw = priv->cpsw; cpsw_fifo_shp_on() local
824 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_fifo_bw() local
884 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_fifo_rlimit() local
936 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_cbs() local
996 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_mqprio() local
1082 struct cpsw_common *cpsw = priv->cpsw; cpsw_mqprio_resume() local
1104 struct cpsw_common *cpsw = priv->cpsw; cpsw_fill_rx_channels() local
1147 cpsw_create_page_pool(struct cpsw_common *cpsw, int size) cpsw_create_page_pool() argument
1167 cpsw_create_rx_pool(struct cpsw_common *cpsw, int ch) cpsw_create_rx_pool() argument
1184 struct cpsw_common *cpsw = priv->cpsw; cpsw_ndev_create_xdp_rxq() local
1213 cpsw_destroy_xdp_rxqs(struct cpsw_common *cpsw) cpsw_destroy_xdp_rxqs() argument
1232 cpsw_create_xdp_rxqs(struct cpsw_common *cpsw) cpsw_create_xdp_rxqs() argument
1294 struct cpsw_common *cpsw = priv->cpsw; cpsw_xdp_tx_frame() local
1327 struct cpsw_common *cpsw = priv->cpsw; cpsw_run_xdp() local
[all...]
H A Dcpsw_switchdev.c15 #include "cpsw.h"
29 struct cpsw_common *cpsw = priv->cpsw; in cpsw_port_stp_state_set() local
51 ret = cpsw_ale_control_set(cpsw->ale, priv->emac_port, in cpsw_port_stp_state_set()
62 struct cpsw_common *cpsw = priv->cpsw; in cpsw_port_attr_br_flags_set() local
73 cpsw_ale_set_unreg_mcast(cpsw->ale, BIT(priv->emac_port), in cpsw_port_attr_br_flags_set()
121 struct cpsw_common *cpsw = priv->cpsw; in cpsw_get_pvid() local
128 if (cpsw in cpsw_get_pvid()
143 struct cpsw_common *cpsw = priv->cpsw; cpsw_set_pvid() local
169 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_vlan_add() local
216 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_vlan_del() local
269 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_mdb_add() local
292 struct cpsw_common *cpsw = priv->cpsw; cpsw_port_mdb_del() local
382 struct cpsw_common *cpsw = priv->cpsw; cpsw_switchdev_event_work() local
519 cpsw_switchdev_register_notifiers(struct cpsw_common *cpsw) cpsw_switchdev_register_notifiers() argument
540 cpsw_switchdev_unregister_notifiers(struct cpsw_common *cpsw) cpsw_switchdev_unregister_notifiers() argument
[all...]
H A DMakefile6 obj-$(CONFIG_TI_CPSW) += cpsw-common.o
7 obj-$(CONFIG_TI_DAVINCI_EMAC) += cpsw-common.o
8 obj-$(CONFIG_TI_CPSW_SWITCHDEV) += cpsw-common.o
15 obj-$(CONFIG_TI_CPSW_PHY_SEL) += cpsw-phy-sel.o
18 ti_cpsw-y := cpsw.o davinci_cpdma.o cpsw_ale.o cpsw_priv.o cpsw_sl.o cpsw_ethtool.o
29 obj-$(CONFIG_TI_K3_AM65_CPSW_NUSS) += ti-am65-cpsw-nuss.o
30 ti-am65-cpsw-nuss-y := am65-cpsw-nuss.o cpsw_sl.o am65-cpsw-ethtool.o cpsw_ale.o am65-cpsw
[all...]
H A Dam65-cpsw-switchdev.c14 #include "am65-cpsw-nuss.h"
15 #include "am65-cpsw-switchdev.h"
27 struct am65_cpsw_common *cpsw = port->common; in am65_cpsw_port_stp_state_set() local
49 ret = cpsw_ale_control_set(cpsw->ale, port->port_id, in am65_cpsw_port_stp_state_set()
60 struct am65_cpsw_common *cpsw = port->common; in am65_cpsw_port_attr_br_flags_set() local
71 cpsw_ale_set_unreg_mcast(cpsw->ale, BIT(port->port_id), in am65_cpsw_port_attr_br_flags_set()
119 struct am65_cpsw_common *cpsw = port->common; in am65_cpsw_get_pvid() local
120 struct am65_cpsw_host *host_p = am65_common_get_host(cpsw); in am65_cpsw_get_pvid()
135 struct am65_cpsw_common *cpsw = port->common; in am65_cpsw_set_pvid() local
136 struct am65_cpsw_host *host_p = am65_common_get_host(cpsw); in am65_cpsw_set_pvid()
153 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_port_vlan_add() local
201 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_port_vlan_del() local
261 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_port_mdb_add() local
284 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_port_mdb_del() local
372 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_switchdev_event_work() local
509 am65_cpsw_switchdev_register_notifiers(struct am65_cpsw_common *cpsw) am65_cpsw_switchdev_register_notifiers() argument
530 am65_cpsw_switchdev_unregister_notifiers(struct am65_cpsw_common *cpsw) am65_cpsw_switchdev_unregister_notifiers() argument
[all...]
H A Dam65-cpsw-switchdev.h16 int am65_cpsw_switchdev_register_notifiers(struct am65_cpsw_common *cpsw);
17 void am65_cpsw_switchdev_unregister_notifiers(struct am65_cpsw_common *cpsw);
19 static inline int am65_cpsw_switchdev_register_notifiers(struct am65_cpsw_common *cpsw) in am65_cpsw_switchdev_register_notifiers() argument
24 static inline void am65_cpsw_switchdev_unregister_notifiers(struct am65_cpsw_common *cpsw) in am65_cpsw_switchdev_unregister_notifiers() argument
H A Dcpsw_priv.h389 struct cpsw_common *cpsw; member
396 #define ndev_to_cpsw(ndev) (((struct cpsw_priv *)netdev_priv(ndev))->cpsw)
399 extern int (*cpsw_slave_index)(struct cpsw_common *cpsw,
437 int cpsw_init_common(struct cpsw_common *cpsw, void __iomem *ss_regs,
440 void cpsw_split_res(struct cpsw_common *cpsw);
442 void cpsw_intr_enable(struct cpsw_common *cpsw);
443 void cpsw_intr_disable(struct cpsw_common *cpsw);
445 int cpsw_create_xdp_rxqs(struct cpsw_common *cpsw);
446 void cpsw_destroy_xdp_rxqs(struct cpsw_common *cpsw);
463 int cpsw_need_resplit(struct cpsw_common *cpsw);
[all...]
H A Dcpsw_switchdev.h12 int cpsw_switchdev_register_notifiers(struct cpsw_common *cpsw);
13 void cpsw_switchdev_unregister_notifiers(struct cpsw_common *cpsw);
H A Dam65-cpsw-nuss.c37 #include "am65-cpsw-nuss.h"
38 #include "am65-cpsw-switchdev.h"
163 "initializing am65 cpsw nuss version 0x%08X, cpsw version 0x%08X Ports: %u quirks:%08x\n", in am65_cpsw_nuss_get_ver()
2383 static int am65_cpsw_register_notifiers(struct am65_cpsw_common *cpsw) in am65_cpsw_register_notifiers() argument
2387 if (AM65_CPSW_IS_CPSW2G(cpsw) || in am65_cpsw_register_notifiers()
2391 cpsw->am65_cpsw_netdevice_nb.notifier_call = &am65_cpsw_netdevice_event; in am65_cpsw_register_notifiers()
2392 ret = register_netdevice_notifier(&cpsw->am65_cpsw_netdevice_nb); in am65_cpsw_register_notifiers()
2394 dev_err(cpsw->dev, "can't register netdevice notifier\n"); in am65_cpsw_register_notifiers()
2398 ret = am65_cpsw_switchdev_register_notifiers(cpsw); in am65_cpsw_register_notifiers()
2405 am65_cpsw_unregister_notifiers(struct am65_cpsw_common *cpsw) am65_cpsw_unregister_notifiers() argument
2417 am65_cpsw_init_stp_ale_entry(struct am65_cpsw_common *cpsw) am65_cpsw_init_stp_ale_entry() argument
2491 struct am65_cpsw_common *cpsw = port->common; am65_cpsw_init_port_switch_ale() local
2517 struct am65_cpsw_common *cpsw = dl_priv->common; am65_cpsw_dl_switch_mode_set() local
[all...]

Completed in 19 milliseconds