Home
last modified time | relevance | path

Searched refs:ipd_port (Results 1 – 18 of 18) sorted by relevance

/Linux-v4.19/arch/mips/cavium-octeon/executive/
Dcvmx-helper-board.c62 int cvmx_helper_board_get_mii_address(int ipd_port) in cvmx_helper_board_get_mii_address() argument
73 if ((ipd_port >= 16) && (ipd_port < 20)) in cvmx_helper_board_get_mii_address()
74 return ipd_port - 16; in cvmx_helper_board_get_mii_address()
87 if (ipd_port == 0) in cvmx_helper_board_get_mii_address()
89 else if (ipd_port == 1) in cvmx_helper_board_get_mii_address()
95 if ((ipd_port >= 0) && (ipd_port < 4)) in cvmx_helper_board_get_mii_address()
96 return ipd_port; in cvmx_helper_board_get_mii_address()
97 else if ((ipd_port >= 16) && (ipd_port < 20)) in cvmx_helper_board_get_mii_address()
98 return ipd_port - 16 + 4; in cvmx_helper_board_get_mii_address()
108 if ((ipd_port >= CVMX_HELPER_BOARD_MGMT_IPD_PORT) && in cvmx_helper_board_get_mii_address()
[all …]
Dcvmx-helper-spi.c112 int ipd_port; in __cvmx_helper_spi_enable() local
113 for (ipd_port = interface * 16; ipd_port < interface * 16 + num_ports; in __cvmx_helper_spi_enable()
114 ipd_port++) { in __cvmx_helper_spi_enable()
116 port_config.u64 = cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_spi_enable()
118 cvmx_write_csr(CVMX_PIP_PRT_CFGX(ipd_port), port_config.u64); in __cvmx_helper_spi_enable()
143 cvmx_helper_link_info_t __cvmx_helper_spi_link_get(int ipd_port) in __cvmx_helper_spi_link_get() argument
146 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_spi_link_get()
147 int index = cvmx_helper_get_interface_index_num(ipd_port); in __cvmx_helper_spi_link_get()
196 int __cvmx_helper_spi_link_set(int ipd_port, cvmx_helper_link_info_t link_info) in __cvmx_helper_spi_link_set() argument
Dcvmx-helper.c67 void (*cvmx_override_ipd_port_setup) (int ipd_port);
404 static int __cvmx_helper_port_setup_ipd(int ipd_port) in __cvmx_helper_port_setup_ipd() argument
409 port_config.u64 = cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_port_setup_ipd()
410 tag_config.u64 = cvmx_read_csr(CVMX_PIP_PRT_TAGX(ipd_port)); in __cvmx_helper_port_setup_ipd()
413 port_config.s.qos = ipd_port & 0x7; in __cvmx_helper_port_setup_ipd()
437 cvmx_pip_config_port(ipd_port, port_config, tag_config); in __cvmx_helper_port_setup_ipd()
441 cvmx_override_ipd_port_setup(ipd_port); in __cvmx_helper_port_setup_ipd()
600 int ipd_port = cvmx_helper_get_ipd_port(interface, 0); in __cvmx_helper_interface_setup_ipd() local
604 __cvmx_helper_port_setup_ipd(ipd_port); in __cvmx_helper_interface_setup_ipd()
605 ipd_port++; in __cvmx_helper_interface_setup_ipd()
[all …]
Dcvmx-helper-util.c401 int cvmx_helper_get_interface_num(int ipd_port) in cvmx_helper_get_interface_num() argument
403 if (ipd_port < 16) in cvmx_helper_get_interface_num()
405 else if (ipd_port < 32) in cvmx_helper_get_interface_num()
407 else if (ipd_port < 36) in cvmx_helper_get_interface_num()
409 else if (ipd_port < 40) in cvmx_helper_get_interface_num()
411 else if (ipd_port < 44) in cvmx_helper_get_interface_num()
413 else if (ipd_port < 48) in cvmx_helper_get_interface_num()
431 int cvmx_helper_get_interface_index_num(int ipd_port) in cvmx_helper_get_interface_index_num() argument
433 if (ipd_port < 32) in cvmx_helper_get_interface_index_num()
434 return ipd_port & 15; in cvmx_helper_get_interface_index_num()
[all …]
Dcvmx-helper-rgmii.c264 cvmx_helper_link_info_t __cvmx_helper_rgmii_link_get(int ipd_port) in __cvmx_helper_rgmii_link_get() argument
266 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_rgmii_link_get()
267 int index = cvmx_helper_get_interface_index_num(ipd_port); in __cvmx_helper_rgmii_link_get()
280 return __cvmx_helper_board_link_get(ipd_port); in __cvmx_helper_rgmii_link_get()
294 int __cvmx_helper_rgmii_link_set(int ipd_port, in __cvmx_helper_rgmii_link_set() argument
298 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_rgmii_link_set()
299 int index = cvmx_helper_get_interface_index_num(ipd_port); in __cvmx_helper_rgmii_link_set()
324 for (i = 0; i < cvmx_pko_get_num_queues(ipd_port); i++) { in __cvmx_helper_rgmii_link_set()
325 int queue = cvmx_pko_get_base_queue(ipd_port) + i; in __cvmx_helper_rgmii_link_set()
328 pko_mem_queue_qos.s.pid = ipd_port; in __cvmx_helper_rgmii_link_set()
[all …]
Dcvmx-helper-sgmii.c314 int ipd_port = cvmx_helper_get_ipd_port(interface, index); in __cvmx_helper_sgmii_hardware_init() local
322 __cvmx_helper_sgmii_link_set(ipd_port, in __cvmx_helper_sgmii_hardware_init()
323 __cvmx_helper_sgmii_link_get(ipd_port)); in __cvmx_helper_sgmii_hardware_init()
397 cvmx_helper_link_info_t __cvmx_helper_sgmii_link_get(int ipd_port) in __cvmx_helper_sgmii_link_get() argument
401 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_sgmii_link_get()
402 int index = cvmx_helper_get_interface_index_num(ipd_port); in __cvmx_helper_sgmii_link_get()
490 result = __cvmx_helper_board_link_get(ipd_port); in __cvmx_helper_sgmii_link_get()
507 int __cvmx_helper_sgmii_link_set(int ipd_port, in __cvmx_helper_sgmii_link_set() argument
510 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_sgmii_link_set()
511 int index = cvmx_helper_get_interface_index_num(ipd_port); in __cvmx_helper_sgmii_link_set()
[all …]
Dcvmx-helper-loop.c58 int ipd_port = cvmx_helper_get_ipd_port(interface, port); in __cvmx_helper_loop_probe() local
59 port_cfg.u64 = cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_loop_probe()
62 cvmx_write_csr(CVMX_PIP_PRT_CFGX(ipd_port), port_cfg.u64); in __cvmx_helper_loop_probe()
Dcvmx-helper-npi.c100 int ipd_port = in __cvmx_helper_npi_enable() local
103 cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_npi_enable()
106 cvmx_write_csr(CVMX_PIP_PRT_CFGX(ipd_port), in __cvmx_helper_npi_enable()
Dcvmx-helper-xaui.c262 cvmx_helper_link_info_t __cvmx_helper_xaui_link_get(int ipd_port) in __cvmx_helper_xaui_link_get() argument
264 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_xaui_link_get()
302 int __cvmx_helper_xaui_link_set(int ipd_port, cvmx_helper_link_info_t link_info) in __cvmx_helper_xaui_link_set() argument
304 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_xaui_link_set()
336 extern int __cvmx_helper_xaui_configure_loopback(int ipd_port, in __cvmx_helper_xaui_configure_loopback() argument
340 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_xaui_configure_loopback()
/Linux-v4.19/drivers/staging/octeon/
Dethernet-util.h30 static inline int INTERFACE(int ipd_port) in INTERFACE() argument
34 if (ipd_port == CVMX_PIP_NUM_INPUT_PORTS) in INTERFACE()
36 interface = cvmx_helper_get_interface_num(ipd_port); in INTERFACE()
39 panic("Illegal ipd_port %d passed to %s\n", ipd_port, __func__); in INTERFACE()
48 static inline int INDEX(int ipd_port) in INDEX() argument
50 return cvmx_helper_get_interface_index_num(ipd_port); in INDEX()
/Linux-v4.19/arch/mips/include/asm/octeon/
Dcvmx-helper.h91 extern void (*cvmx_override_ipd_port_setup) (int ipd_port);
168 extern cvmx_helper_link_info_t cvmx_helper_link_get(int ipd_port);
181 extern int cvmx_helper_link_set(int ipd_port,
211 extern int cvmx_helper_configure_loopback(int ipd_port, int enable_internal,
Dcvmx-helper-sgmii.h71 extern cvmx_helper_link_info_t __cvmx_helper_sgmii_link_get(int ipd_port);
84 extern int __cvmx_helper_sgmii_link_set(int ipd_port,
100 extern int __cvmx_helper_sgmii_configure_loopback(int ipd_port,
Dcvmx-helper-xaui.h71 extern cvmx_helper_link_info_t __cvmx_helper_xaui_link_get(int ipd_port);
84 extern int __cvmx_helper_xaui_link_set(int ipd_port,
100 extern int __cvmx_helper_xaui_configure_loopback(int ipd_port,
Dcvmx-helper-rgmii.h77 extern cvmx_helper_link_info_t __cvmx_helper_rgmii_link_get(int ipd_port);
90 extern int __cvmx_helper_rgmii_link_set(int ipd_port,
106 extern int __cvmx_helper_rgmii_configure_loopback(int ipd_port,
Dcvmx-helper-spi.h68 extern cvmx_helper_link_info_t __cvmx_helper_spi_link_get(int ipd_port);
81 extern int __cvmx_helper_spi_link_set(int ipd_port,
Dcvmx-helper-board.h76 extern int cvmx_helper_board_get_mii_address(int ipd_port);
96 extern cvmx_helper_link_info_t __cvmx_helper_board_link_get(int ipd_port);
Dcvmx-helper-util.h203 extern int cvmx_helper_get_interface_num(int ipd_port);
213 extern int cvmx_helper_get_interface_index_num(int ipd_port);
/Linux-v4.19/arch/mips/cavium-octeon/
Docteon-platform.c594 int ipd_port; in octeon_fdt_pip_port() local
606 ipd_port = (0x100 * i) + (0x10 * p) + 0x800; in octeon_fdt_pip_port()
608 ipd_port = 16 * i + p; in octeon_fdt_pip_port()
610 phy_addr = cvmx_helper_board_get_mii_address(ipd_port); in octeon_fdt_pip_port()