Skip to content

Commit

Permalink
devlink: rename devlink_nl_ops to devlink_nl_small_ops
Browse files Browse the repository at this point in the history
In order to avoid name collision with the generated split ops array
which is going to be introduced as a follow-up patch, rename
the existing ops array to devlink_nl_small_ops.

Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Reviewed-by: Jakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20230803111340.1074067-6-jiri@resnulli.us
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Jiri Pirko authored and Jakub Kicinski committed Aug 4, 2023
1 parent fa8ba35 commit ba0f66c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion net/devlink/devl_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ struct devlink_cmd {
struct netlink_callback *cb);
};

extern const struct genl_small_ops devlink_nl_ops[56];
extern const struct genl_small_ops devlink_nl_small_ops[56];

struct devlink *
devlink_get_from_attrs_lock(struct net *net, struct nlattr **attrs);
Expand Down
2 changes: 1 addition & 1 deletion net/devlink/leftover.c
Original file line number Diff line number Diff line change
Expand Up @@ -6278,7 +6278,7 @@ static int devlink_nl_cmd_trap_policer_set_doit(struct sk_buff *skb,
return devlink_trap_policer_set(devlink, policer_item, info);
}

const struct genl_small_ops devlink_nl_ops[56] = {
const struct genl_small_ops devlink_nl_small_ops[56] = {
{
.cmd = DEVLINK_CMD_GET,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
Expand Down
4 changes: 2 additions & 2 deletions net/devlink/netlink.c
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ struct genl_family devlink_nl_family __ro_after_init = {
.pre_doit = devlink_nl_pre_doit,
.post_doit = devlink_nl_post_doit,
.module = THIS_MODULE,
.small_ops = devlink_nl_ops,
.n_small_ops = ARRAY_SIZE(devlink_nl_ops),
.small_ops = devlink_nl_small_ops,
.n_small_ops = ARRAY_SIZE(devlink_nl_small_ops),
.resv_start_op = DEVLINK_CMD_SELFTESTS_RUN + 1,
.mcgrps = devlink_nl_mcgrps,
.n_mcgrps = ARRAY_SIZE(devlink_nl_mcgrps),
Expand Down

0 comments on commit ba0f66c

Please sign in to comment.