Home
last modified time | relevance | path

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

/linux-5.19.10/arch/mips/cavium-octeon/executive/
Dcvmx-helper-board.c63 int cvmx_helper_board_get_mii_address(int ipd_port) in cvmx_helper_board_get_mii_address() argument
74 if ((ipd_port >= 16) && (ipd_port < 20)) in cvmx_helper_board_get_mii_address()
75 return ipd_port - 16; in cvmx_helper_board_get_mii_address()
88 if (ipd_port == 0) in cvmx_helper_board_get_mii_address()
90 else if (ipd_port == 1) in cvmx_helper_board_get_mii_address()
96 if ((ipd_port >= 0) && (ipd_port < 4)) in cvmx_helper_board_get_mii_address()
97 return ipd_port; in cvmx_helper_board_get_mii_address()
98 else if ((ipd_port >= 16) && (ipd_port < 20)) in cvmx_helper_board_get_mii_address()
99 return ipd_port - 16 + 4; in cvmx_helper_board_get_mii_address()
109 if ((ipd_port >= CVMX_HELPER_BOARD_MGMT_IPD_PORT) && in cvmx_helper_board_get_mii_address()
[all …]
Dcvmx-helper-util.c315 int cvmx_helper_get_interface_num(int ipd_port) in cvmx_helper_get_interface_num() argument
317 if (ipd_port < 16) in cvmx_helper_get_interface_num()
319 else if (ipd_port < 32) in cvmx_helper_get_interface_num()
321 else if (ipd_port < 36) in cvmx_helper_get_interface_num()
323 else if (ipd_port < 40) in cvmx_helper_get_interface_num()
325 else if (ipd_port < 44) in cvmx_helper_get_interface_num()
327 else if (ipd_port < 48) in cvmx_helper_get_interface_num()
345 int cvmx_helper_get_interface_index_num(int ipd_port) in cvmx_helper_get_interface_index_num() argument
347 if (ipd_port < 32) in cvmx_helper_get_interface_index_num()
348 return ipd_port & 15; in cvmx_helper_get_interface_index_num()
[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 union cvmx_helper_link_info __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, union cvmx_helper_link_info link_info) in __cvmx_helper_spi_link_set() argument
Dcvmx-helper.c375 static int __cvmx_helper_port_setup_ipd(int ipd_port) in __cvmx_helper_port_setup_ipd() argument
380 port_config.u64 = cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_port_setup_ipd()
381 tag_config.u64 = cvmx_read_csr(CVMX_PIP_PRT_TAGX(ipd_port)); in __cvmx_helper_port_setup_ipd()
384 port_config.s.qos = ipd_port & 0x7; in __cvmx_helper_port_setup_ipd()
408 cvmx_pip_config_port(ipd_port, port_config, tag_config); in __cvmx_helper_port_setup_ipd()
567 int ipd_port = cvmx_helper_get_ipd_port(interface, 0); in __cvmx_helper_interface_setup_ipd() local
571 __cvmx_helper_port_setup_ipd(ipd_port); in __cvmx_helper_interface_setup_ipd()
572 ipd_port++; in __cvmx_helper_interface_setup_ipd()
630 int ipd_port = cvmx_helper_get_ipd_port(interface, 0); in __cvmx_helper_interface_setup_pko() local
633 cvmx_pko_config_port(ipd_port, in __cvmx_helper_interface_setup_pko()
[all …]
Dcvmx-helper-rgmii.c264 union cvmx_helper_link_info __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 union cvmx_helper_link_info __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()
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.c88 int ipd_port = in __cvmx_helper_npi_enable() local
91 cvmx_read_csr(CVMX_PIP_PRT_CFGX(ipd_port)); in __cvmx_helper_npi_enable()
94 cvmx_write_csr(CVMX_PIP_PRT_CFGX(ipd_port), in __cvmx_helper_npi_enable()
Dcvmx-helper-xaui.c263 union cvmx_helper_link_info __cvmx_helper_xaui_link_get(int ipd_port) in __cvmx_helper_xaui_link_get() argument
265 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_xaui_link_get()
303 int __cvmx_helper_xaui_link_set(int ipd_port, union cvmx_helper_link_info link_info) in __cvmx_helper_xaui_link_set() argument
305 int interface = cvmx_helper_get_interface_num(ipd_port); in __cvmx_helper_xaui_link_set()
/linux-5.19.10/drivers/staging/octeon/
Dethernet-util.h26 static inline int INTERFACE(int ipd_port) in INTERFACE() argument
30 if (ipd_port == CVMX_PIP_NUM_INPUT_PORTS) in INTERFACE()
32 interface = cvmx_helper_get_interface_num(ipd_port); in INTERFACE()
35 panic("Illegal ipd_port %d passed to %s\n", ipd_port, __func__); in INTERFACE()
44 static inline int INDEX(int ipd_port) in INDEX() argument
46 return cvmx_helper_get_interface_index_num(ipd_port); in INDEX()
Docteon-stubs.h1220 static inline int cvmx_helper_get_interface_num(int ipd_port) in cvmx_helper_get_interface_num() argument
1222 return ipd_port; in cvmx_helper_get_interface_num()
1225 static inline int cvmx_helper_get_interface_index_num(int ipd_port) in cvmx_helper_get_interface_index_num() argument
1227 return ipd_port; in cvmx_helper_get_interface_index_num()
1274 static inline union cvmx_helper_link_info cvmx_helper_link_get(int ipd_port) in cvmx_helper_link_get() argument
1281 static inline int cvmx_helper_link_set(int ipd_port, in cvmx_helper_link_set() argument
/linux-5.19.10/arch/mips/include/asm/octeon/
Dcvmx-helper-spi.h68 extern union cvmx_helper_link_info __cvmx_helper_spi_link_get(int ipd_port);
81 extern int __cvmx_helper_spi_link_set(int ipd_port,
Dcvmx-helper-sgmii.h71 extern union cvmx_helper_link_info __cvmx_helper_sgmii_link_get(int ipd_port);
84 extern int __cvmx_helper_sgmii_link_set(int ipd_port,
Dcvmx-helper-xaui.h71 extern union cvmx_helper_link_info __cvmx_helper_xaui_link_get(int ipd_port);
84 extern int __cvmx_helper_xaui_link_set(int ipd_port,
Dcvmx-helper-rgmii.h77 extern union cvmx_helper_link_info __cvmx_helper_rgmii_link_get(int ipd_port);
90 extern int __cvmx_helper_rgmii_link_set(int ipd_port,
Dcvmx-helper-board.h76 extern int cvmx_helper_board_get_mii_address(int ipd_port);
96 extern union cvmx_helper_link_info __cvmx_helper_board_link_get(int ipd_port);
Dcvmx-helper.h141 extern union cvmx_helper_link_info cvmx_helper_link_get(int ipd_port);
154 extern int cvmx_helper_link_set(int ipd_port,
Dcvmx-helper-util.h180 extern int cvmx_helper_get_interface_num(int ipd_port);
190 extern int cvmx_helper_get_interface_index_num(int ipd_port);
/linux-5.19.10/arch/mips/cavium-octeon/
Docteon-platform.c464 static bool __init octeon_has_fixed_link(int ipd_port) in octeon_has_fixed_link() argument
473 return ipd_port == 1; in octeon_has_fixed_link()
476 return ipd_port == 0 || ipd_port == 1; in octeon_has_fixed_link()
653 int ipd_port; in octeon_fdt_pip_port() local
666 ipd_port = (0x100 * i) + (0x10 * p) + 0x800; in octeon_fdt_pip_port()
668 ipd_port = 16 * i + p; in octeon_fdt_pip_port()
670 phy_addr = cvmx_helper_board_get_mii_address(ipd_port); in octeon_fdt_pip_port()
675 WARN_ON(octeon_has_fixed_link(ipd_port)); in octeon_fdt_pip_port()
676 else if (!octeon_has_fixed_link(ipd_port)) in octeon_fdt_pip_port()