/kernel/linux/linux-5.10/drivers/net/ethernet/mellanox/mlxsw/ |
H A D | core.h | 22 struct mlxsw_core; 29 unsigned int mlxsw_core_max_ports(const struct mlxsw_core *mlxsw_core); 31 void *mlxsw_core_driver_priv(struct mlxsw_core *mlxsw_core); 33 bool mlxsw_core_res_query_enabled(const struct mlxsw_core *mlxsw_core); 35 bool mlxsw_core_temp_warn_enabled(const struct mlxsw_core *mlxsw_core); 49 void mlxsw_core_bus_device_unregister(struct mlxsw_core *mlxsw_cor 403 mlxsw_core_net(struct mlxsw_core *mlxsw_core) mlxsw_core_net() argument 460 mlxsw_hwmon_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct mlxsw_hwmon **p_hwmon) mlxsw_hwmon_init() argument 484 mlxsw_thermal_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct mlxsw_thermal **p_thermal) mlxsw_thermal_init() argument [all...] |
H A D | core.c | 42 static const char mlxsw_core_driver_name[] = "mlxsw_core"; 64 struct mlxsw_core { struct 99 static int mlxsw_ports_init(struct mlxsw_core *mlxsw_core) in mlxsw_ports_init() argument 102 if (MLXSW_CORE_RES_VALID(mlxsw_core, MAX_SYSTEM_PORT)) in mlxsw_ports_init() 103 mlxsw_core->max_ports = MLXSW_CORE_RES_GET(mlxsw_core, in mlxsw_ports_init() 106 mlxsw_core->max_ports = MLXSW_PORT_MAX_PORTS_DEFAULT + 1; in mlxsw_ports_init() 108 mlxsw_core->ports = kcalloc(mlxsw_core in mlxsw_ports_init() 116 mlxsw_ports_fini(struct mlxsw_core *mlxsw_core) mlxsw_ports_fini() argument 121 mlxsw_core_max_ports(const struct mlxsw_core *mlxsw_core) mlxsw_core_max_ports() argument 127 mlxsw_core_driver_priv(struct mlxsw_core *mlxsw_core) mlxsw_core_driver_priv() argument 133 mlxsw_core_res_query_enabled(const struct mlxsw_core *mlxsw_core) mlxsw_core_res_query_enabled() argument 139 mlxsw_core_temp_warn_enabled(const struct mlxsw_core *mlxsw_core) mlxsw_core_temp_warn_enabled() argument 578 mlxsw_emad_transmit(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans) mlxsw_emad_transmit() argument 604 struct mlxsw_core *mlxsw_core = trans->core; mlxsw_emad_trans_finish() local 614 mlxsw_emad_transmit_retry(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans) mlxsw_emad_transmit_retry() argument 645 mlxsw_emad_process_response(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans, struct sk_buff *skb) mlxsw_emad_process_response() argument 676 struct mlxsw_core *mlxsw_core = priv; mlxsw_emad_rx_listener_func() local 702 mlxsw_emad_init(struct mlxsw_core *mlxsw_core) mlxsw_emad_init() argument 747 mlxsw_emad_fini(struct mlxsw_core *mlxsw_core) mlxsw_emad_fini() argument 759 mlxsw_emad_alloc(const struct mlxsw_core *mlxsw_core, u16 reg_len, bool enable_string_tlv) mlxsw_emad_alloc() argument 782 mlxsw_emad_reg_access(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type, struct mlxsw_reg_trans *trans, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv, u64 tid) mlxsw_emad_reg_access() argument 886 struct mlxsw_core *mlxsw_core; global() member 895 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_component_query() local 914 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_lock() local 937 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_component_update() local 950 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_block_download() local 962 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_component_verify() local 974 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_activate() local 987 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_query_state() local 1008 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_cancel() local 1019 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_release() local 1038 mlxsw_core_fw_flash(struct mlxsw_core *mlxsw_core, const struct firmware *firmware, struct netlink_ext_ack *extack) mlxsw_core_fw_flash() argument 1059 mlxsw_core_fw_rev_validate(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, const struct mlxsw_fw_rev *req_rev, const char *filename) mlxsw_core_fw_rev_validate() argument 1116 mlxsw_core_fw_flash_update(struct mlxsw_core *mlxsw_core, struct devlink_flash_update_params *params, struct netlink_ext_ack *extack) mlxsw_core_fw_flash_update() argument 1150 mlxsw_core_fw_params_register(struct mlxsw_core *mlxsw_core) mlxsw_core_fw_params_register() argument 1166 mlxsw_core_fw_params_unregister(struct mlxsw_core *mlxsw_core) mlxsw_core_fw_params_unregister() argument 1177 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_port_split() local 1193 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_port_unsplit() local 1210 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_pool_get() local 1225 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_pool_set() local 1243 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_port_type_set() local 1259 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_port_pool_get() local 1275 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_port_pool_set() local 1292 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_tc_pool_bind_get() local 1311 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_tc_pool_bind_set() local 1326 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_occ_snapshot() local 1337 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_occ_max_clear() local 1350 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_occ_port_pool_get() local 1367 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_occ_tc_port_bind_get() local 1383 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_info_get() local 1425 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_core_bus_device_reload_down() local 1439 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_core_bus_device_reload_up() local 1453 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_flash_update() local 1462 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_init() local 1474 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_fini() local 1487 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_action_set() local 1499 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_group_init() local 1513 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_group_set() local 1525 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_init() local 1537 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_fini() local 1551 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_set() local 1565 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_counter_get() local 1605 mlxsw_core_params_register(struct mlxsw_core *mlxsw_core) mlxsw_core_params_register() argument 1625 mlxsw_core_params_unregister(struct mlxsw_core *mlxsw_core) mlxsw_core_params_unregister() argument 1633 struct mlxsw_core *mlxsw_core; global() member 1641 struct mlxsw_core *mlxsw_core; mlxsw_core_health_event_work() local 1654 struct mlxsw_core *mlxsw_core = priv; mlxsw_core_health_listener_func() local 1783 struct mlxsw_core *mlxsw_core = devlink_health_reporter_priv(reporter); mlxsw_core_health_fw_fatal_test() local 1802 mlxsw_core_health_fw_fatal_config(struct mlxsw_core *mlxsw_core, bool enable) mlxsw_core_health_fw_fatal_config() argument 1816 mlxsw_core_health_init(struct mlxsw_core *mlxsw_core) mlxsw_core_health_init() argument 1850 mlxsw_core_health_fini(struct mlxsw_core *mlxsw_core) mlxsw_core_health_fini() argument 1870 struct mlxsw_core *mlxsw_core; __mlxsw_core_bus_device_register() local 2036 mlxsw_core_bus_device_unregister(struct mlxsw_core *mlxsw_core, bool reload) mlxsw_core_bus_device_unregister() argument 2084 mlxsw_core_skb_transmit_busy(struct mlxsw_core *mlxsw_core, const struct mlxsw_tx_info *tx_info) mlxsw_core_skb_transmit_busy() argument 2092 mlxsw_core_skb_transmit(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, const struct mlxsw_tx_info *tx_info) mlxsw_core_skb_transmit() argument 2100 mlxsw_core_ptp_transmitted(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, u8 local_port) mlxsw_core_ptp_transmitted() argument 2119 __find_rx_listener_item(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl) __find_rx_listener_item() argument 2131 mlxsw_core_rx_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl, void *priv, bool enabled) mlxsw_core_rx_listener_register() argument 2152 mlxsw_core_rx_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl) mlxsw_core_rx_listener_unregister() argument 2167 mlxsw_core_rx_listener_state_set(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl, bool enabled) mlxsw_core_rx_listener_state_set() argument 2207 __find_event_listener_item(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el) __find_event_listener_item() argument 2219 mlxsw_core_event_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el, void *priv) mlxsw_core_event_listener_register() argument 2257 mlxsw_core_event_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el) mlxsw_core_event_listener_unregister() argument 2276 mlxsw_core_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv, bool enabled) mlxsw_core_listener_register() argument 2292 mlxsw_core_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_listener_unregister() argument 2304 mlxsw_core_trap_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_trap_register() argument 2335 mlxsw_core_trap_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_trap_unregister() argument 2352 mlxsw_core_trap_state_set(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, bool enabled) mlxsw_core_trap_state_set() argument 2380 mlxsw_core_tid_get(struct mlxsw_core *mlxsw_core) mlxsw_core_tid_get() argument 2385 mlxsw_core_reg_access_emad(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_core_reg_access_emad() argument 2410 mlxsw_reg_trans_query(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_reg_trans_query() argument 2421 mlxsw_reg_trans_write(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_reg_trans_write() argument 2437 struct mlxsw_core *mlxsw_core = trans->core; mlxsw_reg_trans_wait() local 2488 mlxsw_core_reg_access_cmd(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type) mlxsw_core_reg_access_cmd() argument 2551 mlxsw_core_reg_access_cb(struct mlxsw_core *mlxsw_core, char *payload, size_t payload_len, unsigned long cb_priv) mlxsw_core_reg_access_cb() argument 2560 mlxsw_core_reg_access(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type) mlxsw_core_reg_access() argument 2585 mlxsw_reg_query(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload) mlxsw_reg_query() argument 2593 mlxsw_reg_write(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload) mlxsw_reg_write() argument 2601 mlxsw_core_skb_receive(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, struct mlxsw_rx_info *rx_info) mlxsw_core_skb_receive() argument 2656 mlxsw_core_lag_mapping_index(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index) mlxsw_core_lag_mapping_index() argument 2663 mlxsw_core_lag_mapping_set(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index, u8 local_port) mlxsw_core_lag_mapping_set() argument 2673 mlxsw_core_lag_mapping_get(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index) mlxsw_core_lag_mapping_get() argument 2683 mlxsw_core_lag_mapping_clear(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 local_port) mlxsw_core_lag_mapping_clear() argument 2698 mlxsw_core_res_valid(struct mlxsw_core *mlxsw_core, enum mlxsw_res_id res_id) mlxsw_core_res_valid() argument 2705 mlxsw_core_res_get(struct mlxsw_core *mlxsw_core, enum mlxsw_res_id res_id) mlxsw_core_res_get() argument 2712 __mlxsw_core_port_init(struct mlxsw_core *mlxsw_core, u8 local_port, enum devlink_port_flavour flavour, u32 port_number, bool split, u32 split_port_subnumber, bool splittable, u32 lanes, const unsigned char *switch_id, unsigned char switch_id_len) __mlxsw_core_port_init() argument 2743 __mlxsw_core_port_fini(struct mlxsw_core *mlxsw_core, u8 local_port) __mlxsw_core_port_fini() argument 2753 mlxsw_core_port_init(struct mlxsw_core *mlxsw_core, u8 local_port, u32 port_number, bool split, u32 split_port_subnumber, bool splittable, u32 lanes, const unsigned char *switch_id, unsigned char switch_id_len) mlxsw_core_port_init() argument 2768 mlxsw_core_port_fini(struct mlxsw_core *mlxsw_core, u8 local_port) mlxsw_core_port_fini() argument 2774 mlxsw_core_cpu_port_init(struct mlxsw_core *mlxsw_core, void *port_driver_priv, const unsigned char *switch_id, unsigned char switch_id_len) mlxsw_core_cpu_port_init() argument 2795 mlxsw_core_cpu_port_fini(struct mlxsw_core *mlxsw_core) mlxsw_core_cpu_port_fini() argument 2801 mlxsw_core_port_eth_set(struct mlxsw_core *mlxsw_core, u8 local_port, void *port_driver_priv, struct net_device *dev) mlxsw_core_port_eth_set() argument 2813 mlxsw_core_port_ib_set(struct mlxsw_core *mlxsw_core, u8 local_port, void *port_driver_priv) mlxsw_core_port_ib_set() argument 2825 mlxsw_core_port_clear(struct mlxsw_core *mlxsw_core, u8 local_port, void *port_driver_priv) mlxsw_core_port_clear() argument 2837 mlxsw_core_port_type_get(struct mlxsw_core *mlxsw_core, u8 local_port) mlxsw_core_port_type_get() argument 2850 mlxsw_core_port_devlink_port_get(struct mlxsw_core *mlxsw_core, u8 local_port) mlxsw_core_port_devlink_port_get() argument 2861 mlxsw_core_env(const struct mlxsw_core *mlxsw_core) mlxsw_core_env() argument 2866 mlxsw_core_is_initialized(const struct mlxsw_core *mlxsw_core) mlxsw_core_is_initialized() argument 2871 mlxsw_core_module_max_width(struct mlxsw_core *mlxsw_core, u8 module) mlxsw_core_module_max_width() argument 2909 mlxsw_core_buf_dump_dbg(struct mlxsw_core *mlxsw_core, const char *buf, size_t size) mlxsw_core_buf_dump_dbg() argument 2927 mlxsw_cmd_exec(struct mlxsw_core *mlxsw_core, u16 opcode, u8 opcode_mod, u32 in_mod, bool out_mbox_direct, bool reset_ok, char *in_mbox, size_t in_mbox_size, char *out_mbox, size_t out_mbox_size) mlxsw_cmd_exec() argument 2991 mlxsw_core_kvd_sizes_get(struct mlxsw_core *mlxsw_core, const struct mlxsw_config_profile *profile, u64 *p_single_size, u64 *p_double_size, u64 *p_linear_size) mlxsw_core_kvd_sizes_get() argument 3007 mlxsw_core_resources_query(struct mlxsw_core *mlxsw_core, char *mbox, struct mlxsw_res *res) mlxsw_core_resources_query() argument 3044 mlxsw_core_read_frc_h(struct mlxsw_core *mlxsw_core) mlxsw_core_read_frc_h() argument 3050 mlxsw_core_read_frc_l(struct mlxsw_core *mlxsw_core) mlxsw_core_read_frc_l() argument 3056 mlxsw_core_emad_string_tlv_enable(struct mlxsw_core *mlxsw_core) mlxsw_core_emad_string_tlv_enable() argument [all...] |
H A D | cmd.h | 26 struct mlxsw_core; 28 int mlxsw_cmd_exec(struct mlxsw_core *mlxsw_core, u16 opcode, u8 opcode_mod, 33 static inline int mlxsw_cmd_exec_in(struct mlxsw_core *mlxsw_core, u16 opcode, in mlxsw_cmd_exec_in() argument 37 return mlxsw_cmd_exec(mlxsw_core, opcode, opcode_mod, in_mod, false, in mlxsw_cmd_exec_in() 41 static inline int mlxsw_cmd_exec_out(struct mlxsw_core *mlxsw_core, u16 opcode, in mlxsw_cmd_exec_out() argument 46 return mlxsw_cmd_exec(mlxsw_core, opcode, opcode_mod, in_mod, in mlxsw_cmd_exec_out() 51 static inline int mlxsw_cmd_exec_none(struct mlxsw_core *mlxsw_cor argument 199 mlxsw_cmd_query_fw(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_query_fw() argument 339 mlxsw_cmd_boardinfo(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_boardinfo() argument 383 mlxsw_cmd_query_aq_cap(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_query_aq_cap() argument 461 mlxsw_cmd_map_fa(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 vpm_entries_count) mlxsw_cmd_map_fa() argument 490 mlxsw_cmd_unmap_fa(struct mlxsw_core *mlxsw_core) mlxsw_cmd_unmap_fa() argument 510 mlxsw_cmd_query_resources(struct mlxsw_core *mlxsw_core, char *out_mbox, int index) mlxsw_cmd_query_resources() argument 544 mlxsw_cmd_config_profile_set(struct mlxsw_core *mlxsw_core, char *in_mbox) mlxsw_cmd_config_profile_set() argument 855 mlxsw_cmd_access_reg(struct mlxsw_core *mlxsw_core, bool reset_ok, char *in_mbox, char *out_mbox) mlxsw_cmd_access_reg() argument 875 __mlxsw_cmd_sw2hw_dq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_sw2hw_dq() argument 889 mlxsw_cmd_sw2hw_sdq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number) mlxsw_cmd_sw2hw_sdq() argument 896 mlxsw_cmd_sw2hw_rdq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number) mlxsw_cmd_sw2hw_rdq() argument 946 __mlxsw_cmd_hw2sw_dq(struct mlxsw_core *mlxsw_core, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_hw2sw_dq() argument 953 mlxsw_cmd_hw2sw_sdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_hw2sw_sdq() argument 960 mlxsw_cmd_hw2sw_rdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_hw2sw_rdq() argument 981 __mlxsw_cmd_2err_dq(struct mlxsw_core *mlxsw_core, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_2err_dq() argument 988 mlxsw_cmd_2err_sdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_2err_sdq() argument 995 mlxsw_cmd_2err_rdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_2err_rdq() argument 1012 __mlxsw_cmd_query_dq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_query_dq() argument 1021 mlxsw_cmd_query_sdq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number) mlxsw_cmd_query_sdq() argument 1028 mlxsw_cmd_query_rdq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number) mlxsw_cmd_query_rdq() argument 1045 mlxsw_cmd_sw2hw_cq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 cq_number) mlxsw_cmd_sw2hw_cq() argument 1099 mlxsw_cmd_hw2sw_cq(struct mlxsw_core *mlxsw_core, u32 cq_number) mlxsw_cmd_hw2sw_cq() argument 1118 mlxsw_cmd_query_cq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 cq_number) mlxsw_cmd_query_cq() argument 1136 mlxsw_cmd_sw2hw_eq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 eq_number) mlxsw_cmd_sw2hw_eq() argument 1181 mlxsw_cmd_hw2sw_eq(struct mlxsw_core *mlxsw_core, u32 eq_number) mlxsw_cmd_hw2sw_eq() argument 1196 mlxsw_cmd_query_eq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 eq_number) mlxsw_cmd_query_eq() argument [all...] |
H A D | core_env.c | 19 struct mlxsw_core *core; 25 static int mlxsw_env_validate_cable_ident(struct mlxsw_core *core, int id, in mlxsw_env_validate_cable_ident() 62 mlxsw_env_query_module_eeprom(struct mlxsw_core *mlxsw_core, int module, in mlxsw_env_query_module_eeprom() argument 110 err = mlxsw_reg_query(mlxsw_core, MLXSW_REG(mcia), mcia_pl); in mlxsw_env_query_module_eeprom() 125 int mlxsw_env_module_temp_thresholds_get(struct mlxsw_core *core, int module, in mlxsw_env_module_temp_thresholds_get() 195 int mlxsw_env_get_module_info(struct mlxsw_core *mlxsw_core, int module, in mlxsw_env_get_module_info() argument 204 err = mlxsw_env_query_module_eeprom(mlxsw_core, module, 0, offset, in mlxsw_env_get_module_info() 234 err = mlxsw_env_query_module_eeprom(mlxsw_core, modul in mlxsw_env_get_module_info() 273 mlxsw_env_get_module_eeprom(struct net_device *netdev, struct mlxsw_core *mlxsw_core, int module, struct ethtool_eeprom *ee, u8 *data) mlxsw_env_get_module_eeprom() argument 309 mlxsw_env_module_has_temp_sensor(struct mlxsw_core *mlxsw_core, u8 module, bool *p_has_temp_sensor) mlxsw_env_module_has_temp_sensor() argument 338 mlxsw_env_temp_event_set(struct mlxsw_core *mlxsw_core, u16 sensor_index, bool enable) mlxsw_env_temp_event_set() argument 378 mlxsw_env_module_temp_event_enable(struct mlxsw_core *mlxsw_core, u8 module_count) mlxsw_env_module_temp_event_enable() argument 449 mlxsw_env_temp_warn_event_register(struct mlxsw_core *mlxsw_core) mlxsw_env_temp_warn_event_register() argument 540 mlxsw_env_module_plug_event_register(struct mlxsw_core *mlxsw_core) mlxsw_env_module_plug_event_register() argument 564 mlxsw_env_module_oper_state_event_enable(struct mlxsw_core *mlxsw_core, u8 module_count) mlxsw_env_module_oper_state_event_enable() argument 582 mlxsw_env_module_overheat_counter_get(struct mlxsw_core *mlxsw_core, u8 module, u64 *p_counter) mlxsw_env_module_overheat_counter_get() argument 604 mlxsw_env_init(struct mlxsw_core *mlxsw_core, struct mlxsw_env **p_env) mlxsw_env_init() argument [all...] |
H A D | core_env.h | 7 int mlxsw_env_module_temp_thresholds_get(struct mlxsw_core *core, int module, 10 int mlxsw_env_get_module_info(struct mlxsw_core *mlxsw_core, int module, 14 struct mlxsw_core *mlxsw_core, int module, 18 mlxsw_env_module_overheat_counter_get(struct mlxsw_core *mlxsw_core, u8 module, 20 int mlxsw_env_init(struct mlxsw_core *core, struct mlxsw_env **p_env);
|
H A D | spectrum.c | 1874 static int mlxsw_sp_local_ports_offset(struct mlxsw_core *mlxsw_core, in mlxsw_sp_local_ports_offset() argument 1890 if (!mlxsw_core_res_valid(mlxsw_core, local_ports_in_x_res_id)) in mlxsw_sp_local_ports_offset() 1892 return mlxsw_core_res_get(mlxsw_core, local_ports_in_x_res_id); in mlxsw_sp_local_ports_offset() 1903 static int mlxsw_sp_port_split(struct mlxsw_core *mlxsw_core, u8 local_port, in mlxsw_sp_port_split() argument 1907 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_port_split() 1924 max_width = mlxsw_core_module_max_width(mlxsw_core, in mlxsw_sp_port_split() 1939 offset = mlxsw_sp_local_ports_offset(mlxsw_core, count, max_width); in mlxsw_sp_port_split() 1987 static int mlxsw_sp_port_unsplit(struct mlxsw_core *mlxsw_cor argument 2238 mlxsw_sp_cpu_policers_set(struct mlxsw_core *mlxsw_core) mlxsw_sp_cpu_policers_set() argument 2279 mlxsw_sp_trap_groups_set(struct mlxsw_core *mlxsw_core) mlxsw_sp_trap_groups_set() argument 2461 mlxsw_sp_basic_trap_groups_set(struct mlxsw_core *mlxsw_core) mlxsw_sp_basic_trap_groups_set() argument 2532 mlxsw_sp_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp_init() argument 2735 mlxsw_sp1_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp1_init() argument 2764 mlxsw_sp2_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp2_init() argument 2791 mlxsw_sp3_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp3_init() argument 2818 mlxsw_sp_fini(struct mlxsw_core *mlxsw_core) mlxsw_sp_fini() argument 2898 mlxsw_sp_resource_size_params_prepare(struct mlxsw_core *mlxsw_core, struct devlink_resource_size_params *kvd_size_params, struct devlink_resource_size_params *linear_size_params, struct devlink_resource_size_params *hash_double_size_params, struct devlink_resource_size_params *hash_single_size_params) mlxsw_sp_resource_size_params_prepare() argument 2933 mlxsw_sp1_resources_kvd_register(struct mlxsw_core *mlxsw_core) mlxsw_sp1_resources_kvd_register() argument 2999 mlxsw_sp2_resources_kvd_register(struct mlxsw_core *mlxsw_core) mlxsw_sp2_resources_kvd_register() argument 3019 mlxsw_sp_resources_span_register(struct mlxsw_core *mlxsw_core) mlxsw_sp_resources_span_register() argument 3038 mlxsw_sp1_resources_register(struct mlxsw_core *mlxsw_core) mlxsw_sp1_resources_register() argument 3066 mlxsw_sp2_resources_register(struct mlxsw_core *mlxsw_core) mlxsw_sp2_resources_register() argument 3094 mlxsw_sp_kvd_sizes_get(struct mlxsw_core *mlxsw_core, const struct mlxsw_config_profile *profile, u64 *p_single_size, u64 *p_double_size, u64 *p_linear_size) mlxsw_sp_kvd_sizes_get() argument 3153 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_sp_params_acl_region_rehash_intrvl_get() local 3164 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_sp_params_acl_region_rehash_intrvl_set() local 3180 mlxsw_sp2_params_register(struct mlxsw_core *mlxsw_core) mlxsw_sp2_params_register() argument 3198 mlxsw_sp2_params_unregister(struct mlxsw_core *mlxsw_core) mlxsw_sp2_params_unregister() argument 3205 mlxsw_sp_ptp_transmitted(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, u8 local_port) mlxsw_sp_ptp_transmitted() argument [all...] |
H A D | spectrum.h | 145 struct mlxsw_core *core; 502 int mlxsw_sp_sb_pool_get(struct mlxsw_core *mlxsw_core, 505 int mlxsw_sp_sb_pool_set(struct mlxsw_core *mlxsw_core, 524 int mlxsw_sp_sb_occ_snapshot(struct mlxsw_core *mlxsw_core, 526 int mlxsw_sp_sb_occ_max_clear(struct mlxsw_core *mlxsw_core, 744 int mlxsw_sp1_kvdl_resources_register(struct mlxsw_core *mlxsw_cor [all...] |
H A D | Makefile | 2 obj-$(CONFIG_MLXSW_CORE) += mlxsw_core.o 3 mlxsw_core-objs := core.o core_acl_flex_keys.o \ 5 mlxsw_core-$(CONFIG_MLXSW_CORE_HWMON) += core_hwmon.o 6 mlxsw_core-$(CONFIG_MLXSW_CORE_THERMAL) += core_thermal.o
|
H A D | switchib.c | 31 struct mlxsw_core *core; 434 static int mlxsw_sib_basic_trap_groups_set(struct mlxsw_core *mlxsw_core) in mlxsw_sib_basic_trap_groups_set() argument 445 return mlxsw_reg_write(mlxsw_core, MLXSW_REG(htgt), htgt_pl); in mlxsw_sib_basic_trap_groups_set() 448 static int mlxsw_sib_init(struct mlxsw_core *mlxsw_core, in mlxsw_sib_init() argument 452 struct mlxsw_sib *mlxsw_sib = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sib_init() 455 mlxsw_sib->core = mlxsw_core; in mlxsw_sib_init() 483 static void mlxsw_sib_fini(struct mlxsw_core *mlxsw_core) in mlxsw_sib_fini() argument [all...] |
H A D | spectrum_trap.c | 1391 int mlxsw_sp_trap_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_init() argument 1394 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_trap_init() 1409 err = mlxsw_core_trap_register(mlxsw_core, listener, trap_ctx); in mlxsw_sp_trap_init() 1417 void mlxsw_sp_trap_fini(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_fini() argument 1420 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_trap_fini() 1434 mlxsw_core_trap_unregister(mlxsw_core, listener, trap_ctx); in mlxsw_sp_trap_fini() 1438 int mlxsw_sp_trap_action_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_action_set() argument 1484 __mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group, u32 policer_id, struct netlink_ext_ack *extack) __mlxsw_sp_trap_group_init() argument 1517 mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group) mlxsw_sp_trap_group_init() argument 1524 mlxsw_sp_trap_group_set(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group, const struct devlink_trap_policer *policer, struct netlink_ext_ack *extack) mlxsw_sp_trap_group_set() argument 1596 mlxsw_sp_trap_policer_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer) mlxsw_sp_trap_policer_init() argument 1624 mlxsw_sp_trap_policer_fini(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer) mlxsw_sp_trap_policer_fini() argument 1637 mlxsw_sp_trap_policer_set(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer, u64 rate, u64 burst, struct netlink_ext_ack *extack) mlxsw_sp_trap_policer_set() argument 1654 mlxsw_sp_trap_policer_counter_get(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer, u64 *p_drops) mlxsw_sp_trap_policer_counter_get() argument [all...] |
H A D | minimal.c | 32 struct mlxsw_core *core; 99 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_info() 109 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_eeprom() 359 static int mlxsw_m_init(struct mlxsw_core *mlxsw_core, in mlxsw_m_init() argument 363 struct mlxsw_m *mlxsw_m = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_m_init() 366 mlxsw_m->core = mlxsw_core; in mlxsw_m_init() 388 static void mlxsw_m_fini(struct mlxsw_core *mlxsw_core) in mlxsw_m_fini() argument 390 struct mlxsw_m *mlxsw_m = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_m_fini() [all...] |
H A D | spectrum_cnt.c | 242 int mlxsw_sp_counter_resources_register(struct mlxsw_core *mlxsw_core) in mlxsw_sp_counter_resources_register() argument 245 struct devlink *devlink = priv_to_devlink(mlxsw_core); in mlxsw_sp_counter_resources_register() 255 if (!MLXSW_CORE_RES_VALID(mlxsw_core, COUNTER_POOL_SIZE) || in mlxsw_sp_counter_resources_register() 256 !MLXSW_CORE_RES_VALID(mlxsw_core, COUNTER_BANK_SIZE)) in mlxsw_sp_counter_resources_register() 259 pool_size = MLXSW_CORE_RES_GET(mlxsw_core, COUNTER_POOL_SIZE); in mlxsw_sp_counter_resources_register() 260 bank_size = MLXSW_CORE_RES_GET(mlxsw_core, COUNTER_BANK_SIZE); in mlxsw_sp_counter_resources_register()
|
/kernel/linux/linux-6.6/drivers/net/ethernet/mellanox/mlxsw/ |
H A D | core.h | 29 struct mlxsw_core; 36 unsigned int mlxsw_core_max_ports(const struct mlxsw_core *mlxsw_core); 38 int mlxsw_core_max_lag(struct mlxsw_core *mlxsw_core, u16 *p_max_lag); 40 void *mlxsw_core_driver_priv(struct mlxsw_core *mlxsw_core); 42 struct mlxsw_linecards *mlxsw_core_linecards(struct mlxsw_core *mlxsw_core); 44 void mlxsw_core_linecards_set(struct mlxsw_core *mlxsw_cor 461 mlxsw_core_net(struct mlxsw_core *mlxsw_core) mlxsw_core_net() argument 520 mlxsw_hwmon_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct mlxsw_hwmon **p_hwmon) mlxsw_hwmon_init() argument 544 mlxsw_thermal_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct mlxsw_thermal **p_thermal) mlxsw_thermal_init() argument 621 struct mlxsw_core *mlxsw_core; global() member [all...] |
H A D | core.c | 42 static const char mlxsw_core_driver_name[] = "mlxsw_core"; 65 struct mlxsw_core { struct 102 struct mlxsw_linecards *mlxsw_core_linecards(struct mlxsw_core *mlxsw_core) in mlxsw_core_linecards() argument 104 return mlxsw_core->linecards; in mlxsw_core_linecards() 107 void mlxsw_core_linecards_set(struct mlxsw_core *mlxsw_core, in mlxsw_core_linecards_set() argument 110 mlxsw_core->linecards = linecards; in mlxsw_core_linecards_set() 117 struct mlxsw_core *mlxsw_core in mlxsw_ports_occ_get() local 122 mlxsw_core_resources_ports_register(struct mlxsw_core *mlxsw_core) mlxsw_core_resources_ports_register() argument 140 mlxsw_ports_init(struct mlxsw_core *mlxsw_core, bool reload) mlxsw_ports_init() argument 173 mlxsw_ports_fini(struct mlxsw_core *mlxsw_core, bool reload) mlxsw_ports_fini() argument 184 mlxsw_core_max_ports(const struct mlxsw_core *mlxsw_core) mlxsw_core_max_ports() argument 190 mlxsw_core_max_lag(struct mlxsw_core *mlxsw_core, u16 *p_max_lag) mlxsw_core_max_lag() argument 207 mlxsw_core_driver_priv(struct mlxsw_core *mlxsw_core) mlxsw_core_driver_priv() argument 232 struct mlxsw_core *mlxsw_core; global() member 242 mlxsw_core_trap_groups_set(struct mlxsw_core *mlxsw_core) mlxsw_core_trap_groups_set() argument 502 mlxsw_emad_construct(const struct mlxsw_core *mlxsw_core, struct sk_buff *skb, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type, u64 tid) mlxsw_emad_construct() argument 716 mlxsw_emad_transmit(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans) mlxsw_emad_transmit() argument 742 struct mlxsw_core *mlxsw_core = trans->core; mlxsw_emad_trans_finish() local 752 mlxsw_emad_transmit_retry(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans) mlxsw_emad_transmit_retry() argument 783 mlxsw_emad_process_response(struct mlxsw_core *mlxsw_core, struct mlxsw_reg_trans *trans, struct sk_buff *skb) mlxsw_emad_process_response() argument 814 struct mlxsw_core *mlxsw_core = priv; mlxsw_emad_rx_listener_func() local 840 mlxsw_emad_tlv_enable(struct mlxsw_core *mlxsw_core) mlxsw_emad_tlv_enable() argument 860 mlxsw_emad_tlv_disable(struct mlxsw_core *mlxsw_core) mlxsw_emad_tlv_disable() argument 866 mlxsw_emad_init(struct mlxsw_core *mlxsw_core) mlxsw_emad_init() argument 912 mlxsw_emad_fini(struct mlxsw_core *mlxsw_core) mlxsw_emad_fini() argument 925 mlxsw_emad_alloc(const struct mlxsw_core *mlxsw_core, u16 reg_len) mlxsw_emad_alloc() argument 950 mlxsw_emad_reg_access(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type, struct mlxsw_reg_trans *trans, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv, u64 tid) mlxsw_emad_reg_access() argument 1045 mlxsw_core_fw_flash(struct mlxsw_core *mlxsw_core, struct mlxfw_dev *mlxfw_dev, const struct firmware *firmware, struct netlink_ext_ack *extack) mlxsw_core_fw_flash() argument 1061 struct mlxsw_core *mlxsw_core; global() member 1070 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_component_query() local 1089 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_lock() local 1112 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_component_update() local 1125 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_block_download() local 1137 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_component_verify() local 1149 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_activate() local 1162 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_query_state() local 1183 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_cancel() local 1194 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; mlxsw_core_fw_fsm_release() local 1213 mlxsw_core_dev_fw_flash(struct mlxsw_core *mlxsw_core, const struct firmware *firmware, struct netlink_ext_ack *extack) mlxsw_core_dev_fw_flash() argument 1231 mlxsw_core_fw_rev_validate(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, const struct mlxsw_fw_rev *req_rev, const char *filename) mlxsw_core_fw_rev_validate() argument 1288 mlxsw_core_fw_flash_update(struct mlxsw_core *mlxsw_core, struct devlink_flash_update_params *params, struct netlink_ext_ack *extack) mlxsw_core_fw_flash_update() argument 1313 mlxsw_core_fw_params_register(struct mlxsw_core *mlxsw_core) mlxsw_core_fw_params_register() argument 1331 mlxsw_core_fw_params_unregister(struct mlxsw_core *mlxsw_core) mlxsw_core_fw_params_unregister() argument 1348 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_port_split() local 1362 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_port_unsplit() local 1376 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_pool_get() local 1391 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_pool_set() local 1405 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_port_pool_get() local 1421 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_port_pool_set() local 1438 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_tc_pool_bind_get() local 1457 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_tc_pool_bind_set() local 1472 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_occ_snapshot() local 1483 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_sb_occ_max_clear() local 1496 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_occ_port_pool_get() local 1513 struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); mlxsw_devlink_sb_occ_tc_port_bind_get() local 1529 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_info_get() local 1570 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_core_bus_device_reload_down() local 1584 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_core_bus_device_reload_up() local 1600 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_flash_update() local 1609 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_init() local 1621 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_fini() local 1634 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_action_set() local 1646 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_group_init() local 1660 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_group_set() local 1672 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_init() local 1684 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_fini() local 1698 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_set() local 1712 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); mlxsw_devlink_trap_policer_counter_get() local 1749 mlxsw_core_params_register(struct mlxsw_core *mlxsw_core) mlxsw_core_params_register() argument 1754 mlxsw_core_params_unregister(struct mlxsw_core *mlxsw_core) mlxsw_core_params_unregister() argument 1760 struct mlxsw_core *mlxsw_core; global() member 1768 struct mlxsw_core *mlxsw_core; mlxsw_core_health_event_work() local 1781 struct mlxsw_core *mlxsw_core = priv; mlxsw_core_health_listener_func() local 2067 struct mlxsw_core *mlxsw_core = devlink_health_reporter_priv(reporter); mlxsw_core_health_fw_fatal_test() local 2086 mlxsw_core_health_fw_fatal_config(struct mlxsw_core *mlxsw_core, bool enable) mlxsw_core_health_fw_fatal_config() argument 2100 mlxsw_core_health_init(struct mlxsw_core *mlxsw_core) mlxsw_core_health_init() argument 2134 mlxsw_core_health_fini(struct mlxsw_core *mlxsw_core) mlxsw_core_health_fini() argument 2146 mlxsw_core_irq_event_handler_init(struct mlxsw_core *mlxsw_core) mlxsw_core_irq_event_handler_init() argument 2152 mlxsw_core_irq_event_handler_fini(struct mlxsw_core *mlxsw_core) mlxsw_core_irq_event_handler_fini() argument 2166 struct mlxsw_core *mlxsw_core; __mlxsw_core_bus_device_register() local 2336 mlxsw_core_bus_device_unregister(struct mlxsw_core *mlxsw_core, bool reload) mlxsw_core_bus_device_unregister() argument 2387 mlxsw_core_skb_transmit_busy(struct mlxsw_core *mlxsw_core, const struct mlxsw_tx_info *tx_info) mlxsw_core_skb_transmit_busy() argument 2395 mlxsw_core_skb_transmit(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, const struct mlxsw_tx_info *tx_info) mlxsw_core_skb_transmit() argument 2403 mlxsw_core_ptp_transmitted(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, u16 local_port) mlxsw_core_ptp_transmitted() argument 2422 __find_rx_listener_item(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl) __find_rx_listener_item() argument 2434 mlxsw_core_rx_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl, void *priv, bool enabled) mlxsw_core_rx_listener_register() argument 2455 mlxsw_core_rx_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl) mlxsw_core_rx_listener_unregister() argument 2470 mlxsw_core_rx_listener_state_set(struct mlxsw_core *mlxsw_core, const struct mlxsw_rx_listener *rxl, bool enabled) mlxsw_core_rx_listener_state_set() argument 2486 struct mlxsw_core *mlxsw_core; mlxsw_core_event_listener_func() local 2515 __find_event_listener_item(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el) __find_event_listener_item() argument 2527 mlxsw_core_event_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el, void *priv) mlxsw_core_event_listener_register() argument 2566 mlxsw_core_event_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_event_listener *el) mlxsw_core_event_listener_unregister() argument 2585 mlxsw_core_listener_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv, bool enabled) mlxsw_core_listener_register() argument 2601 mlxsw_core_listener_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_listener_unregister() argument 2613 mlxsw_core_trap_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_trap_register() argument 2647 mlxsw_core_trap_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, void *priv) mlxsw_core_trap_unregister() argument 2667 mlxsw_core_traps_register(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listeners, size_t listeners_count, void *priv) mlxsw_core_traps_register() argument 2692 mlxsw_core_traps_unregister(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listeners, size_t listeners_count, void *priv) mlxsw_core_traps_unregister() argument 2706 mlxsw_core_trap_state_set(struct mlxsw_core *mlxsw_core, const struct mlxsw_listener *listener, bool enabled) mlxsw_core_trap_state_set() argument 2734 mlxsw_core_tid_get(struct mlxsw_core *mlxsw_core) mlxsw_core_tid_get() argument 2739 mlxsw_core_reg_access_emad(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_core_reg_access_emad() argument 2764 mlxsw_reg_trans_query(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_reg_trans_query() argument 2775 mlxsw_reg_trans_write(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, struct list_head *bulk_list, mlxsw_reg_trans_cb_t *cb, unsigned long cb_priv) mlxsw_reg_trans_write() argument 2791 struct mlxsw_core *mlxsw_core = trans->core; mlxsw_reg_trans_wait() local 2847 mlxsw_core_irq_event_handler_register(struct mlxsw_core *mlxsw_core, mlxsw_irq_event_cb_t cb) mlxsw_core_irq_event_handler_register() argument 2863 mlxsw_core_irq_event_handler_unregister(struct mlxsw_core *mlxsw_core, mlxsw_irq_event_cb_t cb) mlxsw_core_irq_event_handler_unregister() argument 2880 mlxsw_core_irq_event_handlers_call(struct mlxsw_core *mlxsw_core) mlxsw_core_irq_event_handlers_call() argument 2893 mlxsw_core_reg_access_cmd(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type) mlxsw_core_reg_access_cmd() argument 2956 mlxsw_core_reg_access_cb(struct mlxsw_core *mlxsw_core, char *payload, size_t payload_len, unsigned long cb_priv) mlxsw_core_reg_access_cb() argument 2965 mlxsw_core_reg_access(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload, enum mlxsw_core_reg_access_type type) mlxsw_core_reg_access() argument 2990 mlxsw_reg_query(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload) mlxsw_reg_query() argument 2998 mlxsw_reg_write(struct mlxsw_core *mlxsw_core, const struct mlxsw_reg_info *reg, char *payload) mlxsw_reg_write() argument 3006 mlxsw_core_skb_receive(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, struct mlxsw_rx_info *rx_info) mlxsw_core_skb_receive() argument 3061 mlxsw_core_lag_mapping_index(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index) mlxsw_core_lag_mapping_index() argument 3068 mlxsw_core_lag_mapping_set(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index, u16 local_port) mlxsw_core_lag_mapping_set() argument 3078 mlxsw_core_lag_mapping_get(struct mlxsw_core *mlxsw_core, u16 lag_id, u8 port_index) mlxsw_core_lag_mapping_get() argument 3088 mlxsw_core_lag_mapping_clear(struct mlxsw_core *mlxsw_core, u16 lag_id, u16 local_port) mlxsw_core_lag_mapping_clear() argument 3103 mlxsw_core_res_valid(struct mlxsw_core *mlxsw_core, enum mlxsw_res_id res_id) mlxsw_core_res_valid() argument 3110 mlxsw_core_res_get(struct mlxsw_core *mlxsw_core, enum mlxsw_res_id res_id) mlxsw_core_res_get() argument 3122 __mlxsw_core_port_init(struct mlxsw_core *mlxsw_core, u16 local_port, enum devlink_port_flavour flavour, u8 slot_index, u32 port_number, bool split, u32 split_port_subnumber, bool splittable, u32 lanes, const unsigned char *switch_id, unsigned char switch_id_len) __mlxsw_core_port_init() argument 3163 __mlxsw_core_port_fini(struct mlxsw_core *mlxsw_core, u16 local_port) __mlxsw_core_port_fini() argument 3173 mlxsw_core_port_init(struct mlxsw_core *mlxsw_core, u16 local_port, u8 slot_index, u32 port_number, bool split, u32 split_port_subnumber, bool splittable, u32 lanes, const unsigned char *switch_id, unsigned char switch_id_len) mlxsw_core_port_init() argument 3195 mlxsw_core_port_fini(struct mlxsw_core *mlxsw_core, u16 local_port) mlxsw_core_port_fini() argument 3203 mlxsw_core_cpu_port_init(struct mlxsw_core *mlxsw_core, void *port_driver_priv, const unsigned char *switch_id, unsigned char switch_id_len) mlxsw_core_cpu_port_init() argument 3224 mlxsw_core_cpu_port_fini(struct mlxsw_core *mlxsw_core) mlxsw_core_cpu_port_fini() argument 3230 mlxsw_core_port_netdev_link(struct mlxsw_core *mlxsw_core, u16 local_port, void *port_driver_priv, struct net_device *dev) mlxsw_core_port_netdev_link() argument 3243 mlxsw_core_port_devlink_port_get(struct mlxsw_core *mlxsw_core, u16 local_port) mlxsw_core_port_devlink_port_get() argument 3255 mlxsw_core_port_linecard_get(struct mlxsw_core *mlxsw_core, u16 local_port) mlxsw_core_port_linecard_get() argument 3264 mlxsw_core_ports_remove_selected(struct mlxsw_core *mlxsw_core, bool (*selector)(void *priv, u16 local_port), void *priv) mlxsw_core_ports_remove_selected() argument 3273 mlxsw_core_env(const struct mlxsw_core *mlxsw_core) mlxsw_core_env() argument 3278 mlxsw_core_buf_dump_dbg(struct mlxsw_core *mlxsw_core, const char *buf, size_t size) mlxsw_core_buf_dump_dbg() argument 3296 mlxsw_cmd_exec(struct mlxsw_core *mlxsw_core, u16 opcode, u8 opcode_mod, u32 in_mod, bool out_mbox_direct, bool reset_ok, char *in_mbox, size_t in_mbox_size, char *out_mbox, size_t out_mbox_size) mlxsw_cmd_exec() argument 3360 mlxsw_core_kvd_sizes_get(struct mlxsw_core *mlxsw_core, const struct mlxsw_config_profile *profile, u64 *p_single_size, u64 *p_double_size, u64 *p_linear_size) mlxsw_core_kvd_sizes_get() argument 3376 mlxsw_core_resources_query(struct mlxsw_core *mlxsw_core, char *mbox, struct mlxsw_res *res) mlxsw_core_resources_query() argument 3410 mlxsw_core_read_frc_h(struct mlxsw_core *mlxsw_core) mlxsw_core_read_frc_h() argument 3416 mlxsw_core_read_frc_l(struct mlxsw_core *mlxsw_core) mlxsw_core_read_frc_l() argument 3422 mlxsw_core_read_utc_sec(struct mlxsw_core *mlxsw_core) mlxsw_core_read_utc_sec() argument 3428 mlxsw_core_read_utc_nsec(struct mlxsw_core *mlxsw_core) mlxsw_core_read_utc_nsec() argument 3434 mlxsw_core_sdq_supports_cqe_v2(struct mlxsw_core *mlxsw_core) mlxsw_core_sdq_supports_cqe_v2() argument [all...] |
H A D | core_env.h | 12 int mlxsw_env_module_temp_thresholds_get(struct mlxsw_core *core, 17 struct mlxsw_core *mlxsw_core, u8 slot_index, 21 struct mlxsw_core *mlxsw_core, u8 slot_index, 26 mlxsw_env_get_module_eeprom_by_page(struct mlxsw_core *mlxsw_core, 32 struct mlxsw_core *mlxsw_core, u8 slot_index, 36 mlxsw_env_get_module_power_mode(struct mlxsw_core *mlxsw_cor [all...] |
H A D | cmd.h | 26 struct mlxsw_core; 28 int mlxsw_cmd_exec(struct mlxsw_core *mlxsw_core, u16 opcode, u8 opcode_mod, 33 static inline int mlxsw_cmd_exec_in(struct mlxsw_core *mlxsw_core, u16 opcode, in mlxsw_cmd_exec_in() argument 37 return mlxsw_cmd_exec(mlxsw_core, opcode, opcode_mod, in_mod, false, in mlxsw_cmd_exec_in() 41 static inline int mlxsw_cmd_exec_out(struct mlxsw_core *mlxsw_core, u16 opcode, in mlxsw_cmd_exec_out() argument 46 return mlxsw_cmd_exec(mlxsw_core, opcode, opcode_mod, in_mod, in mlxsw_cmd_exec_out() 51 static inline int mlxsw_cmd_exec_none(struct mlxsw_core *mlxsw_cor argument 199 mlxsw_cmd_query_fw(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_query_fw() argument 365 mlxsw_cmd_boardinfo(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_boardinfo() argument 409 mlxsw_cmd_query_aq_cap(struct mlxsw_core *mlxsw_core, char *out_mbox) mlxsw_cmd_query_aq_cap() argument 487 mlxsw_cmd_map_fa(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 vpm_entries_count) mlxsw_cmd_map_fa() argument 516 mlxsw_cmd_unmap_fa(struct mlxsw_core *mlxsw_core) mlxsw_cmd_unmap_fa() argument 536 mlxsw_cmd_query_resources(struct mlxsw_core *mlxsw_core, char *out_mbox, int index) mlxsw_cmd_query_resources() argument 570 mlxsw_cmd_config_profile_set(struct mlxsw_core *mlxsw_core, char *in_mbox) mlxsw_cmd_config_profile_set() argument 932 mlxsw_cmd_access_reg(struct mlxsw_core *mlxsw_core, bool reset_ok, char *in_mbox, char *out_mbox) mlxsw_cmd_access_reg() argument 952 __mlxsw_cmd_sw2hw_dq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_sw2hw_dq() argument 966 mlxsw_cmd_sw2hw_sdq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number) mlxsw_cmd_sw2hw_sdq() argument 973 mlxsw_cmd_sw2hw_rdq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 dq_number) mlxsw_cmd_sw2hw_rdq() argument 1023 __mlxsw_cmd_hw2sw_dq(struct mlxsw_core *mlxsw_core, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_hw2sw_dq() argument 1030 mlxsw_cmd_hw2sw_sdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_hw2sw_sdq() argument 1037 mlxsw_cmd_hw2sw_rdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_hw2sw_rdq() argument 1058 __mlxsw_cmd_2err_dq(struct mlxsw_core *mlxsw_core, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_2err_dq() argument 1065 mlxsw_cmd_2err_sdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_2err_sdq() argument 1072 mlxsw_cmd_2err_rdq(struct mlxsw_core *mlxsw_core, u32 dq_number) mlxsw_cmd_2err_rdq() argument 1089 __mlxsw_cmd_query_dq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number, u8 opcode_mod) __mlxsw_cmd_query_dq() argument 1098 mlxsw_cmd_query_sdq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number) mlxsw_cmd_query_sdq() argument 1105 mlxsw_cmd_query_rdq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 dq_number) mlxsw_cmd_query_rdq() argument 1122 mlxsw_cmd_sw2hw_cq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 cq_number) mlxsw_cmd_sw2hw_cq() argument 1176 mlxsw_cmd_hw2sw_cq(struct mlxsw_core *mlxsw_core, u32 cq_number) mlxsw_cmd_hw2sw_cq() argument 1195 mlxsw_cmd_query_cq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 cq_number) mlxsw_cmd_query_cq() argument 1213 mlxsw_cmd_sw2hw_eq(struct mlxsw_core *mlxsw_core, char *in_mbox, u32 eq_number) mlxsw_cmd_sw2hw_eq() argument 1258 mlxsw_cmd_hw2sw_eq(struct mlxsw_core *mlxsw_core, u32 eq_number) mlxsw_cmd_hw2sw_eq() argument 1273 mlxsw_cmd_query_eq(struct mlxsw_core *mlxsw_core, char *out_mbox, u32 eq_number) mlxsw_cmd_query_eq() argument [all...] |
H A D | core_env.c | 31 struct mlxsw_core *core; 59 mlxsw_env_module_info *mlxsw_env_module_info_get(struct mlxsw_core *mlxsw_core, in mlxsw_env_module_info_get() argument 62 struct mlxsw_env *mlxsw_env = mlxsw_core_env(mlxsw_core); in mlxsw_env_module_info_get() 67 static int __mlxsw_env_validate_module_type(struct mlxsw_core *core, in __mlxsw_env_validate_module_type() 89 static int mlxsw_env_validate_module_type(struct mlxsw_core *core, in mlxsw_env_validate_module_type() 103 mlxsw_env_validate_cable_ident(struct mlxsw_core *core, u8 slot_index, int id, in mlxsw_env_validate_cable_ident() 146 mlxsw_env_query_module_eeprom(struct mlxsw_core *mlxsw_core, u8 slot_index, in mlxsw_env_query_module_eeprom() argument 150 struct mlxsw_env *mlxsw_env = mlxsw_core_env(mlxsw_core); in mlxsw_env_query_module_eeprom() 289 mlxsw_env_get_module_info(struct net_device *netdev, struct mlxsw_core *mlxsw_core, u8 slot_index, int module, struct ethtool_modinfo *modinfo) mlxsw_env_get_module_info() argument 384 mlxsw_env_get_module_eeprom(struct net_device *netdev, struct mlxsw_core *mlxsw_core, u8 slot_index, int module, struct ethtool_eeprom *ee, u8 *data) mlxsw_env_get_module_eeprom() argument 459 mlxsw_env_get_module_eeprom_by_page(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, const struct ethtool_module_eeprom *page, struct netlink_ext_ack *extack) mlxsw_env_get_module_eeprom_by_page() argument 516 mlxsw_env_module_reset(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module) mlxsw_env_module_reset() argument 527 mlxsw_env_reset_module(struct net_device *netdev, struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, u32 *flags) mlxsw_env_reset_module() argument 582 mlxsw_env_get_module_power_mode(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, struct ethtool_module_power_mode_params *params, struct netlink_ext_ack *extack) mlxsw_env_get_module_power_mode() argument 630 mlxsw_env_module_enable_set(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, bool enable) mlxsw_env_module_enable_set() argument 645 mlxsw_env_module_low_power_set(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, bool low_power) mlxsw_env_module_low_power_set() argument 664 __mlxsw_env_set_module_power_mode(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, bool low_power, struct netlink_ext_ack *extack) __mlxsw_env_set_module_power_mode() argument 709 mlxsw_env_set_module_power_mode_apply(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, enum ethtool_module_power_mode_policy policy, struct netlink_ext_ack *extack) mlxsw_env_set_module_power_mode_apply() argument 746 mlxsw_env_set_module_power_mode(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, enum ethtool_module_power_mode_policy policy, struct netlink_ext_ack *extack) mlxsw_env_set_module_power_mode() argument 769 mlxsw_env_module_has_temp_sensor(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, bool *p_has_temp_sensor) mlxsw_env_module_has_temp_sensor() argument 799 mlxsw_env_temp_event_set(struct mlxsw_core *mlxsw_core, u8 slot_index, u16 sensor_index, bool enable) mlxsw_env_temp_event_set() argument 841 mlxsw_env_module_temp_event_enable(struct mlxsw_core *mlxsw_core, u8 slot_index) mlxsw_env_module_temp_event_enable() argument 945 mlxsw_env_temp_warn_event_register(struct mlxsw_core *mlxsw_core) mlxsw_env_temp_warn_event_register() argument 1041 mlxsw_env_module_plug_event_register(struct mlxsw_core *mlxsw_core) mlxsw_env_module_plug_event_register() argument 1059 mlxsw_env_module_oper_state_event_enable(struct mlxsw_core *mlxsw_core, u8 slot_index) mlxsw_env_module_oper_state_event_enable() argument 1080 mlxsw_env_module_overheat_counter_get(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module, u64 *p_counter) mlxsw_env_module_overheat_counter_get() argument 1095 mlxsw_env_module_port_map(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module) mlxsw_env_module_port_map() argument 1108 mlxsw_env_module_port_unmap(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module) mlxsw_env_module_port_unmap() argument 1121 mlxsw_env_module_port_up(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module) mlxsw_env_module_port_up() argument 1154 mlxsw_env_module_port_down(struct mlxsw_core *mlxsw_core, u8 slot_index, u8 module) mlxsw_env_module_port_down() argument 1245 mlxsw_env_module_type_set(struct mlxsw_core *mlxsw_core, u8 slot_index) mlxsw_env_module_type_set() argument 1269 mlxsw_env_linecard_modules_power_mode_apply(struct mlxsw_core *mlxsw_core, struct mlxsw_env *env, u8 slot_index) mlxsw_env_linecard_modules_power_mode_apply() argument 1292 mlxsw_env_got_active(struct mlxsw_core *mlxsw_core, u8 slot_index, void *priv) mlxsw_env_got_active() argument 1340 mlxsw_env_got_inactive(struct mlxsw_core *mlxsw_core, u8 slot_index, void *priv) mlxsw_env_got_inactive() argument 1380 mlxsw_env_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *bus_info, struct mlxsw_env **p_env) mlxsw_env_init() argument [all...] |
H A D | core_linecards.c | 79 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; in mlxsw_linecard_type_name() local 84 err = mlxsw_reg_query(mlxsw_core, MLXSW_REG(mddq), mddq_pl); in mlxsw_linecard_type_name() 93 struct mlxsw_core *mlxsw_core; member 107 struct mlxsw_core *mlxsw_core = info->mlxsw_core; in mlxsw_linecard_device_fw_component_query() local 118 err = mlxsw_reg_query(mlxsw_core, MLXSW_RE in mlxsw_linecard_device_fw_component_query() 137 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_lock() local 175 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_component_update() local 197 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_block_download() local 217 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_component_verify() local 237 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_activate() local 260 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_query_state() local 290 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_cancel() local 310 struct mlxsw_core *mlxsw_core = info->mlxsw_core; mlxsw_linecard_device_fw_fsm_release() local 341 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_flash_update() local 370 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_device_psid_get() local 390 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_device_info_update() local 454 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_event_op_call() local 525 mlxsw_linecards_event_ops_register(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards_event_ops *ops, void *priv) mlxsw_linecards_event_ops_register() argument 548 mlxsw_linecards_event_ops_unregister(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards_event_ops *ops, void *priv) mlxsw_linecards_event_ops_unregister() argument 669 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_ready_set() local 687 struct mlxsw_core *mlxsw_core = linecard->linecards->mlxsw_core; mlxsw_linecard_ready_clear() local 773 mlxsw_linecard_status_get_and_process(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards, struct mlxsw_linecard *linecard) mlxsw_linecard_status_get_and_process() argument 788 mlxsw_linecards_irq_event_handler(struct mlxsw_core *mlxsw_core) mlxsw_linecards_irq_event_handler() argument 861 mlxsw_linecard_ini_transfer(struct mlxsw_core *mlxsw_core, struct mlxsw_linecard *linecard, const struct mlxsw_linecard_ini_file *ini_file, struct netlink_ext_ack *extack) mlxsw_linecard_ini_transfer() argument 909 mlxsw_linecard_ini_erase(struct mlxsw_core *mlxsw_core, struct mlxsw_linecard *linecard, struct netlink_ext_ack *extack) mlxsw_linecard_ini_erase() argument 946 mlxsw_linecard_bct_process(struct mlxsw_core *mlxsw_core, const char *mbct_pl) mlxsw_linecard_bct_process() argument 975 mlxsw_linecard_ini_activate(struct mlxsw_core *mlxsw_core, struct mlxsw_linecard *linecard, struct netlink_ext_ack *extack) mlxsw_linecard_ini_activate() argument 1007 mlxsw_linecard_ini_in_use_wait(struct mlxsw_core *mlxsw_core, struct mlxsw_linecard *linecard, struct netlink_ext_ack *extack) mlxsw_linecard_ini_in_use_wait() argument 1039 struct mlxsw_core *mlxsw_core; mlxsw_linecard_port_selector() local 1052 struct mlxsw_core *mlxsw_core; mlxsw_linecard_provision() local 1088 struct mlxsw_core *mlxsw_core; mlxsw_linecard_unprovision() local 1168 struct mlxsw_core *mlxsw_core; global() member 1177 struct mlxsw_core *mlxsw_core; mlxsw_linecard_status_event_work() local 1191 struct mlxsw_core *mlxsw_core = priv; mlxsw_linecard_status_listener_func() local 1203 struct mlxsw_core *mlxsw_core; global() member 1211 struct mlxsw_core *mlxsw_core; mlxsw_linecard_bct_event_work() local 1224 struct mlxsw_core *mlxsw_core = priv; mlxsw_linecard_bct_listener_func() local 1240 mlxsw_linecard_event_delivery_set(struct mlxsw_core *mlxsw_core, struct mlxsw_linecard *linecard, bool enable) mlxsw_linecard_event_delivery_set() argument 1250 mlxsw_linecard_init(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards, u8 slot_index) mlxsw_linecard_init() argument 1275 mlxsw_linecard_fini(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards, u8 slot_index) mlxsw_linecard_fini() argument 1293 mlxsw_linecard_event_delivery_init(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards, u8 slot_index) mlxsw_linecard_event_delivery_init() argument 1318 mlxsw_linecard_event_delivery_fini(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards, u8 slot_index) mlxsw_linecard_event_delivery_fini() argument 1425 mlxsw_linecard_types_init(struct mlxsw_core *mlxsw_core, struct mlxsw_linecards *linecards) mlxsw_linecard_types_init() argument 1501 mlxsw_linecards_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *bus_info) mlxsw_linecards_init() argument 1581 mlxsw_linecards_fini(struct mlxsw_core *mlxsw_core) mlxsw_linecards_fini() argument [all...] |
H A D | minimal.c | 36 struct mlxsw_core *core; 110 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_info() 122 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_eeprom() 135 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_eeprom_by_page() 146 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_reset() 159 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_power_mode() 172 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_set_module_power_mode() 545 mlxsw_m_ports_remove_selected(struct mlxsw_core *mlxsw_core, in mlxsw_m_ports_remove_selected() argument 549 struct mlxsw_m *mlxsw_m = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_m_ports_remove_selected() 581 mlxsw_m_got_active(struct mlxsw_core *mlxsw_core, u8 slot_index, void *priv) mlxsw_m_got_active() argument 615 mlxsw_m_got_inactive(struct mlxsw_core *mlxsw_core, u8 slot_index, void *priv) mlxsw_m_got_inactive() argument 634 mlxsw_m_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_m_init() argument 683 mlxsw_m_fini(struct mlxsw_core *mlxsw_core) mlxsw_m_fini() argument [all...] |
H A D | spectrum_ptp.h | 60 int mlxsw_sp_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, 89 int mlxsw_sp2_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, 175 mlxsw_sp_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, in mlxsw_sp_ptp_txhdr_construct() argument 236 mlxsw_sp2_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, in mlxsw_sp2_ptp_txhdr_construct() argument
|
H A D | spectrum.c | 251 mlxsw_sp_txhdr_ptp_data_construct(struct mlxsw_core *mlxsw_core, in mlxsw_sp_txhdr_ptp_data_construct() argument 265 if (!MLXSW_CORE_RES_VALID(mlxsw_core, FID)) { in mlxsw_sp_txhdr_ptp_data_construct() 269 max_fid = MLXSW_CORE_RES_GET(mlxsw_core, FID); in mlxsw_sp_txhdr_ptp_data_construct() 300 static int mlxsw_sp_txhdr_handle(struct mlxsw_core *mlxsw_core, in mlxsw_sp_txhdr_handle() argument 305 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_txhdr_handle() 312 return mlxsw_sp->ptp_ops->txhdr_construct(mlxsw_core, in mlxsw_sp_txhdr_handle() 2099 mlxsw_sp_ports_remove_selected(struct mlxsw_core *mlxsw_core, in mlxsw_sp_ports_remove_selected() argument 2261 mlxsw_sp_port_split(struct mlxsw_core *mlxsw_core, u16 local_port, unsigned int count, struct netlink_ext_ack *extack) mlxsw_sp_port_split() argument 2326 mlxsw_sp_port_unsplit(struct mlxsw_core *mlxsw_core, u16 local_port, struct netlink_ext_ack *extack) mlxsw_sp_port_unsplit() argument 2549 mlxsw_sp_cpu_policers_set(struct mlxsw_core *mlxsw_core) mlxsw_sp_cpu_policers_set() argument 2590 mlxsw_sp_trap_groups_set(struct mlxsw_core *mlxsw_core) mlxsw_sp_trap_groups_set() argument 3086 mlxsw_sp_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp_init() argument 3322 mlxsw_sp1_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp1_init() argument 3355 mlxsw_sp2_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp2_init() argument 3389 mlxsw_sp3_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp3_init() argument 3423 mlxsw_sp4_init(struct mlxsw_core *mlxsw_core, const struct mlxsw_bus_info *mlxsw_bus_info, struct netlink_ext_ack *extack) mlxsw_sp4_init() argument 3457 mlxsw_sp_fini(struct mlxsw_core *mlxsw_core) mlxsw_sp_fini() argument 3559 mlxsw_sp_resource_size_params_prepare(struct mlxsw_core *mlxsw_core, struct devlink_resource_size_params *kvd_size_params, struct devlink_resource_size_params *linear_size_params, struct devlink_resource_size_params *hash_double_size_params, struct devlink_resource_size_params *hash_single_size_params) mlxsw_sp_resource_size_params_prepare() argument 3594 mlxsw_sp1_resources_kvd_register(struct mlxsw_core *mlxsw_core) mlxsw_sp1_resources_kvd_register() argument 3660 mlxsw_sp2_resources_kvd_register(struct mlxsw_core *mlxsw_core) mlxsw_sp2_resources_kvd_register() argument 3680 mlxsw_sp_resources_span_register(struct mlxsw_core *mlxsw_core) mlxsw_sp_resources_span_register() argument 3700 mlxsw_sp_resources_rif_mac_profile_register(struct mlxsw_core *mlxsw_core) mlxsw_sp_resources_rif_mac_profile_register() argument 3723 mlxsw_sp_resources_rifs_register(struct mlxsw_core *mlxsw_core) mlxsw_sp_resources_rifs_register() argument 3743 mlxsw_sp_resources_port_range_register(struct mlxsw_core *mlxsw_core) mlxsw_sp_resources_port_range_register() argument 3762 mlxsw_sp1_resources_register(struct mlxsw_core *mlxsw_core) mlxsw_sp1_resources_register() argument 3806 mlxsw_sp2_resources_register(struct mlxsw_core *mlxsw_core) mlxsw_sp2_resources_register() argument 3850 mlxsw_sp_kvd_sizes_get(struct mlxsw_core *mlxsw_core, const struct mlxsw_config_profile *profile, u64 *p_single_size, u64 *p_double_size, u64 *p_linear_size) mlxsw_sp_kvd_sizes_get() argument 3905 mlxsw_sp_ptp_transmitted(struct mlxsw_core *mlxsw_core, struct sk_buff *skb, u16 local_port) mlxsw_sp_ptp_transmitted() argument [all...] |
H A D | Makefile | 2 obj-$(CONFIG_MLXSW_CORE) += mlxsw_core.o 3 mlxsw_core-objs := core.o core_acl_flex_keys.o \ 6 mlxsw_core-$(CONFIG_MLXSW_CORE_HWMON) += core_hwmon.o 7 mlxsw_core-$(CONFIG_MLXSW_CORE_THERMAL) += core_thermal.o
|
H A D | spectrum_ptp.c | 76 struct mlxsw_core *core; 114 struct mlxsw_core *mlxsw_core = clock->common.core; in __mlxsw_sp1_ptp_read_frc() local 117 frc_h1 = mlxsw_core_read_frc_h(mlxsw_core); in __mlxsw_sp1_ptp_read_frc() 119 frc_l = mlxsw_core_read_frc_l(mlxsw_core); in __mlxsw_sp1_ptp_read_frc() 121 frc_h2 = mlxsw_core_read_frc_h(mlxsw_core); in __mlxsw_sp1_ptp_read_frc() 126 frc_l = mlxsw_core_read_frc_l(mlxsw_core); in __mlxsw_sp1_ptp_read_frc() 144 struct mlxsw_core *mlxsw_core = clock->core; in mlxsw_sp_ptp_phc_adjfreq() local 149 return mlxsw_reg_write(mlxsw_core, MLXSW_RE in mlxsw_sp_ptp_phc_adjfreq() 165 struct mlxsw_core *mlxsw_core = clock->common.core; mlxsw_sp1_ptp_phc_settime() local 339 struct mlxsw_core *mlxsw_core = clock->core; mlxsw_sp2_ptp_read_utc() local 361 struct mlxsw_core *mlxsw_core = clock->core; mlxsw_sp2_ptp_phc_settime() local 389 struct mlxsw_core *mlxsw_core = clock->core; mlxsw_sp2_ptp_adjtime() local 1386 mlxsw_ptp_utc_time_stamp_sec_get(struct mlxsw_core *mlxsw_core, u8 cqe_ts_sec) mlxsw_ptp_utc_time_stamp_sec_get() argument 1403 mlxsw_sp2_ptp_hwtstamp_fill(struct mlxsw_core *mlxsw_core, const struct mlxsw_skb_cb *cb, struct skb_shared_hwtstamps *hwtstamps) mlxsw_sp2_ptp_hwtstamp_fill() argument 1682 mlxsw_sp_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, struct mlxsw_sp_port *mlxsw_sp_port, struct sk_buff *skb, const struct mlxsw_tx_info *tx_info) mlxsw_sp_ptp_txhdr_construct() argument 1691 mlxsw_sp2_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, struct mlxsw_sp_port *mlxsw_sp_port, struct sk_buff *skb, const struct mlxsw_tx_info *tx_info) mlxsw_sp2_ptp_txhdr_construct() argument [all...] |
H A D | spectrum.h | 163 struct mlxsw_core *core; 248 int (*txhdr_construct)(struct mlxsw_core *mlxsw_core, 584 int mlxsw_sp_sb_pool_get(struct mlxsw_core *mlxsw_core, 587 int mlxsw_sp_sb_pool_set(struct mlxsw_core *mlxsw_core, 606 int mlxsw_sp_sb_occ_snapshot(struct mlxsw_core *mlxsw_core, 608 int mlxsw_sp_sb_occ_max_clear(struct mlxsw_core *mlxsw_cor [all...] |
H A D | spectrum_trap.c | 1568 int mlxsw_sp_trap_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_init() argument 1571 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_trap_init() 1586 err = mlxsw_core_trap_register(mlxsw_core, listener, trap_ctx); in mlxsw_sp_trap_init() 1594 void mlxsw_sp_trap_fini(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_fini() argument 1597 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_trap_fini() 1611 mlxsw_core_trap_unregister(mlxsw_core, listener, trap_ctx); in mlxsw_sp_trap_fini() 1615 int mlxsw_sp_trap_action_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_action_set() argument 1661 __mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group, u32 policer_id, struct netlink_ext_ack *extack) __mlxsw_sp_trap_group_init() argument 1694 mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group) mlxsw_sp_trap_group_init() argument 1701 mlxsw_sp_trap_group_set(struct mlxsw_core *mlxsw_core, const struct devlink_trap_group *group, const struct devlink_trap_policer *policer, struct netlink_ext_ack *extack) mlxsw_sp_trap_group_set() argument 1773 mlxsw_sp_trap_policer_init(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer) mlxsw_sp_trap_policer_init() argument 1801 mlxsw_sp_trap_policer_fini(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer) mlxsw_sp_trap_policer_fini() argument 1814 mlxsw_sp_trap_policer_set(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer, u64 rate, u64 burst, struct netlink_ext_ack *extack) mlxsw_sp_trap_policer_set() argument 1831 mlxsw_sp_trap_policer_counter_get(struct mlxsw_core *mlxsw_core, const struct devlink_trap_policer *policer, u64 *p_drops) mlxsw_sp_trap_policer_counter_get() argument [all...] |