Dr Andrew Scott G7VAV

My photo
 
June 2025
Mo Tu We Th Fr Sa Su
26 27 28 29 30 31 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 1 2 3 4 5 6


ebt_802_3.h
01: #ifndef __LINUX_BRIDGE_EBT_802_3_H
02: #define __LINUX_BRIDGE_EBT_802_3_H
03: 
04: #include <linux/types.h>
05: 
06: #define EBT_802_3_SAP 0x01
07: #define EBT_802_3_TYPE 0x02
08: 
09: #define EBT_802_3_MATCH "802_3"
10: 
11: /*
12:  * If frame has DSAP/SSAP value 0xaa you must check the SNAP type
13:  * to discover what kind of packet we're carrying. 
14:  */
15: #define CHECK_TYPE 0xaa
16: 
17: /*
18:  * Control field may be one or two bytes.  If the first byte has
19:  * the value 0x03 then the entire length is one byte, otherwise it is two.
20:  * One byte controls are used in Unnumbered Information frames.
21:  * Two byte controls are used in Numbered Information frames.
22:  */
23: #define IS_UI 0x03
24: 
25: #define EBT_802_3_MASK (EBT_802_3_SAP | EBT_802_3_TYPE | EBT_802_3)
26: 
27: /* ui has one byte ctrl, ni has two */
28: struct hdr_ui {
29:         __u8 dsap;
30:         __u8 ssap;
31:         __u8 ctrl;
32:         __u8 orig[3];
33:         __be16 type;
34: };
35: 
36: struct hdr_ni {
37:         __u8 dsap;
38:         __u8 ssap;
39:         __be16 ctrl;
40:         __u8  orig[3];
41:         __be16 type;
42: };
43: 
44: struct ebt_802_3_hdr {
45:         __u8  daddr[6];
46:         __u8  saddr[6];
47:         __be16 len;
48:         union {
49:                 struct hdr_ui ui;
50:                 struct hdr_ni ni;
51:         } llc;
52: };
53: 
54: 
55: struct ebt_802_3_info {
56:         __u8  sap;
57:         __be16 type;
58:         __u8  bitmask;
59:         __u8  invflags;
60: };
61: 
62: #endif
63: 


for client (none)
© Andrew Scott 2006 - 2025,
All Rights Reserved
http://www.andrew-scott.uk/
Andrew Scott
http://www.andrew-scott.co.uk/