]>
git.saurik.com Git - apple/xnu.git/blob - bsd/netat/at_pat.h
2 * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved.
8 * This file contains Original Code and/or Modifications of Original Code
9 * as defined in and that are subject to the Apple Public Source License
10 * Version 2.0 (the 'License'). You may not use this file except in
11 * compliance with the License. Please obtain a copy of the License at
12 * http://www.opensource.apple.com/apsl/ and read it before using this
15 * The Original Code and all software distributed under the License are
16 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
17 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
18 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
20 * Please see the License for the specific language governing rights and
21 * limitations under the License.
23 * @APPLE_LICENSE_HEADER_END@
27 * Copyright (c) 1988, 1989 Apple Computer, Inc.
30 #ifndef _NETAT_AT_PAT_H_
31 #define _NETAT_AT_PAT_H_
32 #include <sys/appleapiopts.h>
34 /* This is header for the PAT module. This contains a table of pointers that
35 * should get initialized with the BNET stuff and the ethernet driver. The
36 * number of interfaces supported should be communicated. Should include
37 * mbuf.h, if.h, socket.h
39 * Author: R. C. Venkatraman
50 unsigned char dst_sap
;
51 unsigned char src_sap
;
52 unsigned char control
;
53 unsigned char protocol
[5];
56 #define ENET_LLC_SIZE (sizeof(enet_header_t)+sizeof(llc_header_t))
57 #define SNAP_UI 0x03 /* bits 11000000 reversed!! */
58 #define SNAP_AT_SAP 0xaa
59 #define SNAP_PROTO_AT {0x08, 0x00, 0x07, 0x80, 0x9B}
60 #define SNAP_PROTO_AARP {0x00, 0x00, 0x00, 0x80, 0xF3}
61 #define SNAP_HDR_AT {SNAP_AT_SAP, SNAP_AT_SAP, SNAP_UI, SNAP_PROTO_AT}
62 #define SNAP_HDR_AARP {SNAP_AT_SAP, SNAP_AT_SAP, SNAP_UI, SNAP_PROTO_AARP}
64 #define LLC_PROTO_EQUAL(a1, a2) \
65 ((*((unsigned long *)(a1)) == *((unsigned long *)(a2))) && \
68 #endif /* _NETAT_AT_PAT_H_ */