Home
last modified time | relevance | path

Searched refs:mlxsw_core (Results 1 – 23 of 23) sorted by relevance

/linux/drivers/net/ethernet/mellanox/mlxsw/
A Dcore.h36 void *mlxsw_core_driver_priv(struct mlxsw_core *mlxsw_core);
201 int mlxsw_reg_query(struct mlxsw_core *mlxsw_core,
203 int mlxsw_reg_write(struct mlxsw_core *mlxsw_core,
314 int (*init)(struct mlxsw_core *mlxsw_core,
317 void (*fini)(struct mlxsw_core *mlxsw_core);
325 int (*sb_pool_get)(struct mlxsw_core *mlxsw_core,
328 int (*sb_pool_set)(struct mlxsw_core *mlxsw_core,
358 int (*trap_init)(struct mlxsw_core *mlxsw_core,
360 void (*trap_fini)(struct mlxsw_core *mlxsw_core,
386 int (*kvd_sizes_get)(struct mlxsw_core *mlxsw_core,
[all …]
A Dcore.c101 struct mlxsw_core *mlxsw_core = priv; in mlxsw_ports_occ_get() argument
210 struct mlxsw_core *mlxsw_core; member
934 struct mlxsw_core *mlxsw_core; member
943 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; in mlxsw_core_fw_component_query() local
962 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; in mlxsw_core_fw_fsm_lock() local
985 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; in mlxsw_core_fw_fsm_component_update() local
998 struct mlxsw_core *mlxsw_core = mlxsw_core_fw_info->mlxsw_core; in mlxsw_core_fw_fsm_block_download() local
1096 .mlxsw_core = mlxsw_core in mlxsw_core_fw_flash()
1676 struct mlxsw_core *mlxsw_core; member
1684 struct mlxsw_core *mlxsw_core; in mlxsw_core_health_event_work() local
[all …]
A Dcmd.h26 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
41 static inline int mlxsw_cmd_exec_out(struct mlxsw_core *mlxsw_core, u16 opcode, in mlxsw_cmd_exec_out() argument
199 static inline int mlxsw_cmd_query_fw(struct mlxsw_core *mlxsw_core, in mlxsw_cmd_query_fw() argument
339 static inline int mlxsw_cmd_boardinfo(struct mlxsw_core *mlxsw_core, in mlxsw_cmd_boardinfo() argument
478 static inline int mlxsw_cmd_map_fa(struct mlxsw_core *mlxsw_core, in mlxsw_cmd_map_fa() argument
507 static inline int mlxsw_cmd_unmap_fa(struct mlxsw_core *mlxsw_core) in mlxsw_cmd_unmap_fa() argument
1006 static inline int mlxsw_cmd_2err_sdq(struct mlxsw_core *mlxsw_core, in mlxsw_cmd_2err_sdq() argument
1013 static inline int mlxsw_cmd_2err_rdq(struct mlxsw_core *mlxsw_core, in mlxsw_cmd_2err_rdq() argument
[all …]
A Dcore_env.h15 int mlxsw_env_get_module_info(struct mlxsw_core *mlxsw_core, int module,
19 struct mlxsw_core *mlxsw_core, int module,
23 mlxsw_env_get_module_eeprom_by_page(struct mlxsw_core *mlxsw_core, u8 module,
28 struct mlxsw_core *mlxsw_core, u8 module,
32 mlxsw_env_get_module_power_mode(struct mlxsw_core *mlxsw_core, u8 module,
37 mlxsw_env_set_module_power_mode(struct mlxsw_core *mlxsw_core, u8 module,
42 mlxsw_env_module_overheat_counter_get(struct mlxsw_core *mlxsw_core, u8 module,
45 void mlxsw_env_module_port_map(struct mlxsw_core *mlxsw_core, u8 module);
47 void mlxsw_env_module_port_unmap(struct mlxsw_core *mlxsw_core, u8 module);
49 int mlxsw_env_module_port_up(struct mlxsw_core *mlxsw_core, u8 module);
[all …]
A Dcore_env.c24 struct mlxsw_core *core;
67 mlxsw_env_query_module_eeprom(struct mlxsw_core *mlxsw_core, int module, in mlxsw_env_query_module_eeprom() argument
209 int mlxsw_env_get_module_info(struct mlxsw_core *mlxsw_core, int module, in mlxsw_env_get_module_info() argument
288 struct mlxsw_core *mlxsw_core, int module, in mlxsw_env_get_module_eeprom() argument
407 struct mlxsw_core *mlxsw_core, u8 module, u32 *flags) in mlxsw_env_reset_module() argument
488 static int mlxsw_env_module_enable_set(struct mlxsw_core *mlxsw_core, in mlxsw_env_module_enable_set() argument
503 static int mlxsw_env_module_low_power_set(struct mlxsw_core *mlxsw_core, in mlxsw_env_module_low_power_set() argument
624 static int mlxsw_env_temp_event_set(struct mlxsw_core *mlxsw_core, in mlxsw_env_temp_event_set() argument
855 mlxsw_env_module_plug_event_register(struct mlxsw_core *mlxsw_core) in mlxsw_env_module_plug_event_register() argument
879 mlxsw_env_module_oper_state_event_enable(struct mlxsw_core *mlxsw_core, in mlxsw_env_module_oper_state_event_enable() argument
[all …]
A Dspectrum.c2307 static int mlxsw_sp_cpu_policers_set(struct mlxsw_core *mlxsw_core) in mlxsw_sp_cpu_policers_set() argument
2348 static int mlxsw_sp_trap_groups_set(struct mlxsw_core *mlxsw_core) in mlxsw_sp_trap_groups_set() argument
2758 static int mlxsw_sp_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_init() argument
2972 static int mlxsw_sp1_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp1_init() argument
3003 static int mlxsw_sp2_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp2_init() argument
3032 static int mlxsw_sp3_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp3_init() argument
3061 static void mlxsw_sp_fini(struct mlxsw_core *mlxsw_core) in mlxsw_sp_fini() argument
3377 static int mlxsw_sp_kvd_sizes_get(struct mlxsw_core *mlxsw_core, in mlxsw_sp_kvd_sizes_get() argument
3436 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); in mlxsw_sp_params_acl_region_rehash_intrvl_get() local
3447 struct mlxsw_core *mlxsw_core = devlink_priv(devlink); in mlxsw_sp_params_acl_region_rehash_intrvl_set() local
[all …]
A Dminimal.c32 struct mlxsw_core *core;
111 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_info()
121 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_eeprom()
133 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_eeprom_by_page()
142 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_reset()
154 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_get_module_power_mode()
166 struct mlxsw_core *core = mlxsw_m_port->mlxsw_m->core; in mlxsw_m_set_module_power_mode()
419 static int mlxsw_m_init(struct mlxsw_core *mlxsw_core, in mlxsw_m_init() argument
423 struct mlxsw_m *mlxsw_m = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_m_init()
426 mlxsw_m->core = mlxsw_core; in mlxsw_m_init()
[all …]
A Dspectrum.h538 int mlxsw_sp_sb_pool_get(struct mlxsw_core *mlxsw_core,
541 int mlxsw_sp_sb_pool_set(struct mlxsw_core *mlxsw_core,
560 int mlxsw_sp_sb_occ_snapshot(struct mlxsw_core *mlxsw_core,
562 int mlxsw_sp_sb_occ_max_clear(struct mlxsw_core *mlxsw_core,
1330 int mlxsw_sp_trap_init(struct mlxsw_core *mlxsw_core,
1332 void mlxsw_sp_trap_fini(struct mlxsw_core *mlxsw_core,
1334 int mlxsw_sp_trap_action_set(struct mlxsw_core *mlxsw_core,
1338 int mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core,
1340 int mlxsw_sp_trap_group_set(struct mlxsw_core *mlxsw_core,
1345 mlxsw_sp_trap_policer_init(struct mlxsw_core *mlxsw_core,
[all …]
A Dspectrum_trap.c1544 int mlxsw_sp_trap_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_init() argument
1570 void mlxsw_sp_trap_fini(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_fini() argument
1591 int mlxsw_sp_trap_action_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_action_set() argument
1637 __mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, in __mlxsw_sp_trap_group_init() argument
1670 int mlxsw_sp_trap_group_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_group_init() argument
1673 return __mlxsw_sp_trap_group_init(mlxsw_core, group, in mlxsw_sp_trap_group_init()
1677 int mlxsw_sp_trap_group_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_group_set() argument
1749 int mlxsw_sp_trap_policer_init(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_policer_init() argument
1777 void mlxsw_sp_trap_policer_fini(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_policer_fini() argument
1790 int mlxsw_sp_trap_policer_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_trap_policer_set() argument
[all …]
A DMakefile2 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
A Dspectrum_cnt.c242 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()
A Dspectrum_policer.c82 struct mlxsw_core *core = family->mlxsw_sp->core; in mlxsw_sp_policer_single_rate_family_init()
404 int mlxsw_sp_policer_resources_register(struct mlxsw_core *mlxsw_core) in mlxsw_sp_policer_resources_register() argument
407 struct devlink *devlink = priv_to_devlink(mlxsw_core); in mlxsw_sp_policer_resources_register()
411 if (!MLXSW_CORE_RES_VALID(mlxsw_core, MAX_GLOBAL_POLICERS) || in mlxsw_sp_policer_resources_register()
412 !MLXSW_CORE_RES_VALID(mlxsw_core, MAX_CPU_POLICERS)) in mlxsw_sp_policer_resources_register()
415 global_policers = MLXSW_CORE_RES_GET(mlxsw_core, MAX_GLOBAL_POLICERS); in mlxsw_sp_policer_resources_register()
416 cpu_policers = MLXSW_CORE_RES_GET(mlxsw_core, MAX_CPU_POLICERS); in mlxsw_sp_policer_resources_register()
A Dspectrum_buffers.c273 static void mlxsw_sp_sb_pm_occ_query_cb(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_pm_occ_query_cb() argument
1328 int mlxsw_sp_sb_pool_get(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_pool_get() argument
1332 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_sb_pool_get()
1345 int mlxsw_sp_sb_pool_set(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_pool_set() argument
1350 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_sb_pool_set()
1532 static void mlxsw_sp_sb_sr_occ_query_cb(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_sr_occ_query_cb() argument
1536 struct mlxsw_sp *mlxsw_sp = mlxsw_core_driver_priv(mlxsw_core); in mlxsw_sp_sb_sr_occ_query_cb()
1581 int mlxsw_sp_sb_occ_snapshot(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_occ_snapshot() argument
1637 if (local_port < mlxsw_core_max_ports(mlxsw_core)) { in mlxsw_sp_sb_occ_snapshot()
1650 int mlxsw_sp_sb_occ_max_clear(struct mlxsw_core *mlxsw_core, in mlxsw_sp_sb_occ_max_clear() argument
[all …]
A Dspectrum_ptp.c62 struct mlxsw_core *core;
76 struct mlxsw_core *mlxsw_core = clock->core; in __mlxsw_sp1_ptp_read_frc() local
79 frc_h1 = mlxsw_core_read_frc_h(mlxsw_core); in __mlxsw_sp1_ptp_read_frc()
81 frc_l = mlxsw_core_read_frc_l(mlxsw_core); in __mlxsw_sp1_ptp_read_frc()
83 frc_h2 = mlxsw_core_read_frc_h(mlxsw_core); in __mlxsw_sp1_ptp_read_frc()
88 frc_l = mlxsw_core_read_frc_l(mlxsw_core); in __mlxsw_sp1_ptp_read_frc()
106 struct mlxsw_core *mlxsw_core = clock->core; in mlxsw_sp1_ptp_phc_adjfreq() local
111 return mlxsw_reg_write(mlxsw_core, MLXSW_REG(mtutc), mtutc_pl); in mlxsw_sp1_ptp_phc_adjfreq()
127 struct mlxsw_core *mlxsw_core = clock->core; in mlxsw_sp1_ptp_phc_settime() local
141 err = mlxsw_reg_write(mlxsw_core, MLXSW_REG(mtpps), mtpps_pl); in mlxsw_sp1_ptp_phc_settime()
[all …]
A Dspectrum_cnt.h23 int mlxsw_sp_counter_resources_register(struct mlxsw_core *mlxsw_core);
A Dspectrum1_kvdl.c386 int mlxsw_sp1_kvdl_resources_register(struct mlxsw_core *mlxsw_core) in mlxsw_sp1_kvdl_resources_register() argument
388 struct devlink *devlink = priv_to_devlink(mlxsw_core); in mlxsw_sp1_kvdl_resources_register()
393 kvdl_max_size = MLXSW_CORE_RES_GET(mlxsw_core, KVD_SIZE) - in mlxsw_sp1_kvdl_resources_register()
394 MLXSW_CORE_RES_GET(mlxsw_core, KVD_SINGLE_MIN_SIZE) - in mlxsw_sp1_kvdl_resources_register()
395 MLXSW_CORE_RES_GET(mlxsw_core, KVD_DOUBLE_MIN_SIZE); in mlxsw_sp1_kvdl_resources_register()
A Di2c.c76 struct mlxsw_core *core;
510 mlxsw_i2c_init(void *bus_priv, struct mlxsw_core *mlxsw_core, in mlxsw_i2c_init() argument
518 mlxsw_i2c->core = mlxsw_core; in mlxsw_i2c_init()
524 err = mlxsw_cmd_query_fw(mlxsw_core, mbox); in mlxsw_i2c_init()
535 err = mlxsw_core_resources_query(mlxsw_core, mbox, res); in mlxsw_i2c_init()
A Dcore_thermal.c88 struct mlxsw_core *core;
143 mlxsw_thermal_module_trips_update(struct device *dev, struct mlxsw_core *core, in mlxsw_thermal_module_trips_update()
421 mlxsw_thermal_module_temp_and_thresholds_get(struct mlxsw_core *core, in mlxsw_thermal_module_temp_and_thresholds_get()
701 mlxsw_thermal_module_init(struct device *dev, struct mlxsw_core *core, in mlxsw_thermal_module_init()
737 mlxsw_thermal_modules_init(struct device *dev, struct mlxsw_core *core, in mlxsw_thermal_modules_init()
830 mlxsw_thermal_gearboxes_init(struct device *dev, struct mlxsw_core *core, in mlxsw_thermal_gearboxes_init()
894 int mlxsw_thermal_init(struct mlxsw_core *core, in mlxsw_thermal_init()
A Dpci.c108 struct mlxsw_core *core;
1489 static int mlxsw_pci_init(void *bus_priv, struct mlxsw_core *mlxsw_core, in mlxsw_pci_init() argument
1499 mlxsw_pci->core = mlxsw_core; in mlxsw_pci_init()
1515 err = mlxsw_cmd_query_fw(mlxsw_core, mbox); in mlxsw_pci_init()
1562 if (MLXSW_CORE_RES_VALID(mlxsw_core, CQE_V2) && in mlxsw_pci_init()
1563 MLXSW_CORE_RES_GET(mlxsw_core, CQE_V2)) in mlxsw_pci_init()
1565 else if (MLXSW_CORE_RES_VALID(mlxsw_core, CQE_V1) && in mlxsw_pci_init()
1566 MLXSW_CORE_RES_GET(mlxsw_core, CQE_V1)) in mlxsw_pci_init()
1568 else if ((MLXSW_CORE_RES_VALID(mlxsw_core, CQE_V0) && in mlxsw_pci_init()
1569 MLXSW_CORE_RES_GET(mlxsw_core, CQE_V0)) || in mlxsw_pci_init()
[all …]
A Dcore_hwmon.c44 struct mlxsw_core *core;
752 int mlxsw_hwmon_init(struct mlxsw_core *mlxsw_core, in mlxsw_hwmon_init() argument
763 mlxsw_hwmon->core = mlxsw_core; in mlxsw_hwmon_init()
A DKconfig14 module will be called mlxsw_core.
A Dspectrum_ethtool.c572 struct mlxsw_core *mlxsw_core = mlxsw_sp_port->mlxsw_sp->core; in mlxsw_sp_port_get_transceiver_overheat_stats() local
576 err = mlxsw_env_module_overheat_counter_get(mlxsw_core, in mlxsw_sp_port_get_transceiver_overheat_stats()
A Dspectrum_router.c9767 struct mlxsw_core *core = mlxsw_sp->core; in mlxsw_sp_rifs_init()

Completed in 99 milliseconds