act_mirred: fix a typo in get_dev
Fixes: 255cb30425
("net/sched: act_mirred: Add new tc_action_ops get_dev()")
Cc: Hadar Hen Zion <hadarh@mellanox.com>
Cc: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
db7e9f7c56
commit
548ed72246
|
@ -321,7 +321,7 @@ static int tcf_mirred_device(const struct tc_action *a, struct net *net,
|
||||||
int ifindex = tcf_mirred_ifindex(a);
|
int ifindex = tcf_mirred_ifindex(a);
|
||||||
|
|
||||||
*mirred_dev = __dev_get_by_index(net, ifindex);
|
*mirred_dev = __dev_get_by_index(net, ifindex);
|
||||||
if (!mirred_dev)
|
if (!*mirred_dev)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue