1 /*
2  * This file is part of libtrace
3  *
4  * Copyright (c) 2007-2012 The University of Waikato, Hamilton,
5  * New Zealand.
6  *
7  * Authors: Daniel Lawson
8  *          Perry Lorier
9  *          Shane Alcock
10  *
11  * All rights reserved.
12  *
13  * This code has been developed by the University of Waikato WAND
14  * research group. For further information please see http://www.wand.net.nz/
15  *
16  * libtrace is free software; you can redistribute it and/or modify
17  * it under the terms of the GNU General Public License as published by
18  * the Free Software Foundation; either version 2 of the License, or
19  * (at your option) any later version.
20  *
21  * libtrace is distributed in the hope that it will be useful,
22  * but WITHOUT ANY WARRANTY; without even the implied warranty of
23  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
24  * GNU General Public License for more details.
25  *
26  * You should have received a copy of the GNU General Public License
27  * along with libtrace; if not, write to the Free Software
28  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
29  *
30  * $Id: libtrace_arphrd.h 1780 2012-12-04 02:24:34Z salcock $
31  *
32  */
33 
34 #ifndef LIBTRACE_ARPHRD_H_
35 #define LIBTRACE_ARPHRD_H_
36 
37 /* This is just a copy, paste and rename job from net/if_arp.h
38  *
39  * Unfortunately not all systems (MAC OS X!!) have all of the ARPHRD types
40  * defined in their version of net/if_arp.h so, as per usual, we have to
41  * include our own for portability.
42  */
43 
44 /* ARP protocol HARDWARE identifiers. */
45 #define LIBTRACE_ARPHRD_NETROM   0               /* From KA9Q: NET/ROM pseudo. */
46 #define LIBTRACE_ARPHRD_ETHER    1               /* Ethernet 10/100Mbps.  */
47 #define LIBTRACE_ARPHRD_EETHER   2               /* Experimental Ethernet.  */
48 #define LIBTRACE_ARPHRD_AX25     3               /* AX.25 Level 2.  */
49 #define LIBTRACE_ARPHRD_PRONET   4               /* PROnet token ring.  */
50 #define LIBTRACE_ARPHRD_CHAOS    5               /* Chaosnet.  */
51 #define LIBTRACE_ARPHRD_IEEE802  6               /* IEEE 802.2 Ethernet/TR/TB.  */
52 #define LIBTRACE_ARPHRD_ARCNET   7               /* ARCnet.  */
53 #define LIBTRACE_ARPHRD_APPLETLK 8               /* APPLEtalk.  */
54 #define LIBTRACE_ARPHRD_DLCI     15              /* Frame Relay DLCI.  */
55 #define LIBTRACE_ARPHRD_ATM      19              /* ATM.  */
56 #define LIBTRACE_ARPHRD_METRICOM 23              /* Metricom STRIP (new IANA id).  */
57 #define LIBTRACE_ARPHRD_IEEE1394 24              /* IEEE 1394 IPv4 - RFC 2734.  */
58 #define LIBTRACE_ARPHRD_EUI64            27              /* EUI-64.  */
59 #define LIBTRACE_ARPHRD_INFINIBAND       32              /* InfiniBand.  */
60 
61 /* Dummy types for non ARP hardware */
62 #define LIBTRACE_ARPHRD_SLIP     256
63 #define LIBTRACE_ARPHRD_CSLIP    257
64 #define LIBTRACE_ARPHRD_SLIP6    258
65 #define LIBTRACE_ARPHRD_CSLIP6   259
66 #define LIBTRACE_ARPHRD_RSRVD    260             /* Notional KISS type.  */
67 #define LIBTRACE_ARPHRD_ADAPT    264
68 #define LIBTRACE_ARPHRD_ROSE     270
69 #define LIBTRACE_ARPHRD_X25      271             /* CCITT X.25.  */
70 #define LIBTRACE_ARPHRD_HWX25    272             /* Boards with X.25 in firmware.  */
71 #define LIBTRACE_ARPHRD_PPP      512
72 #define LIBTRACE_ARPHRD_CISCO    513             /* Cisco HDLC.  */
73 #define LIBTRACE_ARPHRD_HDLC     LIBTRACE_ARPHRD_CISCO
74 #define LIBTRACE_ARPHRD_LAPB     516             /* LAPB.  */
75 #define LIBTRACE_ARPHRD_DDCMP    517             /* Digital's DDCMP.  */
76 #define LIBTRACE_ARPHRD_RAWHDLC  518             /* Raw HDLC.  */
77 #define LIBTRACE_ARPHRD_TUNNEL   768             /* IPIP tunnel.  */
78 #define LIBTRACE_ARPHRD_TUNNEL6  769             /* IPIP6 tunnel.  */
79 #define LIBTRACE_ARPHRD_FRAD     770             /* Frame Relay Access Device.  */
80 #define LIBTRACE_ARPHRD_SKIP     771             /* SKIP vif.  */
81 #define LIBTRACE_ARPHRD_LOOPBACK 772             /* Loopback device.  */
82 #define LIBTRACE_ARPHRD_LOCALTLK 773             /* Localtalk device.  */
83 #define LIBTRACE_ARPHRD_FDDI     774             /* Fiber Distributed Data Interface. */
84 #define LIBTRACE_ARPHRD_BIF      775             /* AP1000 BIF.  */
85 #define LIBTRACE_ARPHRD_SIT      776             /* sit0 device - IPv6-in-IPv4.  */
86 #define LIBTRACE_ARPHRD_IPDDP    777             /* IP-in-DDP tunnel.  */
87 #define LIBTRACE_ARPHRD_IPGRE    778             /* GRE over IP.  */
88 #define LIBTRACE_ARPHRD_PIMREG   779             /* PIMSM register interface.  */
89 #define LIBTRACE_ARPHRD_HIPPI    780             /* High Performance Parallel I'face. */
90 #define LIBTRACE_ARPHRD_ASH      781             /* (Nexus Electronics) Ash.  */
91 #define LIBTRACE_ARPHRD_ECONET   782             /* Acorn Econet.  */
92 #define LIBTRACE_ARPHRD_IRDA     783             /* Linux-IrDA.  */
93 #define LIBTRACE_ARPHRD_FCPP     784             /* Point to point fibrechanel.  */
94 #define LIBTRACE_ARPHRD_FCAL     785             /* Fibrechanel arbitrated loop.  */
95 #define LIBTRACE_ARPHRD_FCPL     786             /* Fibrechanel public loop.  */
96 #define LIBTRACE_ARPHRD_FCFABRIC 787             /* Fibrechanel fabric.  */
97 #define LIBTRACE_ARPHRD_IEEE802_TR 800           /* Magic type ident for TR.  */
98 #define LIBTRACE_ARPHRD_IEEE80211 801            /* IEEE 802.11.  */
99 #define LIBTRACE_ARPHRD_IEEE80211_PRISM 802      /* IEEE 802.11 + Prism2 header.  */
100 #define LIBTRACE_ARPHRD_IEEE80211_RADIOTAP 803   /* IEEE 802.11 + radiotap header.  */
101 #define LIBTRACE_ARPHRD_IEEE802154 804           /* IEEE 802.15.4 header.  */
102 #define LIBTRACE_ARPHRD_IEEE802154_PHY 805       /* IEEE 802.15.4 PHY header.  */
103 
104 #define LIBTRACE_ARPHRD_VOID       0xFFFF        /* Void type, nothing is known.  */
105 #define LIBTRACE_ARPHRD_NONE       0xFFFE        /* Zero header length.  */
106 
107 
108 #endif
109