devlink 1813 drivers/net/ethernet/broadcom/bnxt/bnxt.h struct devlink *dl; devlink 357 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c static int bnxt_dl_nvm_param_get(struct devlink *dl, u32 id, devlink 373 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c static int bnxt_dl_nvm_param_set(struct devlink *dl, u32 id, devlink 387 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c static int bnxt_dl_msix_validate(struct devlink *dl, u32 id, devlink 436 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c struct devlink *dl; devlink 512 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c struct devlink *dl = bp->dl; devlink 18 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.h static inline struct bnxt *bnxt_get_bp_from_dl(struct devlink *dl) devlink 24 drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.h static inline void bnxt_link_bp_to_dl(struct bnxt *bp, struct devlink *dl) devlink 475 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c int bnxt_dl_eswitch_mode_get(struct devlink *devlink, u16 *mode) devlink 477 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c struct bnxt *bp = bnxt_get_bp_from_dl(devlink); devlink 483 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c int bnxt_dl_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 486 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c struct bnxt *bp = bnxt_get_bp_from_dl(devlink); devlink 32 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.h int bnxt_dl_eswitch_mode_get(struct devlink *devlink, u16 *mode); devlink 33 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.h int bnxt_dl_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 1328 drivers/net/ethernet/cavium/liquidio/lio_main.c if (oct->devlink) { devlink 1329 drivers/net/ethernet/cavium/liquidio/lio_main.c devlink_unregister(oct->devlink); devlink 1330 drivers/net/ethernet/cavium/liquidio/lio_main.c devlink_free(oct->devlink); devlink 1331 drivers/net/ethernet/cavium/liquidio/lio_main.c oct->devlink = NULL; devlink 3136 drivers/net/ethernet/cavium/liquidio/lio_main.c liquidio_eswitch_mode_get(struct devlink *devlink, u16 *mode) devlink 3141 drivers/net/ethernet/cavium/liquidio/lio_main.c priv = devlink_priv(devlink); devlink 3150 drivers/net/ethernet/cavium/liquidio/lio_main.c liquidio_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 3157 drivers/net/ethernet/cavium/liquidio/lio_main.c priv = devlink_priv(devlink); devlink 3365 drivers/net/ethernet/cavium/liquidio/lio_main.c struct devlink *devlink; devlink 3767 drivers/net/ethernet/cavium/liquidio/lio_main.c devlink = devlink_alloc(&liquidio_devlink_ops, devlink 3769 drivers/net/ethernet/cavium/liquidio/lio_main.c if (!devlink) { devlink 3774 drivers/net/ethernet/cavium/liquidio/lio_main.c lio_devlink = devlink_priv(devlink); devlink 3777 drivers/net/ethernet/cavium/liquidio/lio_main.c if (devlink_register(devlink, &octeon_dev->pci_dev->dev)) { devlink 3778 drivers/net/ethernet/cavium/liquidio/lio_main.c devlink_free(devlink); devlink 3784 drivers/net/ethernet/cavium/liquidio/lio_main.c octeon_dev->devlink = devlink; devlink 607 drivers/net/ethernet/cavium/liquidio/octeon_device.h struct devlink *devlink; devlink 157 drivers/net/ethernet/mellanox/mlx4/crdump.c struct devlink *devlink = priv_to_devlink(mlx4_priv(dev)); devlink 185 drivers/net/ethernet/mellanox/mlx4/crdump.c id = devlink_region_shapshot_id_get(devlink); devlink 199 drivers/net/ethernet/mellanox/mlx4/crdump.c struct devlink *devlink = priv_to_devlink(mlx4_priv(dev)); devlink 207 drivers/net/ethernet/mellanox/mlx4/crdump.c devlink_region_create(devlink, devlink 218 drivers/net/ethernet/mellanox/mlx4/crdump.c devlink_region_create(devlink, devlink 181 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_ierr_reset_get(struct devlink *devlink, u32 id, devlink 188 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_ierr_reset_set(struct devlink *devlink, u32 id, devlink 195 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_crdump_snapshot_get(struct devlink *devlink, u32 id, devlink 198 drivers/net/ethernet/mellanox/mlx4/main.c struct mlx4_priv *priv = devlink_priv(devlink); devlink 205 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_crdump_snapshot_set(struct devlink *devlink, u32 id, devlink 208 drivers/net/ethernet/mellanox/mlx4/main.c struct mlx4_priv *priv = devlink_priv(devlink); devlink 216 drivers/net/ethernet/mellanox/mlx4/main.c mlx4_devlink_max_macs_validate(struct devlink *devlink, u32 id, devlink 263 drivers/net/ethernet/mellanox/mlx4/main.c static void mlx4_devlink_set_params_init_values(struct devlink *devlink) devlink 268 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_driverinit_value_set(devlink, devlink 273 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_driverinit_value_set(devlink, devlink 278 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_driverinit_value_set(devlink, devlink 283 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_driverinit_value_set(devlink, devlink 288 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_driverinit_value_set(devlink, devlink 3028 drivers/net/ethernet/mellanox/mlx4/main.c struct devlink *devlink = priv_to_devlink(mlx4_priv(dev)); devlink 3032 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_port_register(devlink, &info->devlink_port, port); devlink 3893 drivers/net/ethernet/mellanox/mlx4/main.c static void mlx4_devlink_param_load_driverinit_values(struct devlink *devlink) devlink 3895 drivers/net/ethernet/mellanox/mlx4/main.c struct mlx4_priv *priv = devlink_priv(devlink); devlink 3901 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_param_driverinit_value_get(devlink, devlink 3907 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_value_changed(devlink, devlink 3910 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_param_driverinit_value_get(devlink, devlink 3915 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_param_driverinit_value_get(devlink, devlink 3920 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_param_driverinit_value_get(devlink, devlink 3925 drivers/net/ethernet/mellanox/mlx4/main.c err = devlink_param_driverinit_value_get(devlink, devlink 3930 drivers/net/ethernet/mellanox/mlx4/main.c devlink_param_value_changed(devlink, devlink 3937 drivers/net/ethernet/mellanox/mlx4/main.c struct devlink *devlink); devlink 3939 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_reload_down(struct devlink *devlink, devlink 3942 drivers/net/ethernet/mellanox/mlx4/main.c struct mlx4_priv *priv = devlink_priv(devlink); devlink 3952 drivers/net/ethernet/mellanox/mlx4/main.c static int mlx4_devlink_reload_up(struct devlink *devlink, devlink 3955 drivers/net/ethernet/mellanox/mlx4/main.c struct mlx4_priv *priv = devlink_priv(devlink); devlink 3960 drivers/net/ethernet/mellanox/mlx4/main.c err = mlx4_restart_one_up(persist->pdev, true, devlink); devlink 3976 drivers/net/ethernet/mellanox/mlx4/main.c struct devlink *devlink; devlink 3983 drivers/net/ethernet/mellanox/mlx4/main.c devlink = devlink_alloc(&mlx4_devlink_ops, sizeof(*priv)); devlink 3984 drivers/net/ethernet/mellanox/mlx4/main.c if (!devlink) devlink 3986 drivers/net/ethernet/mellanox/mlx4/main.c priv = devlink_priv(devlink); devlink 4002 drivers/net/ethernet/mellanox/mlx4/main.c ret = devlink_register(devlink, &pdev->dev); devlink 4005 drivers/net/ethernet/mellanox/mlx4/main.c ret = devlink_params_register(devlink, mlx4_devlink_params, devlink 4009 drivers/net/ethernet/mellanox/mlx4/main.c mlx4_devlink_set_params_init_values(devlink); devlink 4014 drivers/net/ethernet/mellanox/mlx4/main.c devlink_params_publish(devlink); devlink 4015 drivers/net/ethernet/mellanox/mlx4/main.c devlink_reload_enable(devlink); devlink 4020 drivers/net/ethernet/mellanox/mlx4/main.c devlink_params_unregister(devlink, mlx4_devlink_params, devlink 4023 drivers/net/ethernet/mellanox/mlx4/main.c devlink_unregister(devlink); devlink 4027 drivers/net/ethernet/mellanox/mlx4/main.c devlink_free(devlink); devlink 4124 drivers/net/ethernet/mellanox/mlx4/main.c struct devlink *devlink = priv_to_devlink(priv); devlink 4127 drivers/net/ethernet/mellanox/mlx4/main.c devlink_reload_disable(devlink); devlink 4161 drivers/net/ethernet/mellanox/mlx4/main.c devlink_params_unregister(devlink, mlx4_devlink_params, devlink 4163 drivers/net/ethernet/mellanox/mlx4/main.c devlink_unregister(devlink); devlink 4165 drivers/net/ethernet/mellanox/mlx4/main.c devlink_free(devlink); devlink 4193 drivers/net/ethernet/mellanox/mlx4/main.c struct devlink *devlink) devlink 4206 drivers/net/ethernet/mellanox/mlx4/main.c mlx4_devlink_param_load_driverinit_values(devlink); devlink 10 drivers/net/ethernet/mellanox/mlx5/core/devlink.c static int mlx5_devlink_flash_update(struct devlink *devlink, devlink 15 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 50 drivers/net/ethernet/mellanox/mlx5/core/devlink.c mlx5_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req, devlink 53 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 104 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct devlink *mlx5_devlink_alloc(void) devlink 109 drivers/net/ethernet/mellanox/mlx5/core/devlink.c void mlx5_devlink_free(struct devlink *devlink) devlink 111 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_free(devlink); devlink 114 drivers/net/ethernet/mellanox/mlx5/core/devlink.c static int mlx5_devlink_fs_mode_validate(struct devlink *devlink, u32 id, devlink 118 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 151 drivers/net/ethernet/mellanox/mlx5/core/devlink.c static int mlx5_devlink_fs_mode_set(struct devlink *devlink, u32 id, devlink 154 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 166 drivers/net/ethernet/mellanox/mlx5/core/devlink.c static int mlx5_devlink_fs_mode_get(struct devlink *devlink, u32 id, devlink 169 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 191 drivers/net/ethernet/mellanox/mlx5/core/devlink.c static void mlx5_devlink_set_params_init_values(struct devlink *devlink) devlink 193 drivers/net/ethernet/mellanox/mlx5/core/devlink.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 200 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_param_driverinit_value_set(devlink, devlink 205 drivers/net/ethernet/mellanox/mlx5/core/devlink.c int mlx5_devlink_register(struct devlink *devlink, struct device *dev) devlink 209 drivers/net/ethernet/mellanox/mlx5/core/devlink.c err = devlink_register(devlink, dev); devlink 213 drivers/net/ethernet/mellanox/mlx5/core/devlink.c err = devlink_params_register(devlink, mlx5_devlink_params, devlink 217 drivers/net/ethernet/mellanox/mlx5/core/devlink.c mlx5_devlink_set_params_init_values(devlink); devlink 218 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_params_publish(devlink); devlink 222 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_unregister(devlink); devlink 226 drivers/net/ethernet/mellanox/mlx5/core/devlink.c void mlx5_devlink_unregister(struct devlink *devlink) devlink 228 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_params_unregister(devlink, mlx5_devlink_params, devlink 230 drivers/net/ethernet/mellanox/mlx5/core/devlink.c devlink_unregister(devlink); devlink 9 drivers/net/ethernet/mellanox/mlx5/core/devlink.h struct devlink *mlx5_devlink_alloc(void); devlink 10 drivers/net/ethernet/mellanox/mlx5/core/devlink.h void mlx5_devlink_free(struct devlink *devlink); devlink 11 drivers/net/ethernet/mellanox/mlx5/core/devlink.h int mlx5_devlink_register(struct devlink *devlink, struct device *dev); devlink 12 drivers/net/ethernet/mellanox/mlx5/core/devlink.h void mlx5_devlink_unregister(struct devlink *devlink); devlink 382 drivers/net/ethernet/mellanox/mlx5/core/en/reporter_rx.c struct devlink *devlink = priv_to_devlink(priv->mdev); devlink 385 drivers/net/ethernet/mellanox/mlx5/core/en/reporter_rx.c reporter = devlink_health_reporter_create(devlink, devlink 288 drivers/net/ethernet/mellanox/mlx5/core/en/reporter_tx.c struct devlink *devlink; devlink 290 drivers/net/ethernet/mellanox/mlx5/core/en/reporter_tx.c devlink = priv_to_devlink(mdev); devlink 292 drivers/net/ethernet/mellanox/mlx5/core/en/reporter_tx.c devlink_health_reporter_create(devlink, &mlx5_tx_reporter_ops, devlink 1813 drivers/net/ethernet/mellanox/mlx5/core/en_rep.c struct devlink *devlink = priv_to_devlink(dev); devlink 1844 drivers/net/ethernet/mellanox/mlx5/core/en_rep.c return devlink_port_register(devlink, &rpriv->dl_port, dl_port_index); devlink 403 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 405 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_mode_get(struct devlink *devlink, u16 *mode); devlink 406 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_inline_mode_set(struct devlink *devlink, u8 mode, devlink 408 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_inline_mode_get(struct devlink *devlink, u8 *mode); devlink 410 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_encap_mode_set(struct devlink *devlink, devlink 413 drivers/net/ethernet/mellanox/mlx5/core/eswitch.h int mlx5_devlink_eswitch_encap_mode_get(struct devlink *devlink, devlink 2299 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c static int mlx5_devlink_eswitch_check(struct devlink *devlink) devlink 2301 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2316 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 2319 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2323 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 2343 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_mode_get(struct devlink *devlink, u16 *mode) devlink 2345 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2348 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 2355 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_inline_mode_set(struct devlink *devlink, u8 mode, devlink 2358 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2363 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 2411 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_inline_mode_get(struct devlink *devlink, u8 *mode) devlink 2413 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2417 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 2461 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_encap_mode_set(struct devlink *devlink, devlink 2465 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2469 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 2511 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c int mlx5_devlink_eswitch_encap_mode_get(struct devlink *devlink, devlink 2514 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c struct mlx5_core_dev *dev = devlink_priv(devlink); devlink 2518 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c err = mlx5_devlink_eswitch_check(devlink); devlink 646 drivers/net/ethernet/mellanox/mlx5/core/health.c struct devlink *devlink = priv_to_devlink(dev); devlink 649 drivers/net/ethernet/mellanox/mlx5/core/health.c devlink_health_reporter_create(devlink, &mlx5_fw_reporter_ops, devlink 656 drivers/net/ethernet/mellanox/mlx5/core/health.c devlink_health_reporter_create(devlink, devlink 1335 drivers/net/ethernet/mellanox/mlx5/core/main.c struct devlink *devlink; devlink 1338 drivers/net/ethernet/mellanox/mlx5/core/main.c devlink = mlx5_devlink_alloc(); devlink 1339 drivers/net/ethernet/mellanox/mlx5/core/main.c if (!devlink) { devlink 1344 drivers/net/ethernet/mellanox/mlx5/core/main.c dev = devlink_priv(devlink); devlink 1383 drivers/net/ethernet/mellanox/mlx5/core/main.c mlx5_devlink_free(devlink); devlink 1391 drivers/net/ethernet/mellanox/mlx5/core/main.c struct devlink *devlink = priv_to_devlink(dev); devlink 1394 drivers/net/ethernet/mellanox/mlx5/core/main.c mlx5_devlink_unregister(devlink); devlink 1404 drivers/net/ethernet/mellanox/mlx5/core/main.c mlx5_devlink_free(devlink); devlink 739 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_port_split(struct devlink *devlink, devlink 744 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 756 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_port_unsplit(struct devlink *devlink, devlink 760 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 773 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_sb_pool_get(struct devlink *devlink, devlink 777 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 787 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_sb_pool_set(struct devlink *devlink, devlink 792 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 810 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 826 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 842 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 859 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 878 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 890 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_sb_occ_snapshot(struct devlink *devlink, devlink 893 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 901 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_sb_occ_max_clear(struct devlink *devlink, devlink 904 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 917 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 934 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink_port->devlink); devlink 947 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req, devlink 950 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 987 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_core_bus_device_reload_down(struct devlink *devlink, devlink 990 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1000 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_core_bus_device_reload_up(struct devlink *devlink, devlink 1003 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1008 drivers/net/ethernet/mellanox/mlxsw/core.c devlink); devlink 1011 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_flash_update(struct devlink *devlink, devlink 1016 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1025 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_trap_init(struct devlink *devlink, devlink 1029 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1037 drivers/net/ethernet/mellanox/mlxsw/core.c static void mlxsw_devlink_trap_fini(struct devlink *devlink, devlink 1041 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1049 drivers/net/ethernet/mellanox/mlxsw/core.c static int mlxsw_devlink_trap_action_set(struct devlink *devlink, devlink 1053 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1062 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_devlink_trap_group_init(struct devlink *devlink, devlink 1065 drivers/net/ethernet/mellanox/mlxsw/core.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 1101 drivers/net/ethernet/mellanox/mlxsw/core.c struct devlink *devlink) devlink 1116 drivers/net/ethernet/mellanox/mlxsw/core.c devlink = devlink_alloc(&mlxsw_devlink_ops, alloc_size); devlink 1117 drivers/net/ethernet/mellanox/mlxsw/core.c if (!devlink) { devlink 1123 drivers/net/ethernet/mellanox/mlxsw/core.c mlxsw_core = devlink_priv(devlink); devlink 1163 drivers/net/ethernet/mellanox/mlxsw/core.c err = devlink_register(devlink, mlxsw_bus_info->dev); devlink 1190 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_params_publish(devlink); devlink 1193 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_reload_enable(devlink); devlink 1207 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_unregister(devlink); devlink 1216 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_resources_unregister(devlink, NULL); devlink 1221 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_free(devlink); devlink 1229 drivers/net/ethernet/mellanox/mlxsw/core.c struct devlink *devlink) devlink 1236 drivers/net/ethernet/mellanox/mlxsw/core.c bus_priv, reload, devlink); devlink 1253 drivers/net/ethernet/mellanox/mlxsw/core.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 1256 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_reload_disable(devlink); devlink 1257 drivers/net/ethernet/mellanox/mlxsw/core.c if (devlink_is_reload_failed(devlink)) { devlink 1268 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_params_unpublish(devlink); devlink 1276 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_unregister(devlink); devlink 1281 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_resources_unregister(devlink, NULL); devlink 1289 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_unregister(devlink); devlink 1290 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_resources_unregister(devlink, NULL); devlink 1291 drivers/net/ethernet/mellanox/mlxsw/core.c devlink_free(devlink); devlink 1879 drivers/net/ethernet/mellanox/mlxsw/core.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 1889 drivers/net/ethernet/mellanox/mlxsw/core.c err = devlink_port_register(devlink, devlink_port, local_port); devlink 39 drivers/net/ethernet/mellanox/mlxsw/core.h struct devlink *devlink); devlink 5106 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 5125 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD, devlink 5133 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_LINEAR, devlink 5150 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_HASH_DOUBLE, devlink 5159 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_HASH_SINGLE, devlink 5172 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 5184 drivers/net/ethernet/mellanox/mlxsw/spectrum.c return devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD, devlink 5205 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 5220 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_size_get(devlink, devlink 5226 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_size_get(devlink, devlink 5239 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_resource_size_get(devlink, devlink 5256 drivers/net/ethernet/mellanox/mlxsw/spectrum.c mlxsw_sp_devlink_param_fw_load_policy_validate(struct devlink *devlink, u32 id, devlink 5278 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 5282 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_params_register(devlink, mlxsw_sp_devlink_params, devlink 5288 drivers/net/ethernet/mellanox/mlxsw/spectrum.c devlink_param_driverinit_value_set(devlink, devlink 5302 drivers/net/ethernet/mellanox/mlxsw/spectrum.c mlxsw_sp_params_acl_region_rehash_intrvl_get(struct devlink *devlink, u32 id, devlink 5305 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 5313 drivers/net/ethernet/mellanox/mlxsw/spectrum.c mlxsw_sp_params_acl_region_rehash_intrvl_set(struct devlink *devlink, u32 id, devlink 5316 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct mlxsw_core *mlxsw_core = devlink_priv(devlink); devlink 5334 drivers/net/ethernet/mellanox/mlxsw/spectrum.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 5342 drivers/net/ethernet/mellanox/mlxsw/spectrum.c err = devlink_params_register(devlink, mlxsw_sp2_devlink_params, devlink 5348 drivers/net/ethernet/mellanox/mlxsw/spectrum.c devlink_param_driverinit_value_set(devlink, devlink 212 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 220 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c err = devlink_resource_size_get(devlink, info->resource_id, devlink 335 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 342 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_register(devlink, devlink 346 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_register(devlink, devlink 350 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_register(devlink, devlink 354 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_register(devlink, devlink 363 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 366 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_unregister(devlink, devlink 368 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_unregister(devlink, devlink 370 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_unregister(devlink, devlink 372 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c devlink_resource_occ_get_unregister(devlink, devlink 388 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c struct devlink *devlink = priv_to_devlink(mlxsw_core); devlink 400 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_LINEAR_SINGLES, devlink 411 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_LINEAR_CHUNKS, devlink 422 drivers/net/ethernet/mellanox/mlxsw/spectrum1_kvdl.c err = devlink_resource_register(devlink, MLXSW_SP_RESOURCE_NAME_KVD_LINEAR_LARGE_CHUNKS, devlink 295 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 297 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c return devlink_dpipe_table_register(devlink, devlink 305 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 307 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, MLXSW_SP_DPIPE_TABLE_NAME_ERIF); devlink 748 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 751 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_register(devlink, devlink 758 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_resource_set(devlink, devlink 768 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 775 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 777 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 825 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 828 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_register(devlink, devlink 835 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_resource_set(devlink, devlink 845 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 852 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 854 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 1228 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 1231 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_register(devlink, devlink 1238 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_table_resource_set(devlink, devlink 1248 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 1255 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 1257 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_table_unregister(devlink, devlink 1263 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 1266 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c err = devlink_dpipe_headers_register(devlink, devlink 1300 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 1306 drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c devlink_dpipe_headers_unregister(devlink); devlink 306 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c struct devlink *devlink; devlink 308 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c devlink = priv_to_devlink(mlxsw_sp->core); devlink 309 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c if (!devlink_dpipe_table_counter_enabled(devlink, devlink 1992 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c struct devlink *devlink; devlink 2007 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c devlink = priv_to_devlink(mlxsw_sp->core); devlink 2008 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c return devlink_dpipe_table_counter_enabled(devlink, table_name); devlink 2727 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c struct devlink *devlink; devlink 2729 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c devlink = priv_to_devlink(mlxsw_sp->core); devlink 2730 drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c if (!devlink_dpipe_table_counter_enabled(devlink, devlink 91 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c struct devlink *devlink; devlink 99 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c devlink = priv_to_devlink(mlxsw_sp->core); devlink 103 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c devlink_trap_report(devlink, skb, trap_ctx, in_devlink_port); devlink 109 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 115 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c return devlink_traps_register(devlink, mlxsw_sp_traps_arr, devlink 122 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c struct devlink *devlink = priv_to_devlink(mlxsw_sp->core); devlink 124 drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c devlink_traps_unregister(devlink, mlxsw_sp_traps_arr, devlink 83 drivers/net/ethernet/netronome/nfp/devlink_param.c nfp_devlink_param_u8_get(struct devlink *devlink, u32 id, devlink 87 drivers/net/ethernet/netronome/nfp/devlink_param.c struct nfp_pf *pf = devlink_priv(devlink); devlink 134 drivers/net/ethernet/netronome/nfp/devlink_param.c nfp_devlink_param_u8_set(struct devlink *devlink, u32 id, devlink 138 drivers/net/ethernet/netronome/nfp/devlink_param.c struct nfp_pf *pf = devlink_priv(devlink); devlink 170 drivers/net/ethernet/netronome/nfp/devlink_param.c nfp_devlink_param_u8_validate(struct devlink *devlink, u32 id, devlink 229 drivers/net/ethernet/netronome/nfp/devlink_param.c struct devlink *devlink = priv_to_devlink(pf); devlink 236 drivers/net/ethernet/netronome/nfp/devlink_param.c err = devlink_params_register(devlink, nfp_devlink_params, devlink 241 drivers/net/ethernet/netronome/nfp/devlink_param.c devlink_params_publish(devlink); devlink 65 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_port_split(struct devlink *devlink, unsigned int port_index, devlink 68 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 102 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_port_unsplit(struct devlink *devlink, unsigned int port_index, devlink 105 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 136 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_sb_pool_get(struct devlink *devlink, unsigned int sb_index, devlink 139 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 145 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_sb_pool_set(struct devlink *devlink, unsigned int sb_index, devlink 150 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 156 drivers/net/ethernet/netronome/nfp/nfp_devlink.c static int nfp_devlink_eswitch_mode_get(struct devlink *devlink, u16 *mode) devlink 158 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 163 drivers/net/ethernet/netronome/nfp/nfp_devlink.c static int nfp_devlink_eswitch_mode_set(struct devlink *devlink, u16 mode, devlink 166 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 258 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req, devlink 261 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct nfp_pf *pf = devlink_priv(devlink); devlink 335 drivers/net/ethernet/netronome/nfp/nfp_devlink.c nfp_devlink_flash_update(struct devlink *devlink, const char *path, devlink 340 drivers/net/ethernet/netronome/nfp/nfp_devlink.c return nfp_flash_update_common(devlink_priv(devlink), path, extack); devlink 357 drivers/net/ethernet/netronome/nfp/nfp_devlink.c struct devlink *devlink; devlink 373 drivers/net/ethernet/netronome/nfp/nfp_devlink.c devlink = priv_to_devlink(app->pf); devlink 375 drivers/net/ethernet/netronome/nfp/nfp_devlink.c return devlink_port_register(devlink, &port->dl_port, port->eth_id); devlink 685 drivers/net/ethernet/netronome/nfp/nfp_main.c struct devlink *devlink; devlink 710 drivers/net/ethernet/netronome/nfp/nfp_main.c devlink = devlink_alloc(&nfp_devlink_ops, sizeof(*pf)); devlink 711 drivers/net/ethernet/netronome/nfp/nfp_main.c if (!devlink) { devlink 715 drivers/net/ethernet/netronome/nfp/nfp_main.c pf = devlink_priv(devlink); devlink 811 drivers/net/ethernet/netronome/nfp/nfp_main.c devlink_free(devlink); devlink 645 drivers/net/ethernet/netronome/nfp/nfp_net_main.c struct devlink *devlink = priv_to_devlink(pf); devlink 704 drivers/net/ethernet/netronome/nfp/nfp_net_main.c err = devlink_register(devlink, &pf->pdev->dev); devlink 754 drivers/net/ethernet/netronome/nfp/nfp_net_main.c devlink_unregister(devlink); devlink 80 drivers/net/ethernet/netronome/nfp/nfp_shared_buf.c struct devlink *devlink = priv_to_devlink(pf); devlink 115 drivers/net/ethernet/netronome/nfp/nfp_shared_buf.c err = devlink_sb_register(devlink, devlink 133 drivers/net/ethernet/netronome/nfp/nfp_shared_buf.c devlink_sb_unregister(devlink, devlink 143 drivers/net/ethernet/netronome/nfp/nfp_shared_buf.c struct devlink *devlink = priv_to_devlink(pf); devlink 147 drivers/net/ethernet/netronome/nfp/nfp_shared_buf.c devlink_sb_unregister(devlink, devlink 12 drivers/net/ethernet/pensando/ionic/ionic_devlink.c static int ionic_dl_info_get(struct devlink *dl, struct devlink_info_req *req, devlink 56 drivers/net/ethernet/pensando/ionic/ionic_devlink.c struct devlink *dl; devlink 65 drivers/net/ethernet/pensando/ionic/ionic_devlink.c struct devlink *dl = priv_to_devlink(ionic); devlink 72 drivers/net/ethernet/pensando/ionic/ionic_devlink.c struct devlink *dl = priv_to_devlink(ionic); devlink 95 drivers/net/ethernet/pensando/ionic/ionic_devlink.c struct devlink *dl = priv_to_devlink(ionic); devlink 867 drivers/net/ethernet/qlogic/qed/qed.h struct devlink *dl; devlink 358 drivers/net/ethernet/qlogic/qed/qed_main.c static int qed_dl_param_get(struct devlink *dl, u32 id, devlink 371 drivers/net/ethernet/qlogic/qed/qed_main.c static int qed_dl_param_set(struct devlink *dl, u32 id, devlink 397 drivers/net/ethernet/qlogic/qed/qed_main.c struct devlink *dl; devlink 126 drivers/net/netdevsim/dev.c static struct net *nsim_devlink_net(struct devlink *devlink) devlink 159 drivers/net/netdevsim/dev.c static int nsim_dev_resources_register(struct devlink *devlink) devlink 166 drivers/net/netdevsim/dev.c struct net *net = nsim_devlink_net(devlink); devlink 171 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "IPv4", (u64)-1, devlink 181 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "fib", n, devlink 190 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "fib-rules", n, devlink 199 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "IPv6", (u64)-1, devlink 209 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "fib", n, devlink 218 drivers/net/netdevsim/dev.c err = devlink_resource_register(devlink, "fib-rules", n, devlink 226 drivers/net/netdevsim/dev.c devlink_resource_occ_get_register(devlink, devlink 230 drivers/net/netdevsim/dev.c devlink_resource_occ_get_register(devlink, devlink 234 drivers/net/netdevsim/dev.c devlink_resource_occ_get_register(devlink, devlink 238 drivers/net/netdevsim/dev.c devlink_resource_occ_get_register(devlink, devlink 262 drivers/net/netdevsim/dev.c struct devlink *devlink) devlink 267 drivers/net/netdevsim/dev.c devlink_param_driverinit_value_set(devlink, devlink 271 drivers/net/netdevsim/dev.c devlink_param_driverinit_value_set(devlink, devlink 276 drivers/net/netdevsim/dev.c static void nsim_devlink_param_load_driverinit_values(struct devlink *devlink) devlink 278 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 282 drivers/net/netdevsim/dev.c err = devlink_param_driverinit_value_get(devlink, devlink 287 drivers/net/netdevsim/dev.c err = devlink_param_driverinit_value_get(devlink, devlink 297 drivers/net/netdevsim/dev.c struct devlink *devlink) devlink 300 drivers/net/netdevsim/dev.c devlink_region_create(devlink, "dummy", devlink 409 drivers/net/netdevsim/dev.c struct devlink *devlink = priv_to_devlink(nsim_dev); devlink 435 drivers/net/netdevsim/dev.c devlink_trap_report(devlink, skb, nsim_trap_item->trap_ctx, devlink 471 drivers/net/netdevsim/dev.c static int nsim_dev_traps_init(struct devlink *devlink) devlink 473 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 497 drivers/net/netdevsim/dev.c err = devlink_traps_register(devlink, nsim_traps_arr, devlink 516 drivers/net/netdevsim/dev.c static void nsim_dev_traps_exit(struct devlink *devlink) devlink 518 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 521 drivers/net/netdevsim/dev.c devlink_traps_unregister(devlink, nsim_traps_arr, devlink 527 drivers/net/netdevsim/dev.c static int nsim_dev_reload_down(struct devlink *devlink, devlink 533 drivers/net/netdevsim/dev.c static int nsim_dev_reload_up(struct devlink *devlink, devlink 540 drivers/net/netdevsim/dev.c struct net *net = nsim_devlink_net(devlink); devlink 547 drivers/net/netdevsim/dev.c err = devlink_resource_size_get(devlink, res_ids[i], &val); devlink 554 drivers/net/netdevsim/dev.c nsim_devlink_param_load_driverinit_values(devlink); devlink 563 drivers/net/netdevsim/dev.c static int nsim_dev_flash_update(struct devlink *devlink, const char *file_name, devlink 567 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 571 drivers/net/netdevsim/dev.c devlink_flash_update_begin_notify(devlink); devlink 572 drivers/net/netdevsim/dev.c devlink_flash_update_status_notify(devlink, devlink 579 drivers/net/netdevsim/dev.c devlink_flash_update_status_notify(devlink, "Flashing", devlink 587 drivers/net/netdevsim/dev.c devlink_flash_update_status_notify(devlink, "Flashing", devlink 591 drivers/net/netdevsim/dev.c devlink_flash_update_status_notify(devlink, "Flashing done", devlink 593 drivers/net/netdevsim/dev.c devlink_flash_update_end_notify(devlink); devlink 613 drivers/net/netdevsim/dev.c static int nsim_dev_devlink_trap_init(struct devlink *devlink, devlink 617 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 631 drivers/net/netdevsim/dev.c nsim_dev_devlink_trap_action_set(struct devlink *devlink, devlink 635 drivers/net/netdevsim/dev.c struct nsim_dev *nsim_dev = devlink_priv(devlink); devlink 664 drivers/net/netdevsim/dev.c struct devlink *devlink; devlink 667 drivers/net/netdevsim/dev.c devlink = devlink_alloc(&nsim_dev_devlink_ops, sizeof(*nsim_dev)); devlink 668 drivers/net/netdevsim/dev.c if (!devlink) devlink 670 drivers/net/netdevsim/dev.c nsim_dev = devlink_priv(devlink); devlink 680 drivers/net/netdevsim/dev.c err = nsim_dev_resources_register(devlink); devlink 684 drivers/net/netdevsim/dev.c err = devlink_register(devlink, &nsim_bus_dev->dev); devlink 688 drivers/net/netdevsim/dev.c err = devlink_params_register(devlink, nsim_devlink_params, devlink 692 drivers/net/netdevsim/dev.c nsim_devlink_set_params_init_values(nsim_dev, devlink); devlink 694 drivers/net/netdevsim/dev.c err = nsim_dev_dummy_region_init(nsim_dev, devlink); devlink 698 drivers/net/netdevsim/dev.c err = nsim_dev_traps_init(devlink); devlink 710 drivers/net/netdevsim/dev.c devlink_params_publish(devlink); devlink 711 drivers/net/netdevsim/dev.c devlink_reload_enable(devlink); devlink 717 drivers/net/netdevsim/dev.c nsim_dev_traps_exit(devlink); devlink 721 drivers/net/netdevsim/dev.c devlink_params_unregister(devlink, nsim_devlink_params, devlink 724 drivers/net/netdevsim/dev.c devlink_unregister(devlink); devlink 726 drivers/net/netdevsim/dev.c devlink_resources_unregister(devlink, NULL); devlink 728 drivers/net/netdevsim/dev.c devlink_free(devlink); devlink 734 drivers/net/netdevsim/dev.c struct devlink *devlink = priv_to_devlink(nsim_dev); devlink 736 drivers/net/netdevsim/dev.c devlink_reload_disable(devlink); devlink 739 drivers/net/netdevsim/dev.c nsim_dev_traps_exit(devlink); devlink 741 drivers/net/netdevsim/dev.c devlink_params_unregister(devlink, nsim_devlink_params, devlink 743 drivers/net/netdevsim/dev.c devlink_unregister(devlink); devlink 744 drivers/net/netdevsim/dev.c devlink_resources_unregister(devlink, NULL); devlink 746 drivers/net/netdevsim/dev.c devlink_free(devlink); devlink 927 include/linux/netdevice.h struct devlink; devlink 79 include/net/devlink.h struct devlink *devlink; devlink 377 include/net/devlink.h int (*get)(struct devlink *devlink, u32 id, devlink 379 include/net/devlink.h int (*set)(struct devlink *devlink, u32 id, devlink 381 include/net/devlink.h int (*validate)(struct devlink *devlink, u32 id, devlink 647 include/net/devlink.h int (*reload_down)(struct devlink *devlink, devlink 649 include/net/devlink.h int (*reload_up)(struct devlink *devlink, devlink 653 include/net/devlink.h int (*port_split)(struct devlink *devlink, unsigned int port_index, devlink 655 include/net/devlink.h int (*port_unsplit)(struct devlink *devlink, unsigned int port_index, devlink 657 include/net/devlink.h int (*sb_pool_get)(struct devlink *devlink, unsigned int sb_index, devlink 660 include/net/devlink.h int (*sb_pool_set)(struct devlink *devlink, unsigned int sb_index, devlink 681 include/net/devlink.h int (*sb_occ_snapshot)(struct devlink *devlink, devlink 683 include/net/devlink.h int (*sb_occ_max_clear)(struct devlink *devlink, devlink 694 include/net/devlink.h int (*eswitch_mode_get)(struct devlink *devlink, u16 *p_mode); devlink 695 include/net/devlink.h int (*eswitch_mode_set)(struct devlink *devlink, u16 mode, devlink 697 include/net/devlink.h int (*eswitch_inline_mode_get)(struct devlink *devlink, u8 *p_inline_mode); devlink 698 include/net/devlink.h int (*eswitch_inline_mode_set)(struct devlink *devlink, u8 inline_mode, devlink 700 include/net/devlink.h int (*eswitch_encap_mode_get)(struct devlink *devlink, devlink 702 include/net/devlink.h int (*eswitch_encap_mode_set)(struct devlink *devlink, devlink 705 include/net/devlink.h int (*info_get)(struct devlink *devlink, struct devlink_info_req *req, devlink 707 include/net/devlink.h int (*flash_update)(struct devlink *devlink, const char *file_name, devlink 718 include/net/devlink.h int (*trap_init)(struct devlink *devlink, devlink 726 include/net/devlink.h void (*trap_fini)(struct devlink *devlink, devlink 731 include/net/devlink.h int (*trap_action_set)(struct devlink *devlink, devlink 740 include/net/devlink.h int (*trap_group_init)(struct devlink *devlink, devlink 744 include/net/devlink.h static inline void *devlink_priv(struct devlink *devlink) devlink 746 include/net/devlink.h BUG_ON(!devlink); devlink 747 include/net/devlink.h return &devlink->priv; devlink 750 include/net/devlink.h static inline struct devlink *priv_to_devlink(void *priv) devlink 753 include/net/devlink.h return container_of(priv, struct devlink, priv); devlink 764 include/net/devlink.h static inline struct devlink *netdev_to_devlink(struct net_device *dev) devlink 769 include/net/devlink.h return devlink_port->devlink; devlink 775 include/net/devlink.h struct devlink *devlink_alloc(const struct devlink_ops *ops, size_t priv_size); devlink 776 include/net/devlink.h int devlink_register(struct devlink *devlink, struct device *dev); devlink 777 include/net/devlink.h void devlink_unregister(struct devlink *devlink); devlink 778 include/net/devlink.h void devlink_reload_enable(struct devlink *devlink); devlink 779 include/net/devlink.h void devlink_reload_disable(struct devlink *devlink); devlink 780 include/net/devlink.h void devlink_free(struct devlink *devlink); devlink 781 include/net/devlink.h int devlink_port_register(struct devlink *devlink, devlink 803 include/net/devlink.h int devlink_sb_register(struct devlink *devlink, unsigned int sb_index, devlink 807 include/net/devlink.h void devlink_sb_unregister(struct devlink *devlink, unsigned int sb_index); devlink 808 include/net/devlink.h int devlink_dpipe_table_register(struct devlink *devlink, devlink 812 include/net/devlink.h void devlink_dpipe_table_unregister(struct devlink *devlink, devlink 814 include/net/devlink.h int devlink_dpipe_headers_register(struct devlink *devlink, devlink 816 include/net/devlink.h void devlink_dpipe_headers_unregister(struct devlink *devlink); devlink 817 include/net/devlink.h bool devlink_dpipe_table_counter_enabled(struct devlink *devlink, devlink 832 include/net/devlink.h int devlink_resource_register(struct devlink *devlink, devlink 838 include/net/devlink.h void devlink_resources_unregister(struct devlink *devlink, devlink 840 include/net/devlink.h int devlink_resource_size_get(struct devlink *devlink, devlink 843 include/net/devlink.h int devlink_dpipe_table_resource_set(struct devlink *devlink, devlink 846 include/net/devlink.h void devlink_resource_occ_get_register(struct devlink *devlink, devlink 850 include/net/devlink.h void devlink_resource_occ_get_unregister(struct devlink *devlink, devlink 852 include/net/devlink.h int devlink_params_register(struct devlink *devlink, devlink 855 include/net/devlink.h void devlink_params_unregister(struct devlink *devlink, devlink 858 include/net/devlink.h void devlink_params_publish(struct devlink *devlink); devlink 859 include/net/devlink.h void devlink_params_unpublish(struct devlink *devlink); devlink 866 include/net/devlink.h int devlink_param_driverinit_value_get(struct devlink *devlink, u32 param_id, devlink 868 include/net/devlink.h int devlink_param_driverinit_value_set(struct devlink *devlink, u32 param_id, devlink 877 include/net/devlink.h void devlink_param_value_changed(struct devlink *devlink, u32 param_id); devlink 882 include/net/devlink.h struct devlink_region *devlink_region_create(struct devlink *devlink, devlink 887 include/net/devlink.h u32 devlink_region_shapshot_id_get(struct devlink *devlink); devlink 937 include/net/devlink.h devlink_health_reporter_create(struct devlink *devlink, devlink 952 include/net/devlink.h bool devlink_is_reload_failed(const struct devlink *devlink); devlink 954 include/net/devlink.h void devlink_flash_update_begin_notify(struct devlink *devlink); devlink 955 include/net/devlink.h void devlink_flash_update_end_notify(struct devlink *devlink); devlink 956 include/net/devlink.h void devlink_flash_update_status_notify(struct devlink *devlink, devlink 962 include/net/devlink.h int devlink_traps_register(struct devlink *devlink, devlink 965 include/net/devlink.h void devlink_traps_unregister(struct devlink *devlink, devlink 968 include/net/devlink.h void devlink_trap_report(struct devlink *devlink, devlink 263 include/net/dsa.h struct devlink *devlink; devlink 5 include/trace/events/devlink.h #define TRACE_SYSTEM devlink devlink 18 include/trace/events/devlink.h TP_PROTO(const struct devlink *devlink, bool incoming, devlink 21 include/trace/events/devlink.h TP_ARGS(devlink, incoming, type, buf, len), devlink 24 include/trace/events/devlink.h __string(bus_name, devlink->dev->bus->name) devlink 25 include/trace/events/devlink.h __string(dev_name, dev_name(devlink->dev)) devlink 26 include/trace/events/devlink.h __string(driver_name, devlink->dev->driver->name) devlink 34 include/trace/events/devlink.h __assign_str(bus_name, devlink->dev->bus->name); devlink 35 include/trace/events/devlink.h __assign_str(dev_name, dev_name(devlink->dev)); devlink 36 include/trace/events/devlink.h __assign_str(driver_name, devlink->dev->driver->name); devlink 53 include/trace/events/devlink.h TP_PROTO(const struct devlink *devlink, int err, const char *msg), devlink 55 include/trace/events/devlink.h TP_ARGS(devlink, err, msg), devlink 58 include/trace/events/devlink.h __string(bus_name, devlink->dev->bus->name) devlink 59 include/trace/events/devlink.h __string(dev_name, dev_name(devlink->dev)) devlink 60 include/trace/events/devlink.h __string(driver_name, devlink->dev->driver->name) devlink 66 include/trace/events/devlink.h __assign_str(bus_name, devlink->dev->bus->name); devlink 67 include/trace/events/devlink.h __assign_str(dev_name, dev_name(devlink->dev)); devlink 68 include/trace/events/devlink.h __assign_str(driver_name, devlink->dev->driver->name); devlink 82 include/trace/events/devlink.h TP_PROTO(const struct devlink *devlink, const char *reporter_name, devlink 85 include/trace/events/devlink.h TP_ARGS(devlink, reporter_name, msg), devlink 88 include/trace/events/devlink.h __string(bus_name, devlink->dev->bus->name) devlink 89 include/trace/events/devlink.h __string(dev_name, dev_name(devlink->dev)) devlink 90 include/trace/events/devlink.h __string(driver_name, devlink->dev->driver->name) devlink 96 include/trace/events/devlink.h __assign_str(bus_name, devlink->dev->bus->name); devlink 97 include/trace/events/devlink.h __assign_str(dev_name, dev_name(devlink->dev)); devlink 98 include/trace/events/devlink.h __assign_str(driver_name, devlink->dev->driver->name); devlink 113 include/trace/events/devlink.h TP_PROTO(const struct devlink *devlink, const char *reporter_name, devlink 116 include/trace/events/devlink.h TP_ARGS(devlink, reporter_name, health_state, time_since_last_recover), devlink 119 include/trace/events/devlink.h __string(bus_name, devlink->dev->bus->name) devlink 120 include/trace/events/devlink.h __string(dev_name, dev_name(devlink->dev)) devlink 121 include/trace/events/devlink.h __string(driver_name, devlink->dev->driver->name) devlink 128 include/trace/events/devlink.h __assign_str(bus_name, devlink->dev->bus->name); devlink 129 include/trace/events/devlink.h __assign_str(dev_name, dev_name(devlink->dev)); devlink 130 include/trace/events/devlink.h __assign_str(driver_name, devlink->dev->driver->name); devlink 147 include/trace/events/devlink.h TP_PROTO(const struct devlink *devlink, const char *reporter_name, devlink 150 include/trace/events/devlink.h TP_ARGS(devlink, reporter_name, new_state), devlink 153 include/trace/events/devlink.h __string(bus_name, devlink->dev->bus->name) devlink 154 include/trace/events/devlink.h __string(dev_name, dev_name(devlink->dev)) devlink 155 include/trace/events/devlink.h __string(driver_name, devlink->dev->driver->name) devlink 161 include/trace/events/devlink.h __assign_str(bus_name, devlink->dev->bus->name); devlink 162 include/trace/events/devlink.h __assign_str(dev_name, dev_name(devlink->dev)); devlink 163 include/trace/events/devlink.h __assign_str(driver_name, devlink->dev->driver->name); devlink 186 include/trace/events/devlink.h static inline void trace_devlink_hwmsg(const struct devlink *devlink, devlink 192 include/trace/events/devlink.h static inline void trace_devlink_hwerr(const struct devlink *devlink, devlink 98 net/core/devlink.c static struct net *devlink_net(const struct devlink *devlink) devlink 100 net/core/devlink.c return read_pnet(&devlink->_net); devlink 103 net/core/devlink.c static void devlink_net_set(struct devlink *devlink, struct net *net) devlink 105 net/core/devlink.c write_pnet(&devlink->_net, net); devlink 108 net/core/devlink.c static struct devlink *devlink_get_from_attrs(struct net *net, devlink 111 net/core/devlink.c struct devlink *devlink; devlink 123 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 124 net/core/devlink.c if (strcmp(devlink->dev->bus->name, busname) == 0 && devlink 125 net/core/devlink.c strcmp(dev_name(devlink->dev), devname) == 0 && devlink 126 net/core/devlink.c net_eq(devlink_net(devlink), net)) devlink 127 net/core/devlink.c return devlink; devlink 133 net/core/devlink.c static struct devlink *devlink_get_from_info(struct genl_info *info) devlink 138 net/core/devlink.c static struct devlink_port *devlink_port_get_by_index(struct devlink *devlink, devlink 143 net/core/devlink.c list_for_each_entry(devlink_port, &devlink->port_list, list) { devlink 150 net/core/devlink.c static bool devlink_port_index_exists(struct devlink *devlink, devlink 153 net/core/devlink.c return devlink_port_get_by_index(devlink, port_index); devlink 156 net/core/devlink.c static struct devlink_port *devlink_port_get_from_attrs(struct devlink *devlink, devlink 163 net/core/devlink.c devlink_port = devlink_port_get_by_index(devlink, port_index); devlink 171 net/core/devlink.c static struct devlink_port *devlink_port_get_from_info(struct devlink *devlink, devlink 174 net/core/devlink.c return devlink_port_get_from_attrs(devlink, info->attrs); devlink 192 net/core/devlink.c static struct devlink_sb *devlink_sb_get_by_index(struct devlink *devlink, devlink 197 net/core/devlink.c list_for_each_entry(devlink_sb, &devlink->sb_list, list) { devlink 204 net/core/devlink.c static bool devlink_sb_index_exists(struct devlink *devlink, devlink 207 net/core/devlink.c return devlink_sb_get_by_index(devlink, sb_index); devlink 210 net/core/devlink.c static struct devlink_sb *devlink_sb_get_from_attrs(struct devlink *devlink, devlink 217 net/core/devlink.c devlink_sb = devlink_sb_get_by_index(devlink, sb_index); devlink 225 net/core/devlink.c static struct devlink_sb *devlink_sb_get_from_info(struct devlink *devlink, devlink 228 net/core/devlink.c return devlink_sb_get_from_attrs(devlink, info->attrs); devlink 336 net/core/devlink.c struct devlink *devlink; devlink 354 net/core/devlink.c devlink_region_get_by_name(struct devlink *devlink, const char *region_name) devlink 358 net/core/devlink.c list_for_each_entry(region, &devlink->region_list, list) devlink 390 net/core/devlink.c struct devlink *devlink; devlink 394 net/core/devlink.c devlink = devlink_get_from_info(info); devlink 395 net/core/devlink.c if (IS_ERR(devlink)) { devlink 397 net/core/devlink.c return PTR_ERR(devlink); devlink 400 net/core/devlink.c mutex_lock(&devlink->lock); devlink 402 net/core/devlink.c info->user_ptr[0] = devlink; devlink 406 net/core/devlink.c devlink_port = devlink_port_get_from_info(devlink, info); devlink 416 net/core/devlink.c devlink_sb = devlink_sb_get_from_info(devlink, info); devlink 427 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 435 net/core/devlink.c struct devlink *devlink; devlink 437 net/core/devlink.c devlink = devlink_get_from_info(info); devlink 439 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 453 net/core/devlink.c static int devlink_nl_put_handle(struct sk_buff *msg, struct devlink *devlink) devlink 455 net/core/devlink.c if (nla_put_string(msg, DEVLINK_ATTR_BUS_NAME, devlink->dev->bus->name)) devlink 457 net/core/devlink.c if (nla_put_string(msg, DEVLINK_ATTR_DEV_NAME, dev_name(devlink->dev))) devlink 462 net/core/devlink.c static int devlink_nl_fill(struct sk_buff *msg, struct devlink *devlink, devlink 472 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 474 net/core/devlink.c if (nla_put_u8(msg, DEVLINK_ATTR_RELOAD_FAILED, devlink->reload_failed)) devlink 485 net/core/devlink.c static void devlink_notify(struct devlink *devlink, enum devlink_command cmd) devlink 496 net/core/devlink.c err = devlink_nl_fill(msg, devlink, cmd, 0, 0, 0); devlink 502 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 549 net/core/devlink.c static int devlink_nl_port_fill(struct sk_buff *msg, struct devlink *devlink, devlink 560 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 607 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 620 net/core/devlink.c err = devlink_nl_port_fill(msg, devlink, devlink_port, cmd, 0, 0, 0); devlink 626 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 632 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 640 net/core/devlink.c err = devlink_nl_fill(msg, devlink, DEVLINK_CMD_NEW, devlink 653 net/core/devlink.c struct devlink *devlink; devlink 659 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 660 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 666 net/core/devlink.c err = devlink_nl_fill(msg, devlink, DEVLINK_CMD_NEW, devlink 684 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 692 net/core/devlink.c err = devlink_nl_port_fill(msg, devlink, devlink_port, devlink 706 net/core/devlink.c struct devlink *devlink; devlink 713 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 714 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 716 net/core/devlink.c mutex_lock(&devlink->lock); devlink 717 net/core/devlink.c list_for_each_entry(devlink_port, &devlink->port_list, list) { devlink 722 net/core/devlink.c err = devlink_nl_port_fill(msg, devlink, devlink_port, devlink 728 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 733 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 742 net/core/devlink.c static int devlink_port_type_set(struct devlink *devlink, devlink 749 net/core/devlink.c if (devlink->ops->port_type_set) { devlink 754 net/core/devlink.c err = devlink->ops->port_type_set(devlink_port, port_type); devlink 768 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 775 net/core/devlink.c err = devlink_port_type_set(devlink, devlink_port, port_type); devlink 782 net/core/devlink.c static int devlink_port_split(struct devlink *devlink, u32 port_index, devlink 786 net/core/devlink.c if (devlink->ops->port_split) devlink 787 net/core/devlink.c return devlink->ops->port_split(devlink, port_index, count, devlink 795 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 805 net/core/devlink.c return devlink_port_split(devlink, port_index, count, info->extack); devlink 808 net/core/devlink.c static int devlink_port_unsplit(struct devlink *devlink, u32 port_index, devlink 812 net/core/devlink.c if (devlink->ops->port_unsplit) devlink 813 net/core/devlink.c return devlink->ops->port_unsplit(devlink, port_index, extack); devlink 820 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 827 net/core/devlink.c return devlink_port_unsplit(devlink, port_index, info->extack); devlink 830 net/core/devlink.c static int devlink_nl_sb_fill(struct sk_buff *msg, struct devlink *devlink, devlink 841 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 871 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 880 net/core/devlink.c err = devlink_nl_sb_fill(msg, devlink, devlink_sb, devlink 894 net/core/devlink.c struct devlink *devlink; devlink 901 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 902 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 904 net/core/devlink.c mutex_lock(&devlink->lock); devlink 905 net/core/devlink.c list_for_each_entry(devlink_sb, &devlink->sb_list, list) { devlink 910 net/core/devlink.c err = devlink_nl_sb_fill(msg, devlink, devlink_sb, devlink 916 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 921 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 930 net/core/devlink.c static int devlink_nl_sb_pool_fill(struct sk_buff *msg, struct devlink *devlink, devlink 939 net/core/devlink.c err = devlink->ops->sb_pool_get(devlink, devlink_sb->index, devlink 948 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 976 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 987 net/core/devlink.c if (!devlink->ops->sb_pool_get) devlink 994 net/core/devlink.c err = devlink_nl_sb_pool_fill(msg, devlink, devlink_sb, pool_index, devlink 1006 net/core/devlink.c struct devlink *devlink, devlink 1019 net/core/devlink.c err = devlink_nl_sb_pool_fill(msg, devlink, devlink 1034 net/core/devlink.c struct devlink *devlink; devlink 1041 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 1042 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk)) || devlink 1043 net/core/devlink.c !devlink->ops->sb_pool_get) devlink 1045 net/core/devlink.c mutex_lock(&devlink->lock); devlink 1046 net/core/devlink.c list_for_each_entry(devlink_sb, &devlink->sb_list, list) { devlink 1047 net/core/devlink.c err = __sb_pool_get_dumpit(msg, start, &idx, devlink, devlink 1052 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1056 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1065 net/core/devlink.c static int devlink_sb_pool_set(struct devlink *devlink, unsigned int sb_index, devlink 1071 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1074 net/core/devlink.c return ops->sb_pool_set(devlink, sb_index, pool_index, devlink 1082 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1102 net/core/devlink.c return devlink_sb_pool_set(devlink, devlink_sb->index, devlink 1108 net/core/devlink.c struct devlink *devlink, devlink 1115 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1129 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 1168 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 1179 net/core/devlink.c if (!devlink->ops->sb_port_pool_get) devlink 1186 net/core/devlink.c err = devlink_nl_sb_port_pool_fill(msg, devlink, devlink_port, devlink 1199 net/core/devlink.c struct devlink *devlink, devlink 1208 net/core/devlink.c list_for_each_entry(devlink_port, &devlink->port_list, list) { devlink 1214 net/core/devlink.c err = devlink_nl_sb_port_pool_fill(msg, devlink, devlink 1232 net/core/devlink.c struct devlink *devlink; devlink 1239 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 1240 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk)) || devlink 1241 net/core/devlink.c !devlink->ops->sb_port_pool_get) devlink 1243 net/core/devlink.c mutex_lock(&devlink->lock); devlink 1244 net/core/devlink.c list_for_each_entry(devlink_sb, &devlink->sb_list, list) { devlink 1246 net/core/devlink.c devlink, devlink_sb, devlink 1250 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1254 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1269 net/core/devlink.c const struct devlink_ops *ops = devlink_port->devlink->ops; devlink 1300 net/core/devlink.c devlink_nl_sb_tc_pool_bind_fill(struct sk_buff *msg, struct devlink *devlink, devlink 1307 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1323 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 1368 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 1384 net/core/devlink.c if (!devlink->ops->sb_tc_pool_bind_get) devlink 1391 net/core/devlink.c err = devlink_nl_sb_tc_pool_bind_fill(msg, devlink, devlink_port, devlink 1406 net/core/devlink.c struct devlink *devlink, devlink 1414 net/core/devlink.c list_for_each_entry(devlink_port, &devlink->port_list, list) { devlink 1421 net/core/devlink.c err = devlink_nl_sb_tc_pool_bind_fill(msg, devlink, devlink 1439 net/core/devlink.c err = devlink_nl_sb_tc_pool_bind_fill(msg, devlink, devlink 1459 net/core/devlink.c struct devlink *devlink; devlink 1466 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 1467 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk)) || devlink 1468 net/core/devlink.c !devlink->ops->sb_tc_pool_bind_get) devlink 1471 net/core/devlink.c mutex_lock(&devlink->lock); devlink 1472 net/core/devlink.c list_for_each_entry(devlink_sb, &devlink->sb_list, list) { devlink 1474 net/core/devlink.c devlink, devlink 1479 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1483 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 1499 net/core/devlink.c const struct devlink_ops *ops = devlink_port->devlink->ops; devlink 1545 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1547 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1550 net/core/devlink.c return ops->sb_occ_snapshot(devlink, devlink_sb->index); devlink 1557 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1559 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1562 net/core/devlink.c return ops->sb_occ_max_clear(devlink, devlink_sb->index); devlink 1566 net/core/devlink.c static int devlink_nl_eswitch_fill(struct sk_buff *msg, struct devlink *devlink, devlink 1570 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1581 net/core/devlink.c err = devlink_nl_put_handle(msg, devlink); devlink 1586 net/core/devlink.c err = ops->eswitch_mode_get(devlink, &mode); devlink 1595 net/core/devlink.c err = ops->eswitch_inline_mode_get(devlink, &inline_mode); devlink 1605 net/core/devlink.c err = ops->eswitch_encap_mode_get(devlink, &encap_mode); devlink 1624 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1632 net/core/devlink.c err = devlink_nl_eswitch_fill(msg, devlink, DEVLINK_CMD_ESWITCH_GET, devlink 1646 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1647 net/core/devlink.c const struct devlink_ops *ops = devlink->ops; devlink 1657 net/core/devlink.c err = ops->eswitch_mode_set(devlink, mode, info->extack); devlink 1667 net/core/devlink.c err = ops->eswitch_inline_mode_set(devlink, inline_mode, devlink 1677 net/core/devlink.c err = ops->eswitch_encap_mode_set(devlink, encap_mode, devlink 1843 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1867 net/core/devlink.c if (devlink_nl_put_handle(skb, devlink)) devlink 1921 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 1928 net/core/devlink.c &devlink->dpipe_table_list, devlink 2093 net/core/devlink.c struct devlink *devlink; devlink 2109 net/core/devlink.c devlink = dump_ctx->info->user_ptr[0]; devlink 2110 net/core/devlink.c if (devlink_nl_put_handle(dump_ctx->skb, devlink)) devlink 2194 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2202 net/core/devlink.c table = devlink_dpipe_table_find(&devlink->dpipe_table_list, devlink 2281 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2302 net/core/devlink.c if (devlink_nl_put_handle(skb, devlink)) devlink 2344 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2346 net/core/devlink.c if (!devlink->dpipe_headers) devlink 2349 net/core/devlink.c 0, devlink->dpipe_headers); devlink 2352 net/core/devlink.c static int devlink_dpipe_table_counters_set(struct devlink *devlink, devlink 2358 net/core/devlink.c table = devlink_dpipe_table_find(&devlink->dpipe_table_list, devlink 2378 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2389 net/core/devlink.c return devlink_dpipe_table_counters_set(devlink, table_name, devlink 2394 net/core/devlink.c devlink_resource_find(struct devlink *devlink, devlink 2402 net/core/devlink.c resource_list = &devlink->resource_list; devlink 2410 net/core/devlink.c child_resource = devlink_resource_find(devlink, resource, devlink 2466 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2477 net/core/devlink.c resource = devlink_resource_find(devlink, NULL, resource_id); devlink 2521 net/core/devlink.c static int devlink_resource_put(struct devlink *devlink, struct sk_buff *skb, devlink 2558 net/core/devlink.c if (devlink_resource_put(devlink, skb, child_resource)) devlink 2577 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2587 net/core/devlink.c resource = list_first_entry(&devlink->resource_list, devlink 2601 net/core/devlink.c if (devlink_nl_put_handle(skb, devlink)) devlink 2611 net/core/devlink.c list_for_each_entry_from(resource, &devlink->resource_list, list) { devlink 2612 net/core/devlink.c err = devlink_resource_put(devlink, skb, resource); devlink 2646 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2648 net/core/devlink.c if (list_empty(&devlink->resource_list)) devlink 2655 net/core/devlink.c devlink_resources_validate(struct devlink *devlink, devlink 2665 net/core/devlink.c resource_list = &devlink->resource_list; devlink 2670 net/core/devlink.c err = devlink_resources_validate(devlink, resource, info); devlink 2677 net/core/devlink.c static bool devlink_reload_supported(struct devlink *devlink) devlink 2679 net/core/devlink.c return devlink->ops->reload_down && devlink->ops->reload_up; devlink 2682 net/core/devlink.c static void devlink_reload_failed_set(struct devlink *devlink, devlink 2685 net/core/devlink.c if (devlink->reload_failed == reload_failed) devlink 2687 net/core/devlink.c devlink->reload_failed = reload_failed; devlink 2688 net/core/devlink.c devlink_notify(devlink, DEVLINK_CMD_NEW); devlink 2691 net/core/devlink.c bool devlink_is_reload_failed(const struct devlink *devlink) devlink 2693 net/core/devlink.c return devlink->reload_failed; devlink 2699 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2702 net/core/devlink.c if (!devlink_reload_supported(devlink) || !devlink->reload_enabled) devlink 2705 net/core/devlink.c err = devlink_resources_validate(devlink, NULL, info); devlink 2710 net/core/devlink.c err = devlink->ops->reload_down(devlink, info->extack); devlink 2713 net/core/devlink.c err = devlink->ops->reload_up(devlink, info->extack); devlink 2714 net/core/devlink.c devlink_reload_failed_set(devlink, !!err); devlink 2719 net/core/devlink.c struct devlink *devlink, devlink 2731 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 2761 net/core/devlink.c static void __devlink_flash_update_notify(struct devlink *devlink, devlink 2779 net/core/devlink.c err = devlink_nl_flash_update_fill(msg, devlink, cmd, status_msg, devlink 2784 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 2792 net/core/devlink.c void devlink_flash_update_begin_notify(struct devlink *devlink) devlink 2794 net/core/devlink.c __devlink_flash_update_notify(devlink, devlink 2800 net/core/devlink.c void devlink_flash_update_end_notify(struct devlink *devlink) devlink 2802 net/core/devlink.c __devlink_flash_update_notify(devlink, devlink 2808 net/core/devlink.c void devlink_flash_update_status_notify(struct devlink *devlink, devlink 2814 net/core/devlink.c __devlink_flash_update_notify(devlink, devlink 2823 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 2827 net/core/devlink.c if (!devlink->ops->flash_update) devlink 2837 net/core/devlink.c return devlink->ops->flash_update(devlink, file_name, component, devlink 2946 net/core/devlink.c static int devlink_param_get(struct devlink *devlink, devlink 2952 net/core/devlink.c return param->get(devlink, param->id, ctx); devlink 2955 net/core/devlink.c static int devlink_param_set(struct devlink *devlink, devlink 2961 net/core/devlink.c return param->set(devlink, param->id, ctx); devlink 3033 net/core/devlink.c static int devlink_nl_param_fill(struct sk_buff *msg, struct devlink *devlink, devlink 3062 net/core/devlink.c err = devlink_param_get(devlink, param, &ctx); devlink 3074 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 3125 net/core/devlink.c static void devlink_param_notify(struct devlink *devlink, devlink 3140 net/core/devlink.c err = devlink_nl_param_fill(msg, devlink, port_index, param_item, cmd, devlink 3147 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 3155 net/core/devlink.c struct devlink *devlink; devlink 3161 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 3162 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 3164 net/core/devlink.c mutex_lock(&devlink->lock); devlink 3165 net/core/devlink.c list_for_each_entry(param_item, &devlink->param_list, list) { devlink 3170 net/core/devlink.c err = devlink_nl_param_fill(msg, devlink, 0, param_item, devlink 3176 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3181 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3281 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 3286 net/core/devlink.c param_item = devlink_param_get_from_info(&devlink->param_list, info); devlink 3294 net/core/devlink.c err = devlink_nl_param_fill(msg, devlink, 0, param_item, devlink 3305 net/core/devlink.c static int __devlink_nl_cmd_param_set_doit(struct devlink *devlink, devlink 3332 net/core/devlink.c err = param->validate(devlink, param->id, value, info->extack); devlink 3354 net/core/devlink.c err = devlink_param_set(devlink, param, &ctx); devlink 3359 net/core/devlink.c devlink_param_notify(devlink, port_index, param_item, cmd); devlink 3366 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 3368 net/core/devlink.c return __devlink_nl_cmd_param_set_doit(devlink, 0, &devlink->param_list, devlink 3372 net/core/devlink.c static int devlink_param_register_one(struct devlink *devlink, devlink 3394 net/core/devlink.c devlink_param_notify(devlink, port_index, param_item, cmd); devlink 3398 net/core/devlink.c static void devlink_param_unregister_one(struct devlink *devlink, devlink 3408 net/core/devlink.c devlink_param_notify(devlink, port_index, param_item, cmd); devlink 3418 net/core/devlink.c struct devlink *devlink; devlink 3424 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 3425 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 3427 net/core/devlink.c mutex_lock(&devlink->lock); devlink 3428 net/core/devlink.c list_for_each_entry(devlink_port, &devlink->port_list, list) { devlink 3436 net/core/devlink.c devlink_port->devlink, devlink 3443 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3449 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3475 net/core/devlink.c err = devlink_nl_param_fill(msg, devlink_port->devlink, devlink 3492 net/core/devlink.c return __devlink_nl_cmd_param_set_doit(devlink_port->devlink, devlink 3499 net/core/devlink.c struct devlink *devlink, devlink 3522 net/core/devlink.c struct devlink *devlink, devlink 3535 net/core/devlink.c err = devlink_nl_region_snapshot_id_put(msg, devlink, snapshot); devlink 3548 net/core/devlink.c static int devlink_nl_region_fill(struct sk_buff *msg, struct devlink *devlink, devlink 3560 net/core/devlink.c err = devlink_nl_put_handle(msg, devlink); devlink 3574 net/core/devlink.c err = devlink_nl_region_snapshots_id_put(msg, devlink, region); devlink 3590 net/core/devlink.c struct devlink *devlink = region->devlink; devlink 3605 net/core/devlink.c err = devlink_nl_put_handle(msg, devlink); devlink 3627 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 3651 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 3661 net/core/devlink.c region = devlink_region_get_by_name(devlink, region_name); devlink 3669 net/core/devlink.c err = devlink_nl_region_fill(msg, devlink, DEVLINK_CMD_REGION_GET, devlink 3684 net/core/devlink.c struct devlink *devlink; devlink 3690 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 3691 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 3694 net/core/devlink.c mutex_lock(&devlink->lock); devlink 3695 net/core/devlink.c list_for_each_entry(region, &devlink->region_list, list) { devlink 3700 net/core/devlink.c err = devlink_nl_region_fill(msg, devlink, devlink 3706 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3711 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3722 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 3735 net/core/devlink.c region = devlink_region_get_by_name(devlink, region_name); devlink 3748 net/core/devlink.c struct devlink *devlink, devlink 3779 net/core/devlink.c struct devlink *devlink, devlink 3812 net/core/devlink.c err = devlink_nl_cmd_region_read_chunk_fill(skb, devlink, devlink 3832 net/core/devlink.c struct devlink *devlink; devlink 3852 net/core/devlink.c devlink = devlink_get_from_attrs(sock_net(cb->skb->sk), attrs); devlink 3853 net/core/devlink.c if (IS_ERR(devlink)) { devlink 3854 net/core/devlink.c err = PTR_ERR(devlink); devlink 3858 net/core/devlink.c mutex_lock(&devlink->lock); devlink 3867 net/core/devlink.c region = devlink_region_get_by_name(devlink, region_name); devlink 3887 net/core/devlink.c err = devlink_nl_put_handle(skb, devlink); devlink 3917 net/core/devlink.c err = devlink_nl_region_read_snapshot_fill(skb, devlink, devlink 3936 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 3945 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 4027 net/core/devlink.c devlink_nl_info_fill(struct sk_buff *msg, struct devlink *devlink, devlink 4040 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 4044 net/core/devlink.c err = devlink->ops->info_get(devlink, &req, extack); devlink 4059 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 4063 net/core/devlink.c if (!devlink->ops->info_get) devlink 4070 net/core/devlink.c err = devlink_nl_info_fill(msg, devlink, DEVLINK_CMD_INFO_GET, devlink 4084 net/core/devlink.c struct devlink *devlink; devlink 4090 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 4091 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 4098 net/core/devlink.c if (!devlink->ops->info_get) { devlink 4103 net/core/devlink.c mutex_lock(&devlink->lock); devlink 4104 net/core/devlink.c err = devlink_nl_info_fill(msg, devlink, DEVLINK_CMD_INFO_GET, devlink 4108 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 4632 net/core/devlink.c struct devlink *devlink; devlink 4654 net/core/devlink.c devlink_health_reporter_find_by_name(struct devlink *devlink, devlink 4659 net/core/devlink.c lockdep_assert_held(&devlink->reporters_lock); devlink 4660 net/core/devlink.c list_for_each_entry(reporter, &devlink->reporter_list, list) devlink 4676 net/core/devlink.c devlink_health_reporter_create(struct devlink *devlink, devlink 4683 net/core/devlink.c mutex_lock(&devlink->reporters_lock); devlink 4684 net/core/devlink.c if (devlink_health_reporter_find_by_name(devlink, ops->name)) { devlink 4703 net/core/devlink.c reporter->devlink = devlink; devlink 4708 net/core/devlink.c list_add_tail(&reporter->list, &devlink->reporter_list); devlink 4710 net/core/devlink.c mutex_unlock(&devlink->reporters_lock); devlink 4723 net/core/devlink.c mutex_lock(&reporter->devlink->reporters_lock); devlink 4725 net/core/devlink.c mutex_unlock(&reporter->devlink->reporters_lock); devlink 4747 net/core/devlink.c trace_devlink_health_reporter_state_update(reporter->devlink, devlink 4825 net/core/devlink.c struct devlink *devlink = reporter->devlink; devlink 4829 net/core/devlink.c trace_devlink_health_report(devlink, reporter->ops->name, msg); devlink 4839 net/core/devlink.c trace_devlink_health_recover_aborted(devlink, devlink 4862 net/core/devlink.c devlink_health_reporter_get_from_attrs(struct devlink *devlink, devlink 4872 net/core/devlink.c mutex_lock(&devlink->reporters_lock); devlink 4873 net/core/devlink.c reporter = devlink_health_reporter_find_by_name(devlink, reporter_name); devlink 4876 net/core/devlink.c mutex_unlock(&devlink->reporters_lock); devlink 4881 net/core/devlink.c devlink_health_reporter_get_from_info(struct devlink *devlink, devlink 4884 net/core/devlink.c return devlink_health_reporter_get_from_attrs(devlink, info->attrs); devlink 4891 net/core/devlink.c struct devlink *devlink; devlink 4907 net/core/devlink.c devlink = devlink_get_from_attrs(sock_net(cb->skb->sk), attrs); devlink 4908 net/core/devlink.c if (IS_ERR(devlink)) devlink 4911 net/core/devlink.c reporter = devlink_health_reporter_get_from_attrs(devlink, attrs); devlink 4930 net/core/devlink.c struct devlink *devlink, devlink 4942 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 4994 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 4999 net/core/devlink.c reporter = devlink_health_reporter_get_from_info(devlink, info); devlink 5009 net/core/devlink.c err = devlink_nl_health_reporter_fill(msg, devlink, reporter, devlink 5029 net/core/devlink.c struct devlink *devlink; devlink 5035 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 5036 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 5038 net/core/devlink.c mutex_lock(&devlink->reporters_lock); devlink 5039 net/core/devlink.c list_for_each_entry(reporter, &devlink->reporter_list, devlink 5045 net/core/devlink.c err = devlink_nl_health_reporter_fill(msg, devlink, devlink 5052 net/core/devlink.c mutex_unlock(&devlink->reporters_lock); devlink 5057 net/core/devlink.c mutex_unlock(&devlink->reporters_lock); devlink 5070 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5074 net/core/devlink.c reporter = devlink_health_reporter_get_from_info(devlink, info); devlink 5103 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5107 net/core/devlink.c reporter = devlink_health_reporter_get_from_info(devlink, info); devlink 5120 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5125 net/core/devlink.c reporter = devlink_health_reporter_get_from_info(devlink, info); devlink 5203 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5206 net/core/devlink.c reporter = devlink_health_reporter_get_from_info(devlink, info); devlink 5267 net/core/devlink.c devlink_trap_item_lookup(struct devlink *devlink, const char *name) devlink 5271 net/core/devlink.c list_for_each_entry(trap_item, &devlink->trap_list, list) { devlink 5280 net/core/devlink.c devlink_trap_item_get_from_info(struct devlink *devlink, devlink 5289 net/core/devlink.c return devlink_trap_item_lookup(devlink, nla_data(attr)); devlink 5385 net/core/devlink.c static int devlink_nl_trap_fill(struct sk_buff *msg, struct devlink *devlink, devlink 5398 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 5439 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5444 net/core/devlink.c if (list_empty(&devlink->trap_list)) devlink 5447 net/core/devlink.c trap_item = devlink_trap_item_get_from_info(devlink, info); devlink 5457 net/core/devlink.c err = devlink_nl_trap_fill(msg, devlink, trap_item, devlink 5474 net/core/devlink.c struct devlink *devlink; devlink 5480 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 5481 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 5483 net/core/devlink.c mutex_lock(&devlink->lock); devlink 5484 net/core/devlink.c list_for_each_entry(trap_item, &devlink->trap_list, list) { devlink 5489 net/core/devlink.c err = devlink_nl_trap_fill(msg, devlink, trap_item, devlink 5495 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 5500 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 5509 net/core/devlink.c static int __devlink_trap_action_set(struct devlink *devlink, devlink 5522 net/core/devlink.c err = devlink->ops->trap_action_set(devlink, trap_item->trap, devlink 5532 net/core/devlink.c static int devlink_trap_action_set(struct devlink *devlink, devlink 5548 net/core/devlink.c return __devlink_trap_action_set(devlink, trap_item, trap_action, devlink 5556 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5560 net/core/devlink.c if (list_empty(&devlink->trap_list)) devlink 5563 net/core/devlink.c trap_item = devlink_trap_item_get_from_info(devlink, info); devlink 5569 net/core/devlink.c err = devlink_trap_action_set(devlink, trap_item, info); devlink 5577 net/core/devlink.c devlink_trap_group_item_lookup(struct devlink *devlink, const char *name) devlink 5581 net/core/devlink.c list_for_each_entry(group_item, &devlink->trap_group_list, list) { devlink 5590 net/core/devlink.c devlink_trap_group_item_get_from_info(struct devlink *devlink, devlink 5599 net/core/devlink.c return devlink_trap_group_item_lookup(devlink, name); devlink 5603 net/core/devlink.c devlink_nl_trap_group_fill(struct sk_buff *msg, struct devlink *devlink, devlink 5615 net/core/devlink.c if (devlink_nl_put_handle(msg, devlink)) devlink 5643 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5648 net/core/devlink.c if (list_empty(&devlink->trap_group_list)) devlink 5651 net/core/devlink.c group_item = devlink_trap_group_item_get_from_info(devlink, info); devlink 5661 net/core/devlink.c err = devlink_nl_trap_group_fill(msg, devlink, group_item, devlink 5680 net/core/devlink.c struct devlink *devlink; devlink 5686 net/core/devlink.c list_for_each_entry(devlink, &devlink_list, list) { devlink 5687 net/core/devlink.c if (!net_eq(devlink_net(devlink), sock_net(msg->sk))) devlink 5689 net/core/devlink.c mutex_lock(&devlink->lock); devlink 5690 net/core/devlink.c list_for_each_entry(group_item, &devlink->trap_group_list, devlink 5696 net/core/devlink.c err = devlink_nl_trap_group_fill(msg, devlink, devlink 5702 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 5707 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 5717 net/core/devlink.c __devlink_trap_group_action_set(struct devlink *devlink, devlink 5726 net/core/devlink.c list_for_each_entry(trap_item, &devlink->trap_list, list) { devlink 5729 net/core/devlink.c err = __devlink_trap_action_set(devlink, trap_item, devlink 5739 net/core/devlink.c devlink_trap_group_action_set(struct devlink *devlink, devlink 5755 net/core/devlink.c err = __devlink_trap_group_action_set(devlink, group_item, trap_action, devlink 5767 net/core/devlink.c struct devlink *devlink = info->user_ptr[0]; devlink 5771 net/core/devlink.c if (list_empty(&devlink->trap_group_list)) devlink 5774 net/core/devlink.c group_item = devlink_trap_group_item_get_from_info(devlink, info); devlink 5780 net/core/devlink.c err = devlink_trap_group_action_set(devlink, group_item, info); devlink 6173 net/core/devlink.c struct devlink *devlink_alloc(const struct devlink_ops *ops, size_t priv_size) devlink 6175 net/core/devlink.c struct devlink *devlink; devlink 6180 net/core/devlink.c devlink = kzalloc(sizeof(*devlink) + priv_size, GFP_KERNEL); devlink 6181 net/core/devlink.c if (!devlink) devlink 6183 net/core/devlink.c devlink->ops = ops; devlink 6184 net/core/devlink.c devlink_net_set(devlink, &init_net); devlink 6185 net/core/devlink.c INIT_LIST_HEAD(&devlink->port_list); devlink 6186 net/core/devlink.c INIT_LIST_HEAD(&devlink->sb_list); devlink 6187 net/core/devlink.c INIT_LIST_HEAD_RCU(&devlink->dpipe_table_list); devlink 6188 net/core/devlink.c INIT_LIST_HEAD(&devlink->resource_list); devlink 6189 net/core/devlink.c INIT_LIST_HEAD(&devlink->param_list); devlink 6190 net/core/devlink.c INIT_LIST_HEAD(&devlink->region_list); devlink 6191 net/core/devlink.c INIT_LIST_HEAD(&devlink->reporter_list); devlink 6192 net/core/devlink.c INIT_LIST_HEAD(&devlink->trap_list); devlink 6193 net/core/devlink.c INIT_LIST_HEAD(&devlink->trap_group_list); devlink 6194 net/core/devlink.c mutex_init(&devlink->lock); devlink 6195 net/core/devlink.c mutex_init(&devlink->reporters_lock); devlink 6196 net/core/devlink.c return devlink; devlink 6206 net/core/devlink.c int devlink_register(struct devlink *devlink, struct device *dev) devlink 6209 net/core/devlink.c devlink->dev = dev; devlink 6210 net/core/devlink.c list_add_tail(&devlink->list, &devlink_list); devlink 6211 net/core/devlink.c devlink_notify(devlink, DEVLINK_CMD_NEW); devlink 6222 net/core/devlink.c void devlink_unregister(struct devlink *devlink) devlink 6225 net/core/devlink.c WARN_ON(devlink_reload_supported(devlink) && devlink 6226 net/core/devlink.c devlink->reload_enabled); devlink 6227 net/core/devlink.c devlink_notify(devlink, DEVLINK_CMD_DEL); devlink 6228 net/core/devlink.c list_del(&devlink->list); devlink 6241 net/core/devlink.c void devlink_reload_enable(struct devlink *devlink) devlink 6244 net/core/devlink.c devlink->reload_enabled = true; devlink 6257 net/core/devlink.c void devlink_reload_disable(struct devlink *devlink) devlink 6263 net/core/devlink.c devlink->reload_enabled = false; devlink 6273 net/core/devlink.c void devlink_free(struct devlink *devlink) devlink 6275 net/core/devlink.c mutex_destroy(&devlink->reporters_lock); devlink 6276 net/core/devlink.c mutex_destroy(&devlink->lock); devlink 6277 net/core/devlink.c WARN_ON(!list_empty(&devlink->trap_group_list)); devlink 6278 net/core/devlink.c WARN_ON(!list_empty(&devlink->trap_list)); devlink 6279 net/core/devlink.c WARN_ON(!list_empty(&devlink->reporter_list)); devlink 6280 net/core/devlink.c WARN_ON(!list_empty(&devlink->region_list)); devlink 6281 net/core/devlink.c WARN_ON(!list_empty(&devlink->param_list)); devlink 6282 net/core/devlink.c WARN_ON(!list_empty(&devlink->resource_list)); devlink 6283 net/core/devlink.c WARN_ON(!list_empty(&devlink->dpipe_table_list)); devlink 6284 net/core/devlink.c WARN_ON(!list_empty(&devlink->sb_list)); devlink 6285 net/core/devlink.c WARN_ON(!list_empty(&devlink->port_list)); devlink 6287 net/core/devlink.c kfree(devlink); devlink 6336 net/core/devlink.c int devlink_port_register(struct devlink *devlink, devlink 6340 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6341 net/core/devlink.c if (devlink_port_index_exists(devlink, port_index)) { devlink 6342 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6345 net/core/devlink.c devlink_port->devlink = devlink; devlink 6349 net/core/devlink.c list_add_tail(&devlink_port->list, &devlink->port_list); devlink 6351 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6366 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 6370 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6372 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6611 net/core/devlink.c int devlink_sb_register(struct devlink *devlink, unsigned int sb_index, devlink 6619 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6620 net/core/devlink.c if (devlink_sb_index_exists(devlink, sb_index)) { devlink 6636 net/core/devlink.c list_add_tail(&devlink_sb->list, &devlink->sb_list); devlink 6638 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6643 net/core/devlink.c void devlink_sb_unregister(struct devlink *devlink, unsigned int sb_index) devlink 6647 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6648 net/core/devlink.c devlink_sb = devlink_sb_get_by_index(devlink, sb_index); devlink 6651 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6664 net/core/devlink.c int devlink_dpipe_headers_register(struct devlink *devlink, devlink 6667 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6668 net/core/devlink.c devlink->dpipe_headers = dpipe_headers; devlink 6669 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6681 net/core/devlink.c void devlink_dpipe_headers_unregister(struct devlink *devlink) devlink 6683 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6684 net/core/devlink.c devlink->dpipe_headers = NULL; devlink 6685 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6703 net/core/devlink.c bool devlink_dpipe_table_counter_enabled(struct devlink *devlink, devlink 6710 net/core/devlink.c table = devlink_dpipe_table_find(&devlink->dpipe_table_list, devlink 6729 net/core/devlink.c int devlink_dpipe_table_register(struct devlink *devlink, devlink 6736 net/core/devlink.c if (devlink_dpipe_table_find(&devlink->dpipe_table_list, table_name)) devlink 6751 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6752 net/core/devlink.c list_add_tail_rcu(&table->list, &devlink->dpipe_table_list); devlink 6753 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6764 net/core/devlink.c void devlink_dpipe_table_unregister(struct devlink *devlink, devlink 6769 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6770 net/core/devlink.c table = devlink_dpipe_table_find(&devlink->dpipe_table_list, devlink 6775 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6779 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6793 net/core/devlink.c int devlink_resource_register(struct devlink *devlink, devlink 6807 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6808 net/core/devlink.c resource = devlink_resource_find(devlink, NULL, resource_id); devlink 6821 net/core/devlink.c resource_list = &devlink->resource_list; devlink 6825 net/core/devlink.c parent_resource = devlink_resource_find(devlink, NULL, devlink 6847 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6858 net/core/devlink.c void devlink_resources_unregister(struct devlink *devlink, devlink 6867 net/core/devlink.c resource_list = &devlink->resource_list; devlink 6870 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6873 net/core/devlink.c devlink_resources_unregister(devlink, child_resource); devlink 6879 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6890 net/core/devlink.c int devlink_resource_size_get(struct devlink *devlink, devlink 6897 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6898 net/core/devlink.c resource = devlink_resource_find(devlink, NULL, resource_id); devlink 6906 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6919 net/core/devlink.c int devlink_dpipe_table_resource_set(struct devlink *devlink, devlink 6926 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6927 net/core/devlink.c table = devlink_dpipe_table_find(&devlink->dpipe_table_list, devlink 6937 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6950 net/core/devlink.c void devlink_resource_occ_get_register(struct devlink *devlink, devlink 6957 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6958 net/core/devlink.c resource = devlink_resource_find(devlink, NULL, resource_id); devlink 6966 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 6976 net/core/devlink.c void devlink_resource_occ_get_unregister(struct devlink *devlink, devlink 6981 net/core/devlink.c mutex_lock(&devlink->lock); devlink 6982 net/core/devlink.c resource = devlink_resource_find(devlink, NULL, resource_id); devlink 6990 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7004 net/core/devlink.c static int __devlink_params_register(struct devlink *devlink, devlink 7016 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7022 net/core/devlink.c err = devlink_param_register_one(devlink, port_index, devlink 7028 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7035 net/core/devlink.c devlink_param_unregister_one(devlink, port_index, param_list, devlink 7038 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7042 net/core/devlink.c static void __devlink_params_unregister(struct devlink *devlink, devlink 7052 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7054 net/core/devlink.c devlink_param_unregister_one(devlink, 0, param_list, param, devlink 7056 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7068 net/core/devlink.c int devlink_params_register(struct devlink *devlink, devlink 7072 net/core/devlink.c return __devlink_params_register(devlink, 0, &devlink->param_list, devlink 7085 net/core/devlink.c void devlink_params_unregister(struct devlink *devlink, devlink 7089 net/core/devlink.c return __devlink_params_unregister(devlink, 0, &devlink->param_list, devlink 7102 net/core/devlink.c void devlink_params_publish(struct devlink *devlink) devlink 7106 net/core/devlink.c list_for_each_entry(param_item, &devlink->param_list, list) { devlink 7110 net/core/devlink.c devlink_param_notify(devlink, 0, param_item, devlink 7123 net/core/devlink.c void devlink_params_unpublish(struct devlink *devlink) devlink 7127 net/core/devlink.c list_for_each_entry(param_item, &devlink->param_list, list) { devlink 7131 net/core/devlink.c devlink_param_notify(devlink, 0, param_item, devlink 7150 net/core/devlink.c return __devlink_params_register(devlink_port->devlink, devlink 7171 net/core/devlink.c return __devlink_params_unregister(devlink_port->devlink, devlink 7203 net/core/devlink.c __devlink_param_driverinit_value_set(struct devlink *devlink, devlink 7225 net/core/devlink.c devlink_param_notify(devlink, port_index, param_item, cmd); devlink 7240 net/core/devlink.c int devlink_param_driverinit_value_get(struct devlink *devlink, u32 param_id, devlink 7243 net/core/devlink.c if (!devlink_reload_supported(devlink)) devlink 7246 net/core/devlink.c return __devlink_param_driverinit_value_get(&devlink->param_list, devlink 7263 net/core/devlink.c int devlink_param_driverinit_value_set(struct devlink *devlink, u32 param_id, devlink 7266 net/core/devlink.c return __devlink_param_driverinit_value_set(devlink, 0, devlink 7267 net/core/devlink.c &devlink->param_list, devlink 7288 net/core/devlink.c struct devlink *devlink = devlink_port->devlink; devlink 7290 net/core/devlink.c if (!devlink_reload_supported(devlink)) devlink 7314 net/core/devlink.c return __devlink_param_driverinit_value_set(devlink_port->devlink, devlink 7334 net/core/devlink.c void devlink_param_value_changed(struct devlink *devlink, u32 param_id) devlink 7338 net/core/devlink.c param_item = devlink_param_find_by_id(&devlink->param_list, param_id); devlink 7341 net/core/devlink.c devlink_param_notify(devlink, 0, param_item, DEVLINK_CMD_PARAM_NEW); devlink 7367 net/core/devlink.c devlink_param_notify(devlink_port->devlink, devlink_port->index, devlink 7397 net/core/devlink.c struct devlink_region *devlink_region_create(struct devlink *devlink, devlink 7405 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7407 net/core/devlink.c if (devlink_region_get_by_name(devlink, region_name)) { devlink 7418 net/core/devlink.c region->devlink = devlink; devlink 7423 net/core/devlink.c list_add_tail(®ion->list, &devlink->region_list); devlink 7426 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7430 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7442 net/core/devlink.c struct devlink *devlink = region->devlink; devlink 7445 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7454 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7468 net/core/devlink.c u32 devlink_region_shapshot_id_get(struct devlink *devlink) devlink 7472 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7473 net/core/devlink.c id = ++devlink->snapshot_id; devlink 7474 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7497 net/core/devlink.c struct devlink *devlink = region->devlink; devlink 7501 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7530 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7534 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7647 net/core/devlink.c devlink_trap_group_notify(struct devlink *devlink, devlink 7661 net/core/devlink.c err = devlink_nl_trap_group_fill(msg, devlink, group_item, cmd, 0, 0, devlink 7668 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 7673 net/core/devlink.c devlink_trap_group_item_create(struct devlink *devlink, devlink 7696 net/core/devlink.c if (devlink->ops->trap_group_init) { devlink 7697 net/core/devlink.c err = devlink->ops->trap_group_init(devlink, group); devlink 7702 net/core/devlink.c list_add_tail(&group_item->list, &devlink->trap_group_list); devlink 7703 net/core/devlink.c devlink_trap_group_notify(devlink, group_item, devlink 7716 net/core/devlink.c devlink_trap_group_item_destroy(struct devlink *devlink, devlink 7719 net/core/devlink.c devlink_trap_group_notify(devlink, group_item, devlink 7727 net/core/devlink.c devlink_trap_group_item_get(struct devlink *devlink, devlink 7732 net/core/devlink.c group_item = devlink_trap_group_item_lookup(devlink, group->name); devlink 7738 net/core/devlink.c return devlink_trap_group_item_create(devlink, group); devlink 7742 net/core/devlink.c devlink_trap_group_item_put(struct devlink *devlink, devlink 7748 net/core/devlink.c devlink_trap_group_item_destroy(devlink, group_item); devlink 7752 net/core/devlink.c devlink_trap_item_group_link(struct devlink *devlink, devlink 7757 net/core/devlink.c group_item = devlink_trap_group_item_get(devlink, devlink 7768 net/core/devlink.c devlink_trap_item_group_unlink(struct devlink *devlink, devlink 7771 net/core/devlink.c devlink_trap_group_item_put(devlink, trap_item->group_item); devlink 7774 net/core/devlink.c static void devlink_trap_notify(struct devlink *devlink, devlink 7788 net/core/devlink.c err = devlink_nl_trap_fill(msg, devlink, trap_item, cmd, 0, 0, 0); devlink 7794 net/core/devlink.c genlmsg_multicast_netns(&devlink_nl_family, devlink_net(devlink), devlink 7799 net/core/devlink.c devlink_trap_register(struct devlink *devlink, devlink 7805 net/core/devlink.c if (devlink_trap_item_lookup(devlink, trap->name)) devlink 7822 net/core/devlink.c err = devlink_trap_item_group_link(devlink, trap_item); devlink 7826 net/core/devlink.c err = devlink->ops->trap_init(devlink, trap, trap_item); devlink 7830 net/core/devlink.c list_add_tail(&trap_item->list, &devlink->trap_list); devlink 7831 net/core/devlink.c devlink_trap_notify(devlink, trap_item, DEVLINK_CMD_TRAP_NEW); devlink 7836 net/core/devlink.c devlink_trap_item_group_unlink(devlink, trap_item); devlink 7844 net/core/devlink.c static void devlink_trap_unregister(struct devlink *devlink, devlink 7849 net/core/devlink.c trap_item = devlink_trap_item_lookup(devlink, trap->name); devlink 7853 net/core/devlink.c devlink_trap_notify(devlink, trap_item, DEVLINK_CMD_TRAP_DEL); devlink 7855 net/core/devlink.c if (devlink->ops->trap_fini) devlink 7856 net/core/devlink.c devlink->ops->trap_fini(devlink, trap, trap_item); devlink 7857 net/core/devlink.c devlink_trap_item_group_unlink(devlink, trap_item); devlink 7862 net/core/devlink.c static void devlink_trap_disable(struct devlink *devlink, devlink 7867 net/core/devlink.c trap_item = devlink_trap_item_lookup(devlink, trap->name); devlink 7871 net/core/devlink.c devlink->ops->trap_action_set(devlink, trap, DEVLINK_TRAP_ACTION_DROP); devlink 7884 net/core/devlink.c int devlink_traps_register(struct devlink *devlink, devlink 7890 net/core/devlink.c if (!devlink->ops->trap_init || !devlink->ops->trap_action_set) devlink 7893 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7901 net/core/devlink.c err = devlink_trap_register(devlink, trap, priv); devlink 7905 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7912 net/core/devlink.c devlink_trap_unregister(devlink, &traps[i]); devlink 7913 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7924 net/core/devlink.c void devlink_traps_unregister(struct devlink *devlink, devlink 7930 net/core/devlink.c mutex_lock(&devlink->lock); devlink 7935 net/core/devlink.c devlink_trap_disable(devlink, &traps[i]); devlink 7938 net/core/devlink.c devlink_trap_unregister(devlink, &traps[i]); devlink 7939 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 7979 net/core/devlink.c void devlink_trap_report(struct devlink *devlink, struct sk_buff *skb, devlink 8008 net/core/devlink.c static void __devlink_compat_running_version(struct devlink *devlink, devlink 8021 net/core/devlink.c err = devlink->ops->info_get(devlink, &req, NULL); devlink 8047 net/core/devlink.c struct devlink *devlink; devlink 8052 net/core/devlink.c devlink = netdev_to_devlink(dev); devlink 8053 net/core/devlink.c if (!devlink || !devlink->ops->info_get) devlink 8056 net/core/devlink.c mutex_lock(&devlink->lock); devlink 8057 net/core/devlink.c __devlink_compat_running_version(devlink, buf, len); devlink 8058 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 8067 net/core/devlink.c struct devlink *devlink; devlink 8073 net/core/devlink.c devlink = netdev_to_devlink(dev); devlink 8074 net/core/devlink.c if (!devlink || !devlink->ops->flash_update) { devlink 8079 net/core/devlink.c mutex_lock(&devlink->lock); devlink 8080 net/core/devlink.c ret = devlink->ops->flash_update(devlink, file_name, NULL, NULL); devlink 8081 net/core/devlink.c mutex_unlock(&devlink->lock); devlink 264 net/dsa/dsa2.c struct devlink *dl = ds->devlink; devlink 382 net/dsa/dsa2.c ds->devlink = devlink_alloc(&dsa_devlink_ops, 0); devlink 383 net/dsa/dsa2.c if (!ds->devlink) devlink 386 net/dsa/dsa2.c err = devlink_register(ds->devlink, ds->dev); devlink 417 net/dsa/dsa2.c devlink_unregister(ds->devlink); devlink 419 net/dsa/dsa2.c devlink_free(ds->devlink); devlink 420 net/dsa/dsa2.c ds->devlink = NULL; devlink 435 net/dsa/dsa2.c if (ds->devlink) { devlink 436 net/dsa/dsa2.c devlink_unregister(ds->devlink); devlink 437 net/dsa/dsa2.c devlink_free(ds->devlink); devlink 438 net/dsa/dsa2.c ds->devlink = NULL; devlink 438 net/dsa/slave.c if (dp->ds->devlink) devlink 839 net/dsa/slave.c if (dp->ds->devlink) devlink 1221 net/dsa/slave.c return dp->ds->devlink ? &dp->devlink_port : NULL;