Update to 2.6.37-rc8 headers
Use sanitized headers from 2.6.37-rc8
This commit is contained in:
parent
5c68fc88c5
commit
8552b387df
|
|
@ -75,6 +75,8 @@
|
|||
#define IFF_DISABLE_NETPOLL 0x2000 /* disable netpoll at run-time */
|
||||
#define IFF_MACVLAN_PORT 0x4000 /* device used as macvlan port */
|
||||
#define IFF_BRIDGE_PORT 0x8000 /* device used as bridge port */
|
||||
#define IFF_OVS_DATAPATH 0x10000 /* device used as Open vSwitch
|
||||
* datapath port */
|
||||
|
||||
#define IF_GET_IFACE 0x0001 /* for querying only */
|
||||
#define IF_GET_PROTO 0x0002
|
||||
|
|
|
|||
|
|
@ -66,6 +66,11 @@ struct xt_standard_target {
|
|||
int verdict;
|
||||
};
|
||||
|
||||
struct xt_error_target {
|
||||
struct xt_entry_target target;
|
||||
char errorname[XT_FUNCTION_MAXNAMELEN];
|
||||
};
|
||||
|
||||
/* The argument to IPT_SO_GET_REVISION_*. Returns highest revision
|
||||
* kernel supports, if >= revision. */
|
||||
struct xt_get_revision {
|
||||
|
|
|
|||
|
|
@ -27,6 +27,41 @@
|
|||
#define ipt_target xt_target
|
||||
#define ipt_table xt_table
|
||||
#define ipt_get_revision xt_get_revision
|
||||
#define ipt_entry_match xt_entry_match
|
||||
#define ipt_entry_target xt_entry_target
|
||||
#define ipt_standard_target xt_standard_target
|
||||
#define ipt_error_target xt_error_target
|
||||
#define ipt_counters xt_counters
|
||||
#define IPT_CONTINUE XT_CONTINUE
|
||||
#define IPT_RETURN XT_RETURN
|
||||
|
||||
/* This group is older than old (iptables < v1.4.0-rc1~89) */
|
||||
#include <linux/netfilter/xt_tcpudp.h>
|
||||
#define ipt_udp xt_udp
|
||||
#define ipt_tcp xt_tcp
|
||||
#define IPT_TCP_INV_SRCPT XT_TCP_INV_SRCPT
|
||||
#define IPT_TCP_INV_DSTPT XT_TCP_INV_DSTPT
|
||||
#define IPT_TCP_INV_FLAGS XT_TCP_INV_FLAGS
|
||||
#define IPT_TCP_INV_OPTION XT_TCP_INV_OPTION
|
||||
#define IPT_TCP_INV_MASK XT_TCP_INV_MASK
|
||||
#define IPT_UDP_INV_SRCPT XT_UDP_INV_SRCPT
|
||||
#define IPT_UDP_INV_DSTPT XT_UDP_INV_DSTPT
|
||||
#define IPT_UDP_INV_MASK XT_UDP_INV_MASK
|
||||
|
||||
/* The argument to IPT_SO_ADD_COUNTERS. */
|
||||
#define ipt_counters_info xt_counters_info
|
||||
/* Standard return verdict, or do jump. */
|
||||
#define IPT_STANDARD_TARGET XT_STANDARD_TARGET
|
||||
/* Error verdict. */
|
||||
#define IPT_ERROR_TARGET XT_ERROR_TARGET
|
||||
|
||||
/* fn returns 0 to continue iteration */
|
||||
#define IPT_MATCH_ITERATE(e, fn, args...) \
|
||||
XT_MATCH_ITERATE(struct ipt_entry, e, fn, ## args)
|
||||
|
||||
/* fn returns 0 to continue iteration */
|
||||
#define IPT_ENTRY_ITERATE(entries, size, fn, args...) \
|
||||
XT_ENTRY_ITERATE(struct ipt_entry, entries, size, fn, ## args)
|
||||
|
||||
/* Yes, Virginia, you have to zero the padding. */
|
||||
struct ipt_ip {
|
||||
|
|
@ -46,12 +81,6 @@ struct ipt_ip {
|
|||
u_int8_t invflags;
|
||||
};
|
||||
|
||||
#define ipt_entry_match xt_entry_match
|
||||
#define ipt_entry_target xt_entry_target
|
||||
#define ipt_standard_target xt_standard_target
|
||||
|
||||
#define ipt_counters xt_counters
|
||||
|
||||
/* Values for "flag" field in struct ipt_ip (general ip structure). */
|
||||
#define IPT_F_FRAG 0x01 /* Set if rule is a fragment rule */
|
||||
#define IPT_F_GOTO 0x02 /* Set if jump is a goto */
|
||||
|
|
@ -110,23 +139,6 @@ struct ipt_entry {
|
|||
#define IPT_SO_GET_REVISION_TARGET (IPT_BASE_CTL + 3)
|
||||
#define IPT_SO_GET_MAX IPT_SO_GET_REVISION_TARGET
|
||||
|
||||
#define IPT_CONTINUE XT_CONTINUE
|
||||
#define IPT_RETURN XT_RETURN
|
||||
|
||||
#include <linux/netfilter/xt_tcpudp.h>
|
||||
#define ipt_udp xt_udp
|
||||
#define ipt_tcp xt_tcp
|
||||
|
||||
#define IPT_TCP_INV_SRCPT XT_TCP_INV_SRCPT
|
||||
#define IPT_TCP_INV_DSTPT XT_TCP_INV_DSTPT
|
||||
#define IPT_TCP_INV_FLAGS XT_TCP_INV_FLAGS
|
||||
#define IPT_TCP_INV_OPTION XT_TCP_INV_OPTION
|
||||
#define IPT_TCP_INV_MASK XT_TCP_INV_MASK
|
||||
|
||||
#define IPT_UDP_INV_SRCPT XT_UDP_INV_SRCPT
|
||||
#define IPT_UDP_INV_DSTPT XT_UDP_INV_DSTPT
|
||||
#define IPT_UDP_INV_MASK XT_UDP_INV_MASK
|
||||
|
||||
/* ICMP matching stuff */
|
||||
struct ipt_icmp {
|
||||
u_int8_t type; /* type to match */
|
||||
|
|
@ -140,7 +152,7 @@ struct ipt_icmp {
|
|||
/* The argument to IPT_SO_GET_INFO */
|
||||
struct ipt_getinfo {
|
||||
/* Which table: caller fills this in. */
|
||||
char name[IPT_TABLE_MAXNAMELEN];
|
||||
char name[XT_TABLE_MAXNAMELEN];
|
||||
|
||||
/* Kernel fills these in. */
|
||||
/* Which hook entry points are valid: bitmask */
|
||||
|
|
@ -162,7 +174,7 @@ struct ipt_getinfo {
|
|||
/* The argument to IPT_SO_SET_REPLACE. */
|
||||
struct ipt_replace {
|
||||
/* Which table. */
|
||||
char name[IPT_TABLE_MAXNAMELEN];
|
||||
char name[XT_TABLE_MAXNAMELEN];
|
||||
|
||||
/* Which hook entry points are valid: bitmask. You can't
|
||||
change this. */
|
||||
|
|
@ -190,13 +202,10 @@ struct ipt_replace {
|
|||
struct ipt_entry entries[0];
|
||||
};
|
||||
|
||||
/* The argument to IPT_SO_ADD_COUNTERS. */
|
||||
#define ipt_counters_info xt_counters_info
|
||||
|
||||
/* The argument to IPT_SO_GET_ENTRIES. */
|
||||
struct ipt_get_entries {
|
||||
/* Which table: user fills this in. */
|
||||
char name[IPT_TABLE_MAXNAMELEN];
|
||||
char name[XT_TABLE_MAXNAMELEN];
|
||||
|
||||
/* User fills this in: total entry size. */
|
||||
unsigned int size;
|
||||
|
|
@ -205,26 +214,13 @@ struct ipt_get_entries {
|
|||
struct ipt_entry entrytable[0];
|
||||
};
|
||||
|
||||
/* Standard return verdict, or do jump. */
|
||||
#define IPT_STANDARD_TARGET XT_STANDARD_TARGET
|
||||
/* Error verdict. */
|
||||
#define IPT_ERROR_TARGET XT_ERROR_TARGET
|
||||
|
||||
/* Helper functions */
|
||||
static __inline__ struct ipt_entry_target *
|
||||
static __inline__ struct xt_entry_target *
|
||||
ipt_get_target(struct ipt_entry *e)
|
||||
{
|
||||
return (void *)e + e->target_offset;
|
||||
}
|
||||
|
||||
/* fn returns 0 to continue iteration */
|
||||
#define IPT_MATCH_ITERATE(e, fn, args...) \
|
||||
XT_MATCH_ITERATE(struct ipt_entry, e, fn, ## args)
|
||||
|
||||
/* fn returns 0 to continue iteration */
|
||||
#define IPT_ENTRY_ITERATE(entries, size, fn, args...) \
|
||||
XT_ENTRY_ITERATE(struct ipt_entry, entries, size, fn, ## args)
|
||||
|
||||
/*
|
||||
* Main firewall chains definitions and global var's definitions.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ struct nlmsghdr {
|
|||
Check NLM_F_EXCL
|
||||
*/
|
||||
|
||||
#define NLMSG_ALIGNTO 4
|
||||
#define NLMSG_ALIGNTO 4U
|
||||
#define NLMSG_ALIGN(len) ( ((len)+NLMSG_ALIGNTO-1) & ~(NLMSG_ALIGNTO-1) )
|
||||
#define NLMSG_HDRLEN ((int) NLMSG_ALIGN(sizeof(struct nlmsghdr)))
|
||||
#define NLMSG_LENGTH(len) ((len)+NLMSG_ALIGN(NLMSG_HDRLEN))
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ enum {
|
|||
TCF_META_ID_SK_SENDMSG_OFF,
|
||||
TCF_META_ID_SK_WRITE_PENDING,
|
||||
TCF_META_ID_VLAN_TAG,
|
||||
TCF_META_ID_RXHASH,
|
||||
__TCF_META_ID_MAX
|
||||
};
|
||||
#define TCF_META_ID_MAX (__TCF_META_ID_MAX - 1)
|
||||
|
|
|
|||
|
|
@ -34,7 +34,15 @@ typedef __u64 __bitwise __be64;
|
|||
typedef __u16 __bitwise __sum16;
|
||||
typedef __u32 __bitwise __wsum;
|
||||
|
||||
/* this is a special 64bit data type that is 8-byte aligned */
|
||||
/*
|
||||
* aligned_u64 should be used in defining kernel<->userspace ABIs to avoid
|
||||
* common 32/64-bit compat problems.
|
||||
* 64-bit values align to 4-byte boundaries on x86_32 (and possibly other
|
||||
* architectures) and to 8-byte boundaries on 64-bit architetures. The new
|
||||
* aligned_64 type enforces 8-byte alignment so that structs containing
|
||||
* aligned_64 values have the same alignment on 32-bit and 64-bit architectures.
|
||||
* No conversions are necessary between 32-bit user-space and a 64-bit kernel.
|
||||
*/
|
||||
#define __aligned_u64 __u64 __attribute__((aligned(8)))
|
||||
#define __aligned_be64 __be64 __attribute__((aligned(8)))
|
||||
#define __aligned_le64 __le64 __attribute__((aligned(8)))
|
||||
|
|
|
|||
Loading…
Reference in New Issue