Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cb6bf9cf authored by Wei Yongjun's avatar Wei Yongjun Committed by David S. Miller
Browse files

devlink: fix return value check in devlink_dpipe_header_put()



Fix the return value check which testing the wrong variable
in devlink_dpipe_header_put().

Fixes: 1555d204 ("devlink: Support for pipeline debug (dpipe)")
Signed-off-by: default avatarWei Yongjun <weiyongjun1@huawei.com>
Acked-by: default avatarJiri Pirko <jiri@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b46b99d7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2031,7 +2031,7 @@ static int devlink_dpipe_header_put(struct sk_buff *skb,
	int err;

	header_attr = nla_nest_start(skb, DEVLINK_ATTR_DPIPE_HEADER);
	if (!header)
	if (!header_attr)
		return -EMSGSIZE;

	if (nla_put_string(skb, DEVLINK_ATTR_DPIPE_HEADER_NAME, header->name) ||