aboutsummaryrefslogtreecommitdiffstats
path: root/net/decnet/dn_route.c
diff options
context:
space:
mode:
authorHarvey Harrison <harvey.harrison@gmail.com>2008-11-27 03:12:47 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-27 03:12:47 -0500
commitc4106aa88a440430d387e022f2ad6dc1e0d52e98 (patch)
tree09064e6e767301ca28357ed5125e99123f5beaca /net/decnet/dn_route.c
parent5b9ab2ec04ec1e1e53939768805612ac191d7ba2 (diff)
decnet: remove private wrappers of endian helpers
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Reviewed-by: Steven Whitehouse <swhiteho@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/decnet/dn_route.c')
-rw-r--r--net/decnet/dn_route.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/net/decnet/dn_route.c b/net/decnet/dn_route.c
index eeaa3d819f9c..b33b254c52cb 100644
--- a/net/decnet/dn_route.c
+++ b/net/decnet/dn_route.c
@@ -475,7 +475,7 @@ static int dn_route_rx_packet(struct sk_buff *skb)
475 printk(KERN_DEBUG 475 printk(KERN_DEBUG
476 "DECnet: dn_route_rx_packet: rt_flags=0x%02x dev=%s len=%d src=0x%04hx dst=0x%04hx err=%d type=%d\n", 476 "DECnet: dn_route_rx_packet: rt_flags=0x%02x dev=%s len=%d src=0x%04hx dst=0x%04hx err=%d type=%d\n",
477 (int)cb->rt_flags, devname, skb->len, 477 (int)cb->rt_flags, devname, skb->len,
478 dn_ntohs(cb->src), dn_ntohs(cb->dst), 478 le16_to_cpu(cb->src), le16_to_cpu(cb->dst),
479 err, skb->pkt_type); 479 err, skb->pkt_type);
480 } 480 }
481 481
@@ -575,7 +575,7 @@ int dn_route_rcv(struct sk_buff *skb, struct net_device *dev, struct packet_type
575{ 575{
576 struct dn_skb_cb *cb; 576 struct dn_skb_cb *cb;
577 unsigned char flags = 0; 577 unsigned char flags = 0;
578 __u16 len = dn_ntohs(*(__le16 *)skb->data); 578 __u16 len = le16_to_cpu(*(__le16 *)skb->data);
579 struct dn_dev *dn = (struct dn_dev *)dev->dn_ptr; 579 struct dn_dev *dn = (struct dn_dev *)dev->dn_ptr;
580 unsigned char padlen = 0; 580 unsigned char padlen = 0;
581 581
@@ -773,7 +773,7 @@ static int dn_rt_bug(struct sk_buff *skb)
773 struct dn_skb_cb *cb = DN_SKB_CB(skb); 773 struct dn_skb_cb *cb = DN_SKB_CB(skb);
774 774
775 printk(KERN_DEBUG "dn_rt_bug: skb from:%04x to:%04x\n", 775 printk(KERN_DEBUG "dn_rt_bug: skb from:%04x to:%04x\n",
776 dn_ntohs(cb->src), dn_ntohs(cb->dst)); 776 le16_to_cpu(cb->src), le16_to_cpu(cb->dst));
777 } 777 }
778 778
779 kfree_skb(skb); 779 kfree_skb(skb);
@@ -816,7 +816,7 @@ static int dn_rt_set_next_hop(struct dn_route *rt, struct dn_fib_res *res)
816 816
817static inline int dn_match_addr(__le16 addr1, __le16 addr2) 817static inline int dn_match_addr(__le16 addr1, __le16 addr2)
818{ 818{
819 __u16 tmp = dn_ntohs(addr1) ^ dn_ntohs(addr2); 819 __u16 tmp = le16_to_cpu(addr1) ^ le16_to_cpu(addr2);
820 int match = 16; 820 int match = 16;
821 while(tmp) { 821 while(tmp) {
822 tmp >>= 1; 822 tmp >>= 1;
@@ -886,8 +886,8 @@ static int dn_route_output_slow(struct dst_entry **pprt, const struct flowi *old
886 if (decnet_debug_level & 16) 886 if (decnet_debug_level & 16)
887 printk(KERN_DEBUG 887 printk(KERN_DEBUG
888 "dn_route_output_slow: dst=%04x src=%04x mark=%d" 888 "dn_route_output_slow: dst=%04x src=%04x mark=%d"
889 " iif=%d oif=%d\n", dn_ntohs(oldflp->fld_dst), 889 " iif=%d oif=%d\n", le16_to_cpu(oldflp->fld_dst),
890 dn_ntohs(oldflp->fld_src), 890 le16_to_cpu(oldflp->fld_src),
891 oldflp->mark, init_net.loopback_dev->ifindex, oldflp->oif); 891 oldflp->mark, init_net.loopback_dev->ifindex, oldflp->oif);
892 892
893 /* If we have an output interface, verify its a DECnet device */ 893 /* If we have an output interface, verify its a DECnet device */
@@ -959,7 +959,7 @@ source_ok:
959 printk(KERN_DEBUG 959 printk(KERN_DEBUG
960 "dn_route_output_slow: initial checks complete." 960 "dn_route_output_slow: initial checks complete."
961 " dst=%o4x src=%04x oif=%d try_hard=%d\n", 961 " dst=%o4x src=%04x oif=%d try_hard=%d\n",
962 dn_ntohs(fl.fld_dst), dn_ntohs(fl.fld_src), 962 le16_to_cpu(fl.fld_dst), le16_to_cpu(fl.fld_src),
963 fl.oif, try_hard); 963 fl.oif, try_hard);
964 964
965 /* 965 /*
@@ -1711,8 +1711,8 @@ static int dn_rt_cache_seq_show(struct seq_file *seq, void *v)
1711 1711
1712 seq_printf(seq, "%-8s %-7s %-7s %04d %04d %04d\n", 1712 seq_printf(seq, "%-8s %-7s %-7s %04d %04d %04d\n",
1713 rt->u.dst.dev ? rt->u.dst.dev->name : "*", 1713 rt->u.dst.dev ? rt->u.dst.dev->name : "*",
1714 dn_addr2asc(dn_ntohs(rt->rt_daddr), buf1), 1714 dn_addr2asc(le16_to_cpu(rt->rt_daddr), buf1),
1715 dn_addr2asc(dn_ntohs(rt->rt_saddr), buf2), 1715 dn_addr2asc(le16_to_cpu(rt->rt_saddr), buf2),
1716 atomic_read(&rt->u.dst.__refcnt), 1716 atomic_read(&rt->u.dst.__refcnt),
1717 rt->u.dst.__use, 1717 rt->u.dst.__use,
1718 (int) dst_metric(&rt->u.dst, RTAX_RTT)); 1718 (int) dst_metric(&rt->u.dst, RTAX_RTT));