Commit bc3ef6605ea325e41b586a76aadc3f731c317504
Committed by
David S. Miller
1 parent
b4aa9e05a6
Exists in
master
and in
7 other branches
ipv6: fib6_ifdown cleanup
Remove (unnecessary) casts to make code cleaner. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Showing 1 changed file with 4 additions and 4 deletions Side-by-side Diff
net/ipv6/route.c
... | ... | @@ -2009,11 +2009,11 @@ |
2009 | 2009 | |
2010 | 2010 | static int fib6_ifdown(struct rt6_info *rt, void *arg) |
2011 | 2011 | { |
2012 | - struct net_device *dev = ((struct arg_dev_net *)arg)->dev; | |
2013 | - struct net *net = ((struct arg_dev_net *)arg)->net; | |
2012 | + const struct arg_dev_net *adn = arg; | |
2013 | + const struct net_device *dev = adn->dev; | |
2014 | 2014 | |
2015 | - if (((void *)rt->rt6i_dev == dev || dev == NULL) && | |
2016 | - rt != net->ipv6.ip6_null_entry) { | |
2015 | + if ((rt->rt6i_dev == dev || dev == NULL) && | |
2016 | + rt != adn->net->ipv6.ip6_null_entry) { | |
2017 | 2017 | RT6_TRACE("deleted by ifdown %p\n", rt); |
2018 | 2018 | return -1; |
2019 | 2019 | } |