diff options
Diffstat (limited to 'drivers/net/team')
-rw-r--r-- | drivers/net/team/team.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/net/team/team.c b/drivers/net/team/team.c index 9ce0c51a04d5..5c7547c4f802 100644 --- a/drivers/net/team/team.c +++ b/drivers/net/team/team.c @@ -967,7 +967,6 @@ static struct netpoll_info *team_netpoll_info(struct team *team) #endif static void __team_port_change_port_added(struct team_port *port, bool linkup); - static int team_dev_type_check_change(struct net_device *dev, struct net_device *port_dev); @@ -1890,8 +1889,8 @@ static int team_nl_cmd_noop(struct sk_buff *skb, struct genl_info *info) hdr = genlmsg_put(msg, info->snd_portid, info->snd_seq, &team_nl_family, 0, TEAM_CMD_NOOP); - if (IS_ERR(hdr)) { - err = PTR_ERR(hdr); + if (!hdr) { + err = -EMSGSIZE; goto err_msg_put; } @@ -2091,8 +2090,8 @@ start_again: hdr = genlmsg_put(skb, portid, seq, &team_nl_family, flags | NLM_F_MULTI, TEAM_CMD_OPTIONS_GET); - if (IS_ERR(hdr)) - return PTR_ERR(hdr); + if (!hdr) + return -EMSGSIZE; if (nla_put_u32(skb, TEAM_ATTR_TEAM_IFINDEX, team->dev->ifindex)) goto nla_put_failure; @@ -2317,8 +2316,8 @@ static int team_nl_fill_port_list_get(struct sk_buff *skb, hdr = genlmsg_put(skb, portid, seq, &team_nl_family, flags, TEAM_CMD_PORT_LIST_GET); - if (IS_ERR(hdr)) - return PTR_ERR(hdr); + if (!hdr) + return -EMSGSIZE; if (nla_put_u32(skb, TEAM_ATTR_TEAM_IFINDEX, team->dev->ifindex)) goto nla_put_failure; |