aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/addrconf.c
diff options
context:
space:
mode:
authorIlpo Järvinen <ilpo.jarvinen@helsinki.fi>2009-03-21 16:36:17 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-21 16:36:17 -0400
commita0bffffc148cd8e75a48a89ad2ddb74e4081a20a (patch)
tree3a4d350d65d88bb1df8906b4822af2350ceb1cfc /net/ipv6/addrconf.c
parenta3ac80a130300573de351083cf4a5b46d233e8bf (diff)
net/*: use linux/kernel.h swap()
tcp_sack_swap seems unnecessary so I pushed swap to the caller. Also removed comment that seemed then pointless, and added include when not already there. Compile tested. Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/addrconf.c')
-rw-r--r--net/ipv6/addrconf.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 717584bad02e..8499da9e76a2 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -40,6 +40,7 @@
40 40
41#include <linux/errno.h> 41#include <linux/errno.h>
42#include <linux/types.h> 42#include <linux/types.h>
43#include <linux/kernel.h>
43#include <linux/socket.h> 44#include <linux/socket.h>
44#include <linux/sockios.h> 45#include <linux/sockios.h>
45#include <linux/net.h> 46#include <linux/net.h>
@@ -1215,16 +1216,12 @@ int ipv6_dev_get_saddr(struct net *net, struct net_device *dst_dev,
1215 } 1216 }
1216 break; 1217 break;
1217 } else if (minihiscore < miniscore) { 1218 } else if (minihiscore < miniscore) {
1218 struct ipv6_saddr_score *tmp;
1219
1220 if (hiscore->ifa) 1219 if (hiscore->ifa)
1221 in6_ifa_put(hiscore->ifa); 1220 in6_ifa_put(hiscore->ifa);
1222 1221
1223 in6_ifa_hold(score->ifa); 1222 in6_ifa_hold(score->ifa);
1224 1223
1225 tmp = hiscore; 1224 swap(hiscore, score);
1226 hiscore = score;
1227 score = tmp;
1228 1225
1229 /* restore our iterator */ 1226 /* restore our iterator */
1230 score->ifa = hiscore->ifa; 1227 score->ifa = hiscore->ifa;