Skip to content

Commit

Permalink
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/gi…
Browse files Browse the repository at this point in the history
…t/kaber/nf-next-2.6
  • Loading branch information
David S. Miller committed May 11, 2010
2 parents 1ae5dc3 + b56f2d5 commit d250fe9
Show file tree
Hide file tree
Showing 154 changed files with 2,033 additions and 2,114 deletions.
2 changes: 1 addition & 1 deletion Documentation/Changes
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ o oprofile 0.9 # oprofiled --version
o udev 081 # udevinfo -V
o grub 0.93 # grub --version
o mcelog 0.6
o iptables 1.4.1 # iptables -V
o iptables 1.4.2 # iptables -V


Kernel compilation
Expand Down
18 changes: 8 additions & 10 deletions Documentation/feature-removal-schedule.txt
Original file line number Diff line number Diff line change
Expand Up @@ -241,16 +241,6 @@ Who: Thomas Gleixner <tglx@linutronix.de>

---------------------------

What (Why):
- xt_recent: the old ipt_recent proc dir
(superseded by /proc/net/xt_recent)

When: January 2009 or Linux 2.7.0, whichever comes first
Why: Superseded by newer revisions or modules
Who: Jan Engelhardt <jengelh@computergmbh.de>

---------------------------

What: GPIO autorequest on gpio_direction_{input,output}() in gpiolib
When: February 2010
Why: All callers should use explicit gpio_request()/gpio_free().
Expand Down Expand Up @@ -628,3 +618,11 @@ Why: Internal alias support has been present in module-init-tools for some
with no impact.

Who: Wey-Yi Guy <wey-yi.w.guy@intel.com>

---------------------------

What: xt_NOTRACK
Files: net/netfilter/xt_NOTRACK.c
When: April 2011
Why: Superseded by xt_CT
Who: Netfilter developer team <netfilter-devel@vger.kernel.org>
1 change: 1 addition & 0 deletions include/linux/ipv6.h
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,7 @@ struct inet6_skb_parm {

#define IP6SKB_XFRM_TRANSFORMED 1
#define IP6SKB_FORWARDED 2
#define IP6SKB_REROUTED 4
};

#define IP6CB(skb) ((struct inet6_skb_parm*)((skb)->cb))
Expand Down
6 changes: 4 additions & 2 deletions include/linux/kernel.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
/*
* 'kernel.h' contains some often-used function prototypes etc
*/
#define __ALIGN_KERNEL(x, a) __ALIGN_KERNEL_MASK(x, (typeof(x))(a) - 1)
#define __ALIGN_KERNEL_MASK(x, mask) (((x) + (mask)) & ~(mask))

#ifdef __KERNEL__

Expand Down Expand Up @@ -37,8 +39,8 @@ extern const char linux_proc_banner[];

#define STACK_MAGIC 0xdeadbeef

#define ALIGN(x,a) __ALIGN_MASK(x,(typeof(x))(a)-1)
#define __ALIGN_MASK(x,mask) (((x)+(mask))&~(mask))
#define ALIGN(x, a) __ALIGN_KERNEL((x), (a))
#define __ALIGN_MASK(x, mask) __ALIGN_KERNEL_MASK((x), (mask))
#define PTR_ALIGN(p, a) ((typeof(p))ALIGN((unsigned long)(p), (a)))
#define IS_ALIGNED(x, a) (((x) & ((typeof(x))(a) - 1)) == 0)

Expand Down
1 change: 1 addition & 0 deletions include/linux/netfilter/Kbuild
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ header-y += xt_RATEEST.h
header-y += xt_SECMARK.h
header-y += xt_TCPMSS.h
header-y += xt_TCPOPTSTRIP.h
header-y += xt_TEE.h
header-y += xt_TPROXY.h
header-y += xt_comment.h
header-y += xt_connbytes.h
Expand Down
1 change: 1 addition & 0 deletions include/linux/netfilter/nf_conntrack_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ struct ip_conntrack_stat {
unsigned int expect_new;
unsigned int expect_create;
unsigned int expect_delete;
unsigned int search_restart;
};

/* call to create an explicit dependency on nf_conntrack. */
Expand Down
3 changes: 1 addition & 2 deletions include/linux/netfilter/nf_conntrack_tuple_common.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
#ifndef _NF_CONNTRACK_TUPLE_COMMON_H
#define _NF_CONNTRACK_TUPLE_COMMON_H

