summaryrefslogtreecommitdiffstats
path: root/include/net/devlink.h
diff options
context:
space:
mode:
authorJiri Pirko <jiri@nvidia.com>2023-01-26 08:58:33 +0100
committerDavid S. Miller <davem@davemloft.net>2023-01-27 13:32:02 +0100
commit85fe0b324c830ac671b811efc70ea80c3dcb2390 (patch)
tree1d03a943a8e6136ddeffdfaa33a2be616558af70 /include/net/devlink.h
parentqed: remove pointless call to devlink_param_driverinit_value_set() (diff)
downloadlinux-85fe0b324c830ac671b811efc70ea80c3dcb2390.tar.xz
linux-85fe0b324c830ac671b811efc70ea80c3dcb2390.zip
devlink: make devlink_param_driverinit_value_set() return void
devlink_param_driverinit_value_set() currently returns int with possible error, but no user is checking it anyway. The only reason for a fail is a driver bug. So convert the function to return void and put WARN_ONs on error paths. Signed-off-by: Jiri Pirko <jiri@nvidia.com> Reviewed-by: Jakub Kicinski <kuba@kernel.org> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/devlink.h')
-rw-r--r--include/net/devlink.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/net/devlink.h b/include/net/devlink.h
index cf74b6391896..e0d773dfa637 100644
--- a/include/net/devlink.h
+++ b/include/net/devlink.h
@@ -1775,8 +1775,8 @@ void devlink_params_unregister(struct devlink *devlink,
size_t params_count);
int devlink_param_driverinit_value_get(struct devlink *devlink, u32 param_id,
union devlink_param_value *init_val);
-int devlink_param_driverinit_value_set(struct devlink *devlink, u32 param_id,
- union devlink_param_value init_val);
+void devlink_param_driverinit_value_set(struct devlink *devlink, u32 param_id,
+ union devlink_param_value init_val);
void devlink_param_value_changed(struct devlink *devlink, u32 param_id);
struct devlink_region *devl_region_create(struct devlink *devlink,
const struct devlink_region_ops *ops,