]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
ethernet: print protocol in host byte order
authorJohannes Berg <johannes@sipsolutions.net>
Tue, 20 Apr 2010 21:06:07 +0000 (21:06 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Apr 2010 05:57:19 +0000 (22:57 -0700)
Eric's recent patch added __force, but this
place would seem to require actually doing
a byte order conversion so the printk is
consistent across architectures.

Cc: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ethernet/eth.c

index 35846964082c15217dc0e2e995b6241849ce5c08..0c0d272a9888af29d8c240535d3061377438df3f 100644 (file)
@@ -136,7 +136,7 @@ int eth_rebuild_header(struct sk_buff *skb)
        default:
                printk(KERN_DEBUG
                       "%s: unable to resolve type %X addresses.\n",
-                      dev->name, (__force int)eth->h_proto);
+                      dev->name, ntohs(eth->h_proto));
 
                memcpy(eth->h_source, dev->dev_addr, ETH_ALEN);
                break;