Skip to content

Commit 61c4378

Browse files
Jiri Pirkokuba-moo
authored andcommitted
devlink: fix port dump cmd type
Unlike other commands, due to a c&p error, port dump fills-up cmd with wrong value, different from port-get request cmd, port-get doit reply and port notification. Fix it by filling cmd with value DEVLINK_CMD_PORT_NEW. Skimmed through devlink userspace implementations, none of them cares about this cmd value. Only ynl, for which, this is actually a fix, as it expects doit and dumpit ops rsp_value to be the same. Omit the fixes tag, even thought this is fix, better to target this for next release. Fixes: bfcd3a4 ("Introduce devlink infrastructure") Signed-off-by: Jiri Pirko <[email protected]> Reviewed-by: Simon Horman <[email protected]> Reviewed-by: Jakub Kicinski <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 90d07e3 commit 61c4378

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/devlink/port.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -583,7 +583,7 @@ devlink_nl_port_get_dump_one(struct sk_buff *msg, struct devlink *devlink,
583583

584584
xa_for_each_start(&devlink->ports, port_index, devlink_port, state->idx) {
585585
err = devlink_nl_port_fill(msg, devlink_port,
586-
DEVLINK_CMD_NEW,
586+
DEVLINK_CMD_PORT_NEW,
587587
NETLINK_CB(cb->skb).portid,
588588
cb->nlh->nlmsg_seq, flags,
589589
cb->extack);

0 commit comments

Comments
 (0)