mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-29 04:45:05 +00:00
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: 1555d204e7
("devlink: Support for pipeline debug (dpipe)")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
b46b99d785
commit
cb6bf9cfdb
@ -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) ||
|
||||
|
Loading…
Reference in New Issue
Block a user