summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2004-06-22 22:46:31 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2004-06-22 22:46:31 +0000
commit30265c03b173b2dc6666564bd1e7f0449f1d1e8e (patch)
treeabb3c319e69d37ab622973310bc61983564e9035
parent07c4dcafde1200024ef116c65fe8b50834bef6a7 (diff)
Add M_LINK0 for net80211; OK markus@ and mcbride@
-rw-r--r--sys/netinet/if_ether.h7
-rw-r--r--sys/sys/mbuf.h8
2 files changed, 11 insertions, 4 deletions
diff --git a/sys/netinet/if_ether.h b/sys/netinet/if_ether.h
index e666e1e8d98..50a0d133009 100644
--- a/sys/netinet/if_ether.h
+++ b/sys/netinet/if_ether.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_ether.h,v 1.31 2004/06/16 21:35:37 naddy Exp $ */
+/* $OpenBSD: if_ether.h,v 1.32 2004/06/22 22:46:30 millert Exp $ */
/* $NetBSD: if_ether.h,v 1.22 1996/05/11 13:00:00 mycroft Exp $ */
/*
@@ -86,6 +86,11 @@ struct ether_header {
#define ETHER_CRC_POLY_LE 0xedb88320
#define ETHER_CRC_POLY_BE 0x04c11db6
+/*
+ * Ethernet-specific mbuf flags.
+ */
+#define M_HASFCS M_LINK0 /* FCS included at end of frame */
+
#ifdef _KERNEL
/*
* Macro to map an IP multicast address to an Ethernet multicast address.
diff --git a/sys/sys/mbuf.h b/sys/sys/mbuf.h
index 2a83cee9778..16e31527dcc 100644
--- a/sys/sys/mbuf.h
+++ b/sys/sys/mbuf.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mbuf.h,v 1.75 2004/04/25 18:32:43 itojun Exp $ */
+/* $OpenBSD: mbuf.h,v 1.76 2004/06/22 22:46:30 millert Exp $ */
/* $NetBSD: mbuf.h,v 1.19 1996/02/09 18:25:14 christos Exp $ */
/*
@@ -73,7 +73,7 @@ struct m_hdr {
caddr_t mh_data; /* location of data */
u_int mh_len; /* amount of data in this mbuf */
short mh_type; /* type of data in this mbuf */
- short mh_flags; /* flags; see below */
+ u_short mh_flags; /* flags; see below */
};
/* record/packet header in first mbuf of chain; valid if M_PKTHDR set */
@@ -157,11 +157,13 @@ struct mbuf {
/* KAME IPv6 */
#define M_ANYCAST6 0x4000 /* received as IPv6 anycast */
+#define M_LINK0 0x8000 /* link layer specific flag */
+
#define M_LOOP 0x0040 /* for Mbuf statistics */
/* flags copied when copying m_pkthdr */
#define M_COPYFLAGS (M_PKTHDR|M_EOR|M_PROTO1|M_BCAST|M_MCAST|M_CONF|\
- M_AUTH|M_COMP|M_ANYCAST6|M_LOOP|M_TUNNEL)
+ M_AUTH|M_COMP|M_ANYCAST6|M_LOOP|M_TUNNEL|M_LINK0)
/* mbuf types */
#define MT_FREE 0 /* should be on free list */