summaryrefslogtreecommitdiffstats
path: root/sys/net/fddi.h
diff options
context:
space:
mode:
authormdodd <mdodd@FreeBSD.org>2002-03-29 08:27:48 +0000
committermdodd <mdodd@FreeBSD.org>2002-03-29 08:27:48 +0000
commitf5718efee5938be0aa3851ac3b50b19d82a897ce (patch)
treee696492e5aa9aa99f1c8a9af5a67e34a6f8c2d1d /sys/net/fddi.h
parenta236d39b78a8084db5ea2090c5546dda86340971 (diff)
downloadFreeBSD-src-f5718efee5938be0aa3851ac3b50b19d82a897ce.zip
FreeBSD-src-f5718efee5938be0aa3851ac3b50b19d82a897ce.tar.gz
Sync defines with NetBSD.
Define FDDI_ADDR_LEN and use it.
Diffstat (limited to 'sys/net/fddi.h')
-rw-r--r--sys/net/fddi.h43
1 files changed, 30 insertions, 13 deletions
diff --git a/sys/net/fddi.h b/sys/net/fddi.h
index 811d069..7ff9a5d 100644
--- a/sys/net/fddi.h
+++ b/sys/net/fddi.h
@@ -39,15 +39,6 @@
#ifndef _NETINET_IF_FDDI_H_
#define _NETINET_IF_FDDI_H_
-/*
- * Structure of an 100Mb/s FDDI header.
- */
-struct fddi_header {
- u_char fddi_fc;
- u_char fddi_dhost[6];
- u_char fddi_shost[6];
-};
-
#define FDDIIPMTU 4352
#define FDDIMTU 4470
#define FDDIMIN 3
@@ -56,7 +47,17 @@ struct fddi_header {
#define FDDIFC_L 0x40 /* 0b01000000 */
#define FDDIFC_F 0x30 /* 0b00110000 */
#define FDDIFC_Z 0x0F /* 0b00001111 */
+#define FDDIFC_CLFF 0xF0 /* Class/Length/Format bits */
+#define FDDIFC_ZZZZ 0x0F /* Control bits */
+/*
+ * FDDI Frame Control values. (48-bit addressing only).
+ */
+#define FDDIFC_VOID 0x40 /* Void frame */
+#define FDDIFC_NRT 0x80 /* Nonrestricted token */
+#define FDDIFC_RT 0xc0 /* Restricted token */
+#define FDDIFC_MAC_BEACON 0xc2 /* MAC Beacon frame */
+#define FDDIFC_MAC_CLAIM 0xc3 /* MAC Claim frame */
#define FDDIFC_LLC_ASYNC 0x50
#define FDDIFC_LLC_PRIO0 0
#define FDDIFC_LLC_PRIO1 1
@@ -66,8 +67,25 @@ struct fddi_header {
#define FDDIFC_LLC_PRIO5 5
#define FDDIFC_LLC_PRIO6 6
#define FDDIFC_LLC_PRIO7 7
-#define FDDIFC_LLC_SYNC 0xd0
+#define FDDIFC_LLC_SYNC 0xd0
+#define FDDIFC_IMP_ASYNC 0x60 /* Implementor Async. */
+#define FDDIFC_IMP_SYNC 0xe0 /* Implementor Synch. */
#define FDDIFC_SMT 0x40
+#define FDDIFC_SMT_INFO 0x41 /* SMT Info */
+#define FDDIFC_SMT_NSA 0x4F /* SMT Next station adrs */
+#define FDDIFC_MAC 0xc0 /* MAC frame */
+
+#define FDDI_ADDR_LEN 6
+#define FDDI_HDR_LEN (sizeof(struct fddi_header))
+
+/*
+ * Structure of an 100Mb/s FDDI header.
+ */
+struct fddi_header {
+ u_char fddi_fc;
+ u_char fddi_dhost[FDDI_ADDR_LEN];
+ u_char fddi_shost[FDDI_ADDR_LEN];
+};
#if defined(_KERNEL)
#define fddibroadcastaddr etherbroadcastaddr
@@ -82,6 +100,5 @@ void fddi_input(struct ifnet *, struct fddi_header *, struct mbuf *);
int fddi_output(struct ifnet *,
struct mbuf *, struct sockaddr *, struct rtentry *);
-#endif
-
-#endif
+#endif /* _KERNEL */
+#endif /* _NET_FDDI_H_ */
OpenPOWER on IntegriCloud