Latest fixes from Nesheim@cornell
[unix-history] / usr / src / sys / vax / if / if_vv.h
index 98ab06e..62614a4 100644 (file)
@@ -1,9 +1,26 @@
-/*     if_vv.h 4.2     82/08/01        */
 /*
 /*
- * Local network header for V2LNI Ring
- * This is arbitrated by "V2LNI-PEOPLE@MIT-MC"
- * (aka Joel N. Chiappa)
+ * Copyright (c) 1982 Regents of the University of California.
+ * All rights reserved.  The Berkeley software License Agreement
+ * specifies the terms and conditions for redistribution.
+ *
+ *     @(#)if_vv.h     4.8 (Berkeley) %G%
  */
  */
+
+/*
+ * ECO 176-748 changed the braodcast address from 0 to 0xff, at
+ * CTL (p1002) serial number around 150.
+ * It was implemented in August, 1982. This is a field-installable ECO,
+ * which improves net reliability. If the broadcast address has not been
+ * changed, comment out the following line.
+ */
+#define        NEW_BROADCAST           /* new chip for broadcast problem */
+
+/*
+ * Local network header for proNET Ring
+ * This is arbitrated by "jas@proteon"
+ * (aka John Shriver, 617-655-3340)
+ */
+
 struct vv_header {
         /* the first two fields are required by the hardware */
        u_char  vh_dhost;       /* destination address */
 struct vv_header {
         /* the first two fields are required by the hardware */
        u_char  vh_dhost;       /* destination address */
@@ -14,26 +31,38 @@ struct vv_header {
        short   vh_info;        /* protocol-specific information */
 };
 
        short   vh_info;        /* protocol-specific information */
 };
 
-#define        RING_VERSION    1       /* current version of v2lni header */
+#define        RING_VERSION    2       /* current version of v2lni header */
 
 /*
 
 /*
- * Packet types (protocol numbers) in v2lni header
- *
- * NOTE: the Trailer format stuff is lifted right out of
- * the other drivers.  It will be changed to take advantage
- * of the fields in the vv_header, but the packet throw-away
- * code must first be improved.
+ * Packet types (protocol numbers) in proNET protocol header
+ * Other types are defined, but are proprietary.
  */
 #define        RING_IP         1
  */
 #define        RING_IP         1
-#define        RING_IPTrailer  2
-#define        RING_IPNTrailer 16
-#define        RING_WHOAMI     0xa5    /* insure some bit transitions */
+#define        RING_IPTrailer  2       /* really, 3 = 512 bytes */
+                               /*         4 = 1024 bytes */
+                               /*         5 = 1536 bytes */
+                               /* it's really very messed-up! */
+#define        RING_IPNTrailer 4       /* not a number, but a range */
+#define RING_ARP       3       /* the next three conflict with trailers */
+#define RING_HDLC      4
+#define RING_VAXDB     5
+#define RING_RINGWAY   6
+#define RING_RINGWAYM  8
+#define        RING_NOVELL     10
+#define RING_PUP       12
+#define RING_XNS       14
+#define        RING_DIAGNOSTICS 15     /* protocol type for testing */
+#define        RING_ECHO       16
 
 
-#define        VV_BROADCAST    0       /* hardware-defined broadcast address */
+#ifdef NEW_BROADCAST
+#define        VV_BROADCAST    0xff    /* hardware-defined broadcast address */
+#else
+#define        VV_BROADCAST    0x00    /* hardware-defined broadcast address */
+#endif
 
 /*
 
 /*
- * Proteon V2LNI Hardware definitions
- * register bit definitions - new style
+ * Proteon proNET Hardware definitions
+ * register bit definitions
  */
 #define        VV_ENB  01              /* Enable Operation */
 #define        VV_DEN  02              /* Enable DMA */
  */
 #define        VV_ENB  01              /* Enable Operation */
 #define        VV_DEN  02              /* Enable DMA */
@@ -50,9 +79,10 @@ struct vv_header {
 #define        VV_RFS  0400            /* Refused (Xmit) */
 #define        VV_NXM  01000           /* Non Existent Memory */
 #define        VV_OVR  02000           /* Overrun */
 #define        VV_RFS  0400            /* Refused (Xmit) */
 #define        VV_NXM  01000           /* Non Existent Memory */
 #define        VV_OVR  02000           /* Overrun */
-#define        VV_ODB  04000           /* Odd Byte (Achtung, mein Fuehrer) (Rcv) */
+#define        VV_ODB  04000           /* Odd Byte (Rcv) */
 #define        VV_UT2  04000           /* Unused (Xmit) */
 #define        VV_UT2  04000           /* Unused (Xmit) */
-#define        VV_LDE  010000          /* Link Data Error (Rcv) */
+#define        VV_LDE  010000          /* Parity on 10 megabit (Rcv), */
+                               /* Link Data Error on 80 megabit (Rcv) */
 #define        VV_OPT  010000          /* Output Timeout (Xmit) */
 #define        VV_NOK  020000          /* Ring Not OK */
 #define        VV_BDF  040000          /* Bad Format in Operation */
 #define        VV_OPT  010000          /* Output Timeout (Xmit) */
 #define        VV_NOK  020000          /* Ring Not OK */
 #define        VV_BDF  040000          /* Bad Format in Operation */
@@ -80,4 +110,7 @@ struct vvreg {
        u_short vvoea;          /* output addr hi */
 };
 
        u_short vvoea;          /* output addr hi */
 };
 
-#define        VVRETRY 7
+#define        VVRETRY 7               /* output retry limit */
+#define VVIDENTSUCC 5          /* number of successes required in self-test */
+#define VVIDENTRETRY 10                /* identify loop attempt limit */
+#define VVTIMEOUT 60           /* seconds before a transmit timeout */