aboutsummaryrefslogtreecommitdiffstats
path: root/net/decnet/dn_route.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/decnet/dn_route.c')
-rw-r--r--net/decnet/dn_route.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/net/decnet/dn_route.c b/net/decnet/dn_route.c
index c754670b7fca..0cc4394117df 100644
--- a/net/decnet/dn_route.c
+++ b/net/decnet/dn_route.c
@@ -124,7 +124,7 @@ int decnet_dst_gc_interval = 2;
124 124
125static struct dst_ops dn_dst_ops = { 125static struct dst_ops dn_dst_ops = {
126 .family = PF_DECnet, 126 .family = PF_DECnet,
127 .protocol = __constant_htons(ETH_P_DNA_RT), 127 .protocol = cpu_to_be16(ETH_P_DNA_RT),
128 .gc_thresh = 128, 128 .gc_thresh = 128,
129 .gc = dn_dst_gc, 129 .gc = dn_dst_gc,
130 .check = dn_dst_check, 130 .check = dn_dst_check,
@@ -380,7 +380,6 @@ static int dn_return_short(struct sk_buff *skb)
380 unsigned char *ptr; 380 unsigned char *ptr;
381 __le16 *src; 381 __le16 *src;
382 __le16 *dst; 382 __le16 *dst;
383 __le16 tmp;
384 383
385 /* Add back headers */ 384 /* Add back headers */
386 skb_push(skb, skb->data - skb_network_header(skb)); 385 skb_push(skb, skb->data - skb_network_header(skb));
@@ -399,10 +398,7 @@ static int dn_return_short(struct sk_buff *skb)
399 ptr += 2; 398 ptr += 2;
400 *ptr = 0; /* Zero hop count */ 399 *ptr = 0; /* Zero hop count */
401 400
402 /* Swap source and destination */ 401 swap(*src, *dst);
403 tmp = *src;
404 *src = *dst;
405 *dst = tmp;
406 402
407 skb->pkt_type = PACKET_OUTGOING; 403 skb->pkt_type = PACKET_OUTGOING;
408 dn_rt_finish_output(skb, NULL, NULL); 404 dn_rt_finish_output(skb, NULL, NULL);