enum ip_conntrack_dir
{
enum ip_conntrack_dir {
IP_CT_DIR_ORIGINAL,
IP_CT_DIR_REPLY,
IP_CT_DIR_MAX
Expand Down
50 changes: 30 additions & 20 deletions include/linux/netfilter/x_tables.h
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#ifndef _X_TABLES_H
#define _X_TABLES_H

#include <linux/kernel.h>
#include <linux/types.h>

#define XT_FUNCTION_MAXNAMELEN 30
#define XT_EXTENSION_MAXNAMELEN 29
#define XT_TABLE_MAXNAMELEN 32

struct xt_entry_match {
Expand All @@ -12,8 +13,7 @@ struct xt_entry_match {
__u16 match_size;

/* Used by userspace */
char name[XT_FUNCTION_MAXNAMELEN-1];

char name[XT_EXTENSION_MAXNAMELEN];
__u8 revision;
} user;
struct {
Expand All @@ -36,8 +36,7 @@ struct xt_entry_target {
__u16 target_size;

/* Used by userspace */
char name[XT_FUNCTION_MAXNAMELEN-1];

char name[XT_EXTENSION_MAXNAMELEN];
__u8 revision;
} user;
struct {
Expand Down Expand Up @@ -70,8 +69,7 @@ struct xt_standard_target {
/* The argument to IPT_SO_GET_REVISION_*. Returns highest revision
* kernel supports, if >= revision. */
struct xt_get_revision {
char name[XT_FUNCTION_MAXNAMELEN-1];

char name[XT_EXTENSION_MAXNAMELEN];
__u8 revision;
};

Expand All @@ -93,7 +91,7 @@ struct _xt_align {
__u64 u64;
};

#define XT_ALIGN(s) ALIGN((s), __alignof__(struct _xt_align))
#define XT_ALIGN(s) __ALIGN_KERNEL((s), __alignof__(struct _xt_align))

/* Standard return verdict, or do jump. */
#define XT_STANDARD_TARGET ""
Expand Down Expand Up @@ -197,6 +195,7 @@ struct xt_counters_info {
* @family: Actual NFPROTO_* through which the function is invoked
* (helpful when match->family == NFPROTO_UNSPEC)
* @hotdrop: drop packet if we had inspection problems
* Network namespace obtainable using dev_net(in/out)
*/
struct xt_match_param {
const struct net_device *in, *out;
Expand All @@ -213,12 +212,14 @@ struct xt_match_param {
* struct xt_mtchk_param - parameters for match extensions'
* checkentry functions
*
* @net: network namespace through which the check was invoked
* @table: table the rule is tried to be inserted into
* @entryinfo: the family-specific rule data
* (struct ipt_ip, ip6t_ip, ebt_entry)
* (struct ipt_ip, ip6t_ip, arpt_arp or (note) ebt_entry)
* @match: struct xt_match through which this function was invoked
* @matchinfo: per-match data
* @hook_mask: via which hooks the new rule is reachable
* Other fields as above.
*/
struct xt_mtchk_param {
struct net *net;
Expand All @@ -230,7 +231,10 @@ struct xt_mtchk_param {
u_int8_t family;
};

/* Match destructor parameters */
/**
* struct xt_mdtor_param - match destructor parameters
* Fields as above.
*/
struct xt_mtdtor_param {
struct net *net;
const struct xt_match *match;
Expand Down Expand Up @@ -285,7 +289,7 @@ struct xt_tgdtor_param {
struct xt_match {
struct list_head list;

const char name[XT_FUNCTION_MAXNAMELEN-1];
const char name[XT_EXTENSION_MAXNAMELEN];
u_int8_t revision;

/* Return true or false: return FALSE and set *hotdrop = 1 to
Expand All @@ -297,7 +301,7 @@ struct xt_match {
const struct xt_match_param *);

/* Called when user tries to insert an entry of this type. */
bool (*checkentry)(const struct xt_mtchk_param *);
int (*checkentry)(const struct xt_mtchk_param *);

/* Called when entry of this type deleted. */
void (*destroy)(const struct xt_mtdtor_param *);
Expand All @@ -309,9 +313,6 @@ struct xt_match {
/* Set this to THIS_MODULE if you are a module, otherwise NULL */
struct module *me;

/* Free to use by each match */
unsigned long data;

const char *table;
unsigned int matchsize;
#ifdef CONFIG_COMPAT
Expand All @@ -327,7 +328,8 @@ struct xt_match {
struct xt_target {
struct list_head list;

const char name[XT_FUNCTION_MAXNAMELEN-1];
const char name[XT_EXTENSION_MAXNAMELEN];
u_int8_t revision;

/* Returns verdict. Argument order changed since 2.6.9, as this
must now handle non-linear skbs, using skb_copy_bits and
Expand All @@ -338,8 +340,8 @@ struct xt_target {
/* Called when user tries to insert an entry of this type:
hook_mask is a bitmask of hooks from which it can be
called. */
/* Should return true or false. */
bool (*checkentry)(const struct xt_tgchk_param *);
/* Should return true or false, or an error code (-Exxxx). */
int (*checkentry)(const struct xt_tgchk_param *);

/* Called when entry of this type deleted. */
void (*destroy)(const struct xt_tgdtor_param *);
Expand All @@ -360,7 +362,6 @@ struct xt_target {
unsigned short proto;

unsigned short family;
u_int8_t revision;
};

/* Furniture shopping... */
Expand Down Expand Up @@ -398,6 +399,13 @@ struct xt_table_info {
unsigned int hook_entry[NF_INET_NUMHOOKS];
unsigned int underflow[NF_INET_NUMHOOKS];

/*
* Number of user chains. Since tables cannot have loops, at most
* @stacksize jumps (number of user chains) can possibly be made.
*/
unsigned int stacksize;
unsigned int *stackptr;
void ***jumpstack;
/* ipt_entry tables: one per CPU */
/* Note : this field MUST be the last one, see XT_TABLE_INFO_SZ */
void *entries[1];
Expand Down Expand Up @@ -433,6 +441,8 @@ extern struct xt_table_info *xt_replace_table(struct xt_table *table,

extern struct xt_match *xt_find_match(u8 af, const char *name, u8 revision);
extern struct xt_target *xt_find_target(u8 af, const char *name, u8 revision);
extern struct xt_match *xt_request_find_match(u8 af, const char *name,
u8 revision);
extern struct xt_target *xt_request_find_target(u8 af, const char *name,
u8 revision);
extern int xt_find_revision(u8 af, const char *name, u8 revision,
Expand Down Expand Up @@ -598,7 +608,7 @@ struct _compat_xt_align {
compat_u64 u64;
};

#define COMPAT_XT_ALIGN(s) ALIGN((s), __alignof__(struct _compat_xt_align))
#define COMPAT_XT_ALIGN(s) __ALIGN_KERNEL((s), __alignof__(struct _compat_xt_align))

extern void xt_compat_lock(u_int8_t af);
extern void xt_compat_unlock(u_int8_t af);
Expand Down
22 changes: 1 addition & 21 deletions include/linux/netfilter/xt_CONNMARK.h
Original file line number Diff line number Diff line change
@@ -1,26 +1,6 @@
#ifndef _XT_CONNMARK_H_target
#define _XT_CONNMARK_H_target

#include <linux/types.h>

/* Copyright (C) 2002,2004 MARA Systems AB <http://www.marasystems.com>
* by Henrik Nordstrom <hno@marasystems.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/

enum {
XT_CONNMARK_SET = 0,
XT_CONNMARK_SAVE,
XT_CONNMARK_RESTORE
};

struct xt_connmark_tginfo1 {
__u32 ctmark, ctmask, nfmask;
__u8 mode;
};
#include <linux/netfilter/xt_connmark.h>

#endif /*_XT_CONNMARK_H_target*/
6 changes: 1 addition & 5 deletions include/linux/netfilter/xt_MARK.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
#ifndef _XT_MARK_H_target
#define _XT_MARK_H_target

#include <linux/types.h>

struct xt_mark_tginfo2 {
__u32 mark, mask;
};
#include <linux/netfilter/xt_mark.h>

#endif /*_XT_MARK_H_target */
12 changes: 12 additions & 0 deletions include/linux/netfilter/xt_TEE.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#ifndef _XT_TEE_TARGET_H
#define _XT_TEE_TARGET_H

struct xt_tee_tginfo {
union nf_inet_addr gw;
char oif[16];

/* used internally by the kernel */
struct xt_tee_priv *priv __attribute__((aligned(8)));
};

#endif /* _XT_TEE_TARGET_H */
11 changes: 11 additions & 0 deletions include/linux/netfilter/xt_connmark.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,17 @@
* (at your option) any later version.
*/

enum {
XT_CONNMARK_SET = 0,
XT_CONNMARK_SAVE,
XT_CONNMARK_RESTORE
};

struct xt_connmark_tginfo1 {
__u32 ctmark, ctmask, nfmask;
__u8 mode;
};

struct xt_connmark_mtinfo1 {
__u32 mark, mask;
__u8 invert;
Expand Down
4 changes: 4 additions & 0 deletions include/linux/netfilter/xt_mark.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

#include <linux/types.h>

struct xt_mark_tginfo2 {
__u32 mark, mask;
};

struct xt_mark_mtinfo1 {
__u32 mark, mask;
__u8 invert;
Expand Down
7 changes: 7 additions & 0 deletions include/linux/netfilter/xt_recent.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,20 @@ enum {
XT_RECENT_UPDATE = 1 << 2,
XT_RECENT_REMOVE = 1 << 3,
XT_RECENT_TTL = 1 << 4,
XT_RECENT_REAP = 1 << 5,

XT_RECENT_SOURCE = 0,
XT_RECENT_DEST = 1,

XT_RECENT_NAME_LEN = 200,
};

/* Only allowed with --rcheck and --update */
#define XT_RECENT_MODIFIERS (XT_RECENT_TTL|XT_RECENT_REAP)

#define XT_RECENT_VALID_FLAGS (XT_RECENT_CHECK|XT_RECENT_SET|XT_RECENT_UPDATE|\
XT_RECENT_REMOVE|XT_RECENT_TTL|XT_RECENT_REAP)

struct xt_recent_mtinfo {
__u32 seconds;
__u32 hit_count;
Expand Down
Loading

0 comments on commit d250fe9

Please sign in to comment.