diff options
| author | David S. Miller <davem@davemloft.net> | 2024-06-05 12:24:58 +0300 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2024-06-05 12:24:58 +0300 |
| commit | fd70f0443e24c3888bf4b7f198df6d705c9b8ab2 (patch) | |
| tree | d8d3c13b52c92efe2020385affa0fd444e28429f /include | |
| parent | 61578f67937881abf54c8bd258eb913312dbe4c1 (diff) | |
| parent | b072aa7899189127e26b2daf8c38933c994f97d3 (diff) | |
| download | linux-fd70f0443e24c3888bf4b7f198df6d705c9b8ab2.tar.xz | |
Merge branch 'devlink-const'
Christophe JAILLET says:
====================
devlink: Constify struct devlink_dpipe_table_ops
Patch 1 updates devl_dpipe_table_register() and struct
devlink_dpipe_table to accept "const struct devlink_dpipe_table_ops".
Then patch 2 updates the only user of this function.
This is compile tested only.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
| -rw-r--r-- | include/net/devlink.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/net/devlink.h b/include/net/devlink.h index 35eb0f884386..db5eff6cb60f 100644 --- a/include/net/devlink.h +++ b/include/net/devlink.h @@ -352,7 +352,7 @@ struct devlink_dpipe_table { bool resource_valid; u64 resource_id; u64 resource_units; - struct devlink_dpipe_table_ops *table_ops; + const struct devlink_dpipe_table_ops *table_ops; struct rcu_head rcu; }; @@ -1751,7 +1751,7 @@ void devl_sb_unregister(struct devlink *devlink, unsigned int sb_index); void devlink_sb_unregister(struct devlink *devlink, unsigned int sb_index); int devl_dpipe_table_register(struct devlink *devlink, const char *table_name, - struct devlink_dpipe_table_ops *table_ops, + const struct devlink_dpipe_table_ops *table_ops, void *priv, bool counter_control_extern); void devl_dpipe_table_unregister(struct devlink *devlink, const char *table_name); |
