spi-topcliff-pch: Fix issue for transmitting over 4KByte
[zen-stable.git] / include / linux / netfilter / xt_policy.h
blobbe8ead05c3164a7ae258ee1b4b7f4e25dc82d183
1 #ifndef _XT_POLICY_H
2 #define _XT_POLICY_H
4 #include <linux/types.h>
6 #define XT_POLICY_MAX_ELEM 4
8 enum xt_policy_flags {
9 XT_POLICY_MATCH_IN = 0x1,
10 XT_POLICY_MATCH_OUT = 0x2,
11 XT_POLICY_MATCH_NONE = 0x4,
12 XT_POLICY_MATCH_STRICT = 0x8,
15 enum xt_policy_modes {
16 XT_POLICY_MODE_TRANSPORT,
17 XT_POLICY_MODE_TUNNEL
20 struct xt_policy_spec {
21 __u8 saddr:1,
22 daddr:1,
23 proto:1,
24 mode:1,
25 spi:1,
26 reqid:1;
29 #ifndef __KERNEL__
30 union xt_policy_addr {
31 struct in_addr a4;
32 struct in6_addr a6;
34 #endif
36 struct xt_policy_elem {
37 union {
38 #ifdef __KERNEL__
39 struct {
40 union nf_inet_addr saddr;
41 union nf_inet_addr smask;
42 union nf_inet_addr daddr;
43 union nf_inet_addr dmask;
45 #else
46 struct {
47 union xt_policy_addr saddr;
48 union xt_policy_addr smask;
49 union xt_policy_addr daddr;
50 union xt_policy_addr dmask;
52 #endif
54 __be32 spi;
55 __u32 reqid;
56 __u8 proto;
57 __u8 mode;
59 struct xt_policy_spec match;
60 struct xt_policy_spec invert;
63 struct xt_policy_info {
64 struct xt_policy_elem pol[XT_POLICY_MAX_ELEM];
65 __u16 flags;
66 __u16 len;
69 #endif /* _XT_POLICY_H */