aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2014-03-12 13:04:17 -0400
committerDavid S. Miller <davem@davemloft.net>2014-03-12 15:28:06 -0400
commit2b8837aeaaa0bb6b4b3be1b3afd1cc088f68a362 (patch)
treed09be70a5204356d86bdefc74a1f1e67b545cacf
parentf0e78826e47facd538b74e3ef13f352f2a7db004 (diff)
net: Convert uses of __constant_<foo> to <foo>
The use of __constant_<foo> has been unnecessary for quite awhile now. Make these uses consistent with the rest of the kernel. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/core/dev.c10
-rw-r--r--net/core/flow_dissector.c14
2 files changed, 12 insertions, 12 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index b1b0c8d4d7df..587f9fb85d73 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3495,11 +3495,11 @@ EXPORT_SYMBOL_GPL(netdev_rx_handler_unregister);
3495static bool skb_pfmemalloc_protocol(struct sk_buff *skb) 3495static bool skb_pfmemalloc_protocol(struct sk_buff *skb)
3496{ 3496{
3497 switch (skb->protocol) { 3497 switch (skb->protocol) {
3498 case __constant_htons(ETH_P_ARP): 3498 case htons(ETH_P_ARP):
3499 case __constant_htons(ETH_P_IP): 3499 case htons(ETH_P_IP):
3500 case __constant_htons(ETH_P_IPV6): 3500 case htons(ETH_P_IPV6):
3501 case __constant_htons(ETH_P_8021Q): 3501 case htons(ETH_P_8021Q):
3502 case __constant_htons(ETH_P_8021AD): 3502 case htons(ETH_P_8021AD):
3503 return true; 3503 return true;
3504 default: 3504 default:
3505 return false; 3505 return false;
diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c
index e29e810663d7..80201bf69d59 100644
--- a/net/core/flow_dissector.c
+++ b/net/core/flow_dissector.c
@@ -61,7 +61,7 @@ bool skb_flow_dissect(const struct sk_buff *skb, struct flow_keys *flow)
61 61
62again: 62again:
63 switch (proto) { 63 switch (proto) {
64 case __constant_htons(ETH_P_IP): { 64 case htons(ETH_P_IP): {
65 const struct iphdr *iph; 65 const struct iphdr *iph;
66 struct iphdr _iph; 66 struct iphdr _iph;
67ip: 67ip:
@@ -77,7 +77,7 @@ ip:
77 iph_to_flow_copy_addrs(flow, iph); 77 iph_to_flow_copy_addrs(flow, iph);
78 break; 78 break;
79 } 79 }
80 case __constant_htons(ETH_P_IPV6): { 80 case htons(ETH_P_IPV6): {
81 const struct ipv6hdr *iph; 81 const struct ipv6hdr *iph;
82 struct ipv6hdr _iph; 82 struct ipv6hdr _iph;
83ipv6: 83ipv6:
@@ -91,8 +91,8 @@ ipv6:
91 nhoff += sizeof(struct ipv6hdr); 91 nhoff += sizeof(struct ipv6hdr);
92 break; 92 break;
93 } 93 }
94 case __constant_htons(ETH_P_8021AD): 94 case htons(ETH_P_8021AD):
95 case __constant_htons(ETH_P_8021Q): { 95 case htons(ETH_P_8021Q): {
96 const struct vlan_hdr *vlan; 96 const struct vlan_hdr *vlan;
97 struct vlan_hdr _vlan; 97 struct vlan_hdr _vlan;
98 98
@@ -104,7 +104,7 @@ ipv6:
104 nhoff += sizeof(*vlan); 104 nhoff += sizeof(*vlan);
105 goto again; 105 goto again;
106 } 106 }
107 case __constant_htons(ETH_P_PPP_SES): { 107 case htons(ETH_P_PPP_SES): {
108 struct { 108 struct {
109 struct pppoe_hdr hdr; 109 struct pppoe_hdr hdr;
110 __be16 proto; 110 __be16 proto;
@@ -115,9 +115,9 @@ ipv6:
115 proto = hdr->proto; 115 proto = hdr->proto;
116 nhoff += PPPOE_SES_HLEN; 116 nhoff += PPPOE_SES_HLEN;
117 switch (proto) { 117 switch (proto) {
118 case __constant_htons(PPP_IP): 118 case htons(PPP_IP):
119 goto ip; 119 goto ip;
120 case __constant_htons(PPP_IPV6): 120 case htons(PPP_IPV6):
121 goto ipv6; 121 goto ipv6;
122 default: 122 default:
123 return false; 123 return false;