summaryrefslogtreecommitdiffstats
path: root/net/ipv4/ip_fragment.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-05-17 17:28:02 -0400
committerDavid S. Miller <davem@davemloft.net>2011-05-17 17:28:02 -0400
commit1d1652cbdb9885e4d73972263e4cdbe1b0beebfe (patch)
tree6ded7338cfec98f1adf0b5606dc9a09a0f701d9d /net/ipv4/ip_fragment.c
parent11e73de7ccc1c9c61c65f914a214cb6467966a51 (diff)
downloadlinux-1d1652cbdb9885e4d73972263e4cdbe1b0beebfe.tar.bz2
ipv4: Don't use enums as bitmasks in ip_fragment.c
Noticed by Joe Perches. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ip_fragment.c')
-rw-r--r--net/ipv4/ip_fragment.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c
index 9e1458d3e465..0ad6035f6366 100644
--- a/net/ipv4/ip_fragment.c
+++ b/net/ipv4/ip_fragment.c
@@ -81,12 +81,10 @@ struct ipq {
* We want to check ECN values of all fragments, do detect invalid combinations.
* In ipq->ecn, we store the OR value of each ip4_frag_ecn() fragment value.
*/
-enum {
- IPFRAG_ECN_NOT_ECT = 0x01, /* one frag had ECN_NOT_ECT */
- IPFRAG_ECN_ECT_1 = 0x02, /* one frag had ECN_ECT_1 */
- IPFRAG_ECN_ECT_0 = 0x04, /* one frag had ECN_ECT_0 */
- IPFRAG_ECN_CE = 0x08, /* one frag had ECN_CE */
-};
+#define IPFRAG_ECN_NOT_ECT 0x01 /* one frag had ECN_NOT_ECT */
+#define IPFRAG_ECN_ECT_1 0x02 /* one frag had ECN_ECT_1 */
+#define IPFRAG_ECN_ECT_0 0x04 /* one frag had ECN_ECT_0 */
+#define IPFRAG_ECN_CE 0x08 /* one frag had ECN_CE */
static inline u8 ip4_frag_ecn(u8 tos)
{