10f74e101Schristos /* 20f74e101Schristos * Copyright (c) 1993, 1994, 1997 30f74e101Schristos * The Regents of the University of California. All rights reserved. 40f74e101Schristos * 50f74e101Schristos * Redistribution and use in source and binary forms, with or without 60f74e101Schristos * modification, are permitted provided that: (1) source code distributions 70f74e101Schristos * retain the above copyright notice and this paragraph in its entirety, (2) 80f74e101Schristos * distributions including binary code include the above copyright notice and 90f74e101Schristos * this paragraph in its entirety in the documentation or other materials 100f74e101Schristos * provided with the distribution, and (3) all advertising materials mentioning 110f74e101Schristos * features or use of this software display the following acknowledgement: 120f74e101Schristos * ``This product includes software developed by the University of California, 130f74e101Schristos * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of 140f74e101Schristos * the University nor the names of its contributors may be used to endorse 150f74e101Schristos * or promote products derived from this software without specific prior 160f74e101Schristos * written permission. 170f74e101Schristos * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED 180f74e101Schristos * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF 190f74e101Schristos * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 200f74e101Schristos */ 210f74e101Schristos 220f74e101Schristos /* 230f74e101Schristos * Definitions for information in the LLC header. 240f74e101Schristos */ 250f74e101Schristos 260f74e101Schristos #define LLC_U_FMT 3 270f74e101Schristos #define LLC_GSAP 1 280f74e101Schristos #define LLC_IG 1 /* Individual / Group */ 290f74e101Schristos #define LLC_S_FMT 1 300f74e101Schristos 310f74e101Schristos #define LLC_U_POLL 0x10 320f74e101Schristos #define LLC_IS_POLL 0x0100 330f74e101Schristos #define LLC_XID_FI 0x81 340f74e101Schristos 350f74e101Schristos #define LLC_U_CMD(u) ((u) & 0xef) 360f74e101Schristos #define LLC_UI 0x03 370f74e101Schristos #define LLC_UA 0x63 380f74e101Schristos #define LLC_DISC 0x43 390f74e101Schristos #define LLC_DM 0x0f 400f74e101Schristos #define LLC_SABME 0x6f 410f74e101Schristos #define LLC_TEST 0xe3 420f74e101Schristos #define LLC_XID 0xaf 430f74e101Schristos #define LLC_FRMR 0x87 440f74e101Schristos 450f74e101Schristos #define LLC_S_CMD(is) (((is) >> 2) & 0x03) 460f74e101Schristos #define LLC_RR 0x0001 470f74e101Schristos #define LLC_RNR 0x0005 480f74e101Schristos #define LLC_REJ 0x0009 490f74e101Schristos 500f74e101Schristos #define LLC_IS_NR(is) (((is) >> 9) & 0x7f) 510f74e101Schristos #define LLC_I_NS(is) (((is) >> 1) & 0x7f) 520f74e101Schristos 530f74e101Schristos #ifndef LLCSAP_NULL 540f74e101Schristos #define LLCSAP_NULL 0x00 550f74e101Schristos #endif 560f74e101Schristos #ifndef LLCSAP_GLOBAL 570f74e101Schristos #define LLCSAP_GLOBAL 0xff 580f74e101Schristos #endif 590f74e101Schristos #ifndef LLCSAP_8021B_I 600f74e101Schristos #define LLCSAP_8021B_I 0x02 610f74e101Schristos #endif 620f74e101Schristos #ifndef LLCSAP_8021B_G 630f74e101Schristos #define LLCSAP_8021B_G 0x03 640f74e101Schristos #endif 650f74e101Schristos #ifndef LLCSAP_SNA 660f74e101Schristos #define LLCSAP_SNA 0x04 670f74e101Schristos #endif 680f74e101Schristos #ifndef LLCSAP_IP 690f74e101Schristos #define LLCSAP_IP 0x06 700f74e101Schristos #endif 710f74e101Schristos #ifndef LLCSAP_PROWAYNM 720f74e101Schristos #define LLCSAP_PROWAYNM 0x0e 730f74e101Schristos #endif 740f74e101Schristos #ifndef LLCSAP_8021D 750f74e101Schristos #define LLCSAP_8021D 0x42 760f74e101Schristos #endif 770f74e101Schristos #ifndef LLCSAP_RS511 780f74e101Schristos #define LLCSAP_RS511 0x4e 790f74e101Schristos #endif 800f74e101Schristos #ifndef LLCSAP_ISO8208 810f74e101Schristos #define LLCSAP_ISO8208 0x7e 820f74e101Schristos #endif 830f74e101Schristos #ifndef LLCSAP_PROWAY 840f74e101Schristos #define LLCSAP_PROWAY 0x8e 850f74e101Schristos #endif 860f74e101Schristos #ifndef LLCSAP_SNAP 870f74e101Schristos #define LLCSAP_SNAP 0xaa 880f74e101Schristos #endif 890f74e101Schristos #ifndef LLCSAP_IPX 900f74e101Schristos #define LLCSAP_IPX 0xe0 910f74e101Schristos #endif 920f74e101Schristos #ifndef LLCSAP_NETBEUI 930f74e101Schristos #define LLCSAP_NETBEUI 0xf0 940f74e101Schristos #endif 950f74e101Schristos #ifndef LLCSAP_ISONS 960f74e101Schristos #define LLCSAP_ISONS 0xfe 970f74e101Schristos #endif 980f74e101Schristos 990f74e101Schristos /* 1000f74e101Schristos * PIDs for use with OUI_CISCO. 1010f74e101Schristos */ 1020f74e101Schristos #define PID_CISCO_CDP 0x2000 /* Cisco Discovery Protocol */ 1030f74e101Schristos #define PID_CISCO_VTP 0x2003 /* Cisco VLAN Trunk Protocol */ 1040f74e101Schristos #define PID_CISCO_DTP 0x2004 /* Cisco Dynamic Trunk Protocol */ 1050f74e101Schristos #define PID_CISCO_UDLD 0x0111 /* Unidirectional Link Detection */ 1060f74e101Schristos #define PID_CISCO_PVST 0x010b /* Per VLAN Spanning Tree+ and RPVST+ */ 107*026d7285Schristos #define PID_CISCO_VLANBRIDGE 0x010c /* "VLAN Bridge", according to Wireshark */ 1080f74e101Schristos 1090f74e101Schristos /* 1100f74e101Schristos * PIDs for use with OUI_RFC2684. 1110f74e101Schristos */ 1120f74e101Schristos #define PID_RFC2684_ETH_FCS 0x0001 /* Ethernet, with FCS */ 1130f74e101Schristos #define PID_RFC2684_ETH_NOFCS 0x0007 /* Ethernet, without FCS */ 1140f74e101Schristos #define PID_RFC2684_802_4_FCS 0x0002 /* 802.4, with FCS */ 1150f74e101Schristos #define PID_RFC2684_802_4_NOFCS 0x0008 /* 802.4, without FCS */ 1160f74e101Schristos #define PID_RFC2684_802_5_FCS 0x0003 /* 802.5, with FCS */ 1170f74e101Schristos #define PID_RFC2684_802_5_NOFCS 0x0009 /* 802.5, without FCS */ 1180f74e101Schristos #define PID_RFC2684_FDDI_FCS 0x0004 /* FDDI, with FCS */ 1190f74e101Schristos #define PID_RFC2684_FDDI_NOFCS 0x000a /* FDDI, without FCS */ 1200f74e101Schristos #define PID_RFC2684_802_6_FCS 0x0005 /* 802.6, with FCS */ 1210f74e101Schristos #define PID_RFC2684_802_6_NOFCS 0x000b /* 802.6, without FCS */ 1220f74e101Schristos #define PID_RFC2684_BPDU 0x000e /* BPDUs */ 123