141c99275SPeter Avalos /* 241c99275SPeter Avalos * Copyright (c) 1993, 1994, 1997 341c99275SPeter Avalos * The Regents of the University of California. All rights reserved. 441c99275SPeter Avalos * 541c99275SPeter Avalos * Redistribution and use in source and binary forms, with or without 641c99275SPeter Avalos * modification, are permitted provided that: (1) source code distributions 741c99275SPeter Avalos * retain the above copyright notice and this paragraph in its entirety, (2) 841c99275SPeter Avalos * distributions including binary code include the above copyright notice and 941c99275SPeter Avalos * this paragraph in its entirety in the documentation or other materials 1041c99275SPeter Avalos * provided with the distribution, and (3) all advertising materials mentioning 1141c99275SPeter Avalos * features or use of this software display the following acknowledgement: 1241c99275SPeter Avalos * ``This product includes software developed by the University of California, 1341c99275SPeter Avalos * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of 1441c99275SPeter Avalos * the University nor the names of its contributors may be used to endorse 1541c99275SPeter Avalos * or promote products derived from this software without specific prior 1641c99275SPeter Avalos * written permission. 1741c99275SPeter Avalos * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED 1841c99275SPeter Avalos * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF 1941c99275SPeter Avalos * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 2041c99275SPeter Avalos */ 2141c99275SPeter Avalos 2241c99275SPeter Avalos /* 2341c99275SPeter Avalos * Definitions for information in the LLC header. 2441c99275SPeter Avalos */ 2541c99275SPeter Avalos 2641c99275SPeter Avalos #define LLC_U_FMT 3 2741c99275SPeter Avalos #define LLC_GSAP 1 2841c99275SPeter Avalos #define LLC_IG 1 /* Individual / Group */ 2941c99275SPeter Avalos #define LLC_S_FMT 1 3041c99275SPeter Avalos 3141c99275SPeter Avalos #define LLC_U_POLL 0x10 3241c99275SPeter Avalos #define LLC_IS_POLL 0x0100 3341c99275SPeter Avalos #define LLC_XID_FI 0x81 3441c99275SPeter Avalos 3541c99275SPeter Avalos #define LLC_U_CMD(u) ((u) & 0xef) 3641c99275SPeter Avalos #define LLC_UI 0x03 3741c99275SPeter Avalos #define LLC_UA 0x63 3841c99275SPeter Avalos #define LLC_DISC 0x43 3941c99275SPeter Avalos #define LLC_DM 0x0f 4041c99275SPeter Avalos #define LLC_SABME 0x6f 4141c99275SPeter Avalos #define LLC_TEST 0xe3 4241c99275SPeter Avalos #define LLC_XID 0xaf 4341c99275SPeter Avalos #define LLC_FRMR 0x87 4441c99275SPeter Avalos 4541c99275SPeter Avalos #define LLC_S_CMD(is) (((is) >> 2) & 0x03) 4641c99275SPeter Avalos #define LLC_RR 0x0001 4741c99275SPeter Avalos #define LLC_RNR 0x0005 4841c99275SPeter Avalos #define LLC_REJ 0x0009 4941c99275SPeter Avalos 5041c99275SPeter Avalos #define LLC_IS_NR(is) (((is) >> 9) & 0x7f) 5141c99275SPeter Avalos #define LLC_I_NS(is) (((is) >> 1) & 0x7f) 5241c99275SPeter Avalos 5341c99275SPeter Avalos #ifndef LLCSAP_NULL 5441c99275SPeter Avalos #define LLCSAP_NULL 0x00 5541c99275SPeter Avalos #endif 5641c99275SPeter Avalos #ifndef LLCSAP_GLOBAL 5741c99275SPeter Avalos #define LLCSAP_GLOBAL 0xff 5841c99275SPeter Avalos #endif 5941c99275SPeter Avalos #ifndef LLCSAP_8021B_I 6041c99275SPeter Avalos #define LLCSAP_8021B_I 0x02 6141c99275SPeter Avalos #endif 6241c99275SPeter Avalos #ifndef LLCSAP_8021B_G 6341c99275SPeter Avalos #define LLCSAP_8021B_G 0x03 6441c99275SPeter Avalos #endif 6541c99275SPeter Avalos #ifndef LLCSAP_SNA 6641c99275SPeter Avalos #define LLCSAP_SNA 0x04 6741c99275SPeter Avalos #endif 6841c99275SPeter Avalos #ifndef LLCSAP_IP 6941c99275SPeter Avalos #define LLCSAP_IP 0x06 7041c99275SPeter Avalos #endif 7141c99275SPeter Avalos #ifndef LLCSAP_PROWAYNM 7241c99275SPeter Avalos #define LLCSAP_PROWAYNM 0x0e 7341c99275SPeter Avalos #endif 7441c99275SPeter Avalos #ifndef LLCSAP_8021D 7541c99275SPeter Avalos #define LLCSAP_8021D 0x42 7641c99275SPeter Avalos #endif 7741c99275SPeter Avalos #ifndef LLCSAP_RS511 7841c99275SPeter Avalos #define LLCSAP_RS511 0x4e 7941c99275SPeter Avalos #endif 8041c99275SPeter Avalos #ifndef LLCSAP_ISO8208 8141c99275SPeter Avalos #define LLCSAP_ISO8208 0x7e 8241c99275SPeter Avalos #endif 8341c99275SPeter Avalos #ifndef LLCSAP_PROWAY 8441c99275SPeter Avalos #define LLCSAP_PROWAY 0x8e 8541c99275SPeter Avalos #endif 8641c99275SPeter Avalos #ifndef LLCSAP_SNAP 8741c99275SPeter Avalos #define LLCSAP_SNAP 0xaa 8841c99275SPeter Avalos #endif 8941c99275SPeter Avalos #ifndef LLCSAP_IPX 9041c99275SPeter Avalos #define LLCSAP_IPX 0xe0 9141c99275SPeter Avalos #endif 9241c99275SPeter Avalos #ifndef LLCSAP_NETBEUI 9341c99275SPeter Avalos #define LLCSAP_NETBEUI 0xf0 9441c99275SPeter Avalos #endif 9541c99275SPeter Avalos #ifndef LLCSAP_ISONS 9641c99275SPeter Avalos #define LLCSAP_ISONS 0xfe 9741c99275SPeter Avalos #endif 9841c99275SPeter Avalos 9941c99275SPeter Avalos /* 10041c99275SPeter Avalos * PIDs for use with OUI_CISCO. 10141c99275SPeter Avalos */ 10241c99275SPeter Avalos #define PID_CISCO_CDP 0x2000 /* Cisco Discovery Protocol */ 10341c99275SPeter Avalos #define PID_CISCO_VTP 0x2003 /* Cisco VLAN Trunk Protocol */ 10441c99275SPeter Avalos #define PID_CISCO_DTP 0x2004 /* Cisco Dynamic Trunk Protocol */ 105ea7b4bf5SPeter Avalos #define PID_CISCO_UDLD 0x0111 /* Unidirectional Link Detection */ 106ea7b4bf5SPeter Avalos #define PID_CISCO_PVST 0x010b /* Per VLAN Spanning Tree+ and RPVST+ */ 107*411677aeSAaron LI #define PID_CISCO_VLANBRIDGE 0x010c /* "VLAN Bridge", according to Wireshark */ 10841c99275SPeter Avalos 10941c99275SPeter Avalos /* 11041c99275SPeter Avalos * PIDs for use with OUI_RFC2684. 11141c99275SPeter Avalos */ 11241c99275SPeter Avalos #define PID_RFC2684_ETH_FCS 0x0001 /* Ethernet, with FCS */ 11341c99275SPeter Avalos #define PID_RFC2684_ETH_NOFCS 0x0007 /* Ethernet, without FCS */ 11441c99275SPeter Avalos #define PID_RFC2684_802_4_FCS 0x0002 /* 802.4, with FCS */ 11541c99275SPeter Avalos #define PID_RFC2684_802_4_NOFCS 0x0008 /* 802.4, without FCS */ 11641c99275SPeter Avalos #define PID_RFC2684_802_5_FCS 0x0003 /* 802.5, with FCS */ 11741c99275SPeter Avalos #define PID_RFC2684_802_5_NOFCS 0x0009 /* 802.5, without FCS */ 11841c99275SPeter Avalos #define PID_RFC2684_FDDI_FCS 0x0004 /* FDDI, with FCS */ 11941c99275SPeter Avalos #define PID_RFC2684_FDDI_NOFCS 0x000a /* FDDI, without FCS */ 12041c99275SPeter Avalos #define PID_RFC2684_802_6_FCS 0x0005 /* 802.6, with FCS */ 12141c99275SPeter Avalos #define PID_RFC2684_802_6_NOFCS 0x000b /* 802.6, without FCS */ 12241c99275SPeter Avalos #define PID_RFC2684_BPDU 0x000e /* BPDUs */ 123