summaryrefslogtreecommitdiffstats
path: root/sys/net/if_atm.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/net/if_atm.h')
-rw-r--r--sys/net/if_atm.h60
1 files changed, 60 insertions, 0 deletions
diff --git a/sys/net/if_atm.h b/sys/net/if_atm.h
index b8a34a8..98f3b3b 100644
--- a/sys/net/if_atm.h
+++ b/sys/net/if_atm.h
@@ -37,6 +37,66 @@
* net/if_atm.h
*/
+/*
+ * Classification of ATM cards.
+ */
+#define ATM_DEVICE_UNKNOWN 0
+#define ATM_DEVICE_PCA200E 1 /* Fore/Marconi PCA200-E */
+#define ATM_DEVICE_HE155 2 /* Fore/Marconi HE155 */
+#define ATM_DEVICE_HE622 3 /* Fore/Marconi HE622 */
+#define ATM_DEVICE_ENI155P 4 /* Efficient networks 155p */
+#define ATM_DEVICE_ADP155P 5 /* Adaptec 155p */
+
+/* map to strings and vendors */
+#define ATM_DEVICE_NAMES \
+ { "Unknown", "Unknown" }, \
+ { "PCA200-E", "Fore/Marconi" }, \
+ { "HE155", "Fore/Marconi" }, \
+ { "HE622", "Fore/Marconi" }, \
+ { "ENI155p", "Efficient Networks" }, \
+ { "ADP155p", "Adaptec" },
+
+/*
+ * This is the common link layer MIB for all ATM interfaces. Much of the
+ * information here is needed for ILMI. This will be augmented by statistics
+ * at some point.
+ */
+struct ifatm_mib {
+ /* configuration data */
+ uint8_t device; /* type of card */
+ u_char esi[6]; /* end system identifier (MAC) */
+ uint32_t serial; /* card serial number */
+ uint32_t hw_version; /* card version */
+ uint32_t sw_version; /* firmware version (if any) */
+ uint32_t pcr; /* supported peak cell rate */
+ uint32_t media; /* physical media */
+ uint8_t vpi_bits; /* number of used bits in VPI field */
+ uint8_t vci_bits; /* number of used bits in VCI field */
+ uint16_t max_vpcs; /* maximum number of VPCs */
+ uint32_t max_vccs; /* maximum number of VCCs */
+};
+
+#ifdef _KERNEL
+/*
+ * Common fields for all ATM interfaces. Each driver's softc must start with
+ * this structure.
+ */
+struct ifatm {
+ struct ifnet ifnet; /* required by if_var.h */
+ struct ifatm_mib mib; /* exported data */
+ void *phy; /* usually SUNI */
+ void *ngpriv; /* netgraph link */
+};
+#endif
+
+/*
+ * Peak cell rates for various physical media. Note, that there are
+ * different opinions on what the correct values are.
+ */
+#define ATM_RATE_155M 353208
+#define ATM_RATE_622M 1412830
+#define ATM_RATE_24G 5651320
+
#if defined(__NetBSD__) || defined(__OpenBSD__) || defined(__bsdi__)
#define RTALLOC1(A,B) rtalloc1((A),(B))
#elif defined(__FreeBSD__)
OpenPOWER on IntegriCloud