aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2006-08-22 03:35:47 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2006-09-22 17:55:33 -0400
commitfe1cb10873b44cf89082465823ee6d4d4ac63ad7 (patch)
tree0176a23fb45e7e45182e5b852a08c6ab16db2015 /net/ipv4
parent4470bbc749e5551cce914529309456f631e25120 (diff)
[NETFILTER]: x_tables: remove unused argument to target functions
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r--net/ipv4/netfilter/arp_tables.c9
-rw-r--r--net/ipv4/netfilter/arpt_mangle.c2
-rw-r--r--net/ipv4/netfilter/arptable_filter.c2
-rw-r--r--net/ipv4/netfilter/ip_nat_rule.c8
-rw-r--r--net/ipv4/netfilter/ip_tables.c9
-rw-r--r--net/ipv4/netfilter/ipt_CLUSTERIP.c3
-rw-r--r--net/ipv4/netfilter/ipt_ECN.c3
-rw-r--r--net/ipv4/netfilter/ipt_LOG.c3
-rw-r--r--net/ipv4/netfilter/ipt_MASQUERADE.c3
-rw-r--r--net/ipv4/netfilter/ipt_NETMAP.c3
-rw-r--r--net/ipv4/netfilter/ipt_REDIRECT.c3
-rw-r--r--net/ipv4/netfilter/ipt_REJECT.c3
-rw-r--r--net/ipv4/netfilter/ipt_SAME.c3
-rw-r--r--net/ipv4/netfilter/ipt_TCPMSS.c3
-rw-r--r--net/ipv4/netfilter/ipt_TOS.c3
-rw-r--r--net/ipv4/netfilter/ipt_TTL.c2
-rw-r--r--net/ipv4/netfilter/ipt_ULOG.c2
-rw-r--r--net/ipv4/netfilter/iptable_filter.c4
-rw-r--r--net/ipv4/netfilter/iptable_mangle.c4
-rw-r--r--net/ipv4/netfilter/iptable_raw.c2
20 files changed, 28 insertions, 46 deletions
diff --git a/net/ipv4/netfilter/arp_tables.c b/net/ipv4/netfilter/arp_tables.c
index 8d1d7a6e72a5..c6bd270bf46a 100644
--- a/net/ipv4/netfilter/arp_tables.c
+++ b/net/ipv4/netfilter/arp_tables.c
@@ -208,8 +208,7 @@ static unsigned int arpt_error(struct sk_buff **pskb,
208 const struct net_device *out, 208 const struct net_device *out,
209 unsigned int hooknum, 209 unsigned int hooknum,
210 const struct xt_target *target, 210 const struct xt_target *target,
211 const void *targinfo, 211 const void *targinfo)
212 void *userinfo)
213{ 212{
214 if (net_ratelimit()) 213 if (net_ratelimit())
215 printk("arp_tables: error: '%s'\n", (char *)targinfo); 214 printk("arp_tables: error: '%s'\n", (char *)targinfo);
@@ -226,8 +225,7 @@ unsigned int arpt_do_table(struct sk_buff **pskb,
226 unsigned int hook, 225 unsigned int hook,
227 const struct net_device *in, 226 const struct net_device *in,
228 const struct net_device *out, 227 const struct net_device *out,
229 struct arpt_table *table, 228 struct arpt_table *table)
230 void *userdata)
231{ 229{
232 static const char nulldevname[IFNAMSIZ]; 230 static const char nulldevname[IFNAMSIZ];
233 unsigned int verdict = NF_DROP; 231 unsigned int verdict = NF_DROP;
@@ -302,8 +300,7 @@ unsigned int arpt_do_table(struct sk_buff **pskb,
302 in, out, 300 in, out,
303 hook, 301 hook,
304 t->u.kernel.target, 302 t->u.kernel.target,
305 t->data, 303 t->data);
306 userdata);
307 304
308 /* Target might have changed stuff. */ 305 /* Target might have changed stuff. */
309 arp = (*pskb)->nh.arph; 306 arp = (*pskb)->nh.arph;
diff --git a/net/ipv4/netfilter/arpt_mangle.c b/net/ipv4/netfilter/arpt_mangle.c
index a58325c1ceb9..05fb2421bb26 100644
--- a/net/ipv4/netfilter/arpt_mangle.c
+++ b/net/ipv4/netfilter/arpt_mangle.c
@@ -11,7 +11,7 @@ static unsigned int
11target(struct sk_buff **pskb, 11target(struct sk_buff **pskb,
12 const struct net_device *in, const struct net_device *out, 12 const struct net_device *in, const struct net_device *out,
13 unsigned int hooknum, const struct xt_target *target, 13 unsigned int hooknum, const struct xt_target *target,
14 const void *targinfo, void *userinfo) 14 const void *targinfo)
15{ 15{
16 const struct arpt_mangle *mangle = targinfo; 16 const struct arpt_mangle *mangle = targinfo;
17 struct arphdr *arp; 17 struct arphdr *arp;
diff --git a/net/ipv4/netfilter/arptable_filter.c b/net/ipv4/netfilter/arptable_filter.c
index d7c472faa53b..7edea2a1696c 100644
--- a/net/ipv4/netfilter/arptable_filter.c
+++ b/net/ipv4/netfilter/arptable_filter.c
@@ -155,7 +155,7 @@ static unsigned int arpt_hook(unsigned int hook,
155 const struct net_device *out, 155 const struct net_device *out,
156 int (*okfn)(struct sk_buff *)) 156 int (*okfn)(struct sk_buff *))
157{ 157{
158 return arpt_do_table(pskb, hook, in, out, &packet_filter, NULL); 158 return arpt_do_table(pskb, hook, in, out, &packet_filter);
159} 159}
160 160
161static struct nf_hook_ops arpt_ops[] = { 161static struct nf_hook_ops arpt_ops[] = {
diff --git a/net/ipv4/netfilter/ip_nat_rule.c b/net/ipv4/netfilter/ip_nat_rule.c
index 1aba926c1cb0..1aa0e4f462a5 100644
--- a/net/ipv4/netfilter/ip_nat_rule.c
+++ b/net/ipv4/netfilter/ip_nat_rule.c
@@ -104,8 +104,7 @@ static unsigned int ipt_snat_target(struct sk_buff **pskb,
104 const struct net_device *out, 104 const struct net_device *out,
105 unsigned int hooknum, 105 unsigned int hooknum,
106 const struct ipt_target *target, 106 const struct ipt_target *target,
107 const void *targinfo, 107 const void *targinfo)
108 void *userinfo)
109{ 108{
110 struct ip_conntrack *ct; 109 struct ip_conntrack *ct;
111 enum ip_conntrack_info ctinfo; 110 enum ip_conntrack_info ctinfo;
@@ -147,8 +146,7 @@ static unsigned int ipt_dnat_target(struct sk_buff **pskb,
147 const struct net_device *out, 146 const struct net_device *out,
148 unsigned int hooknum, 147 unsigned int hooknum,
149 const struct ipt_target *target, 148 const struct ipt_target *target,
150 const void *targinfo, 149 const void *targinfo)
151 void *userinfo)
152{ 150{
153 struct ip_conntrack *ct; 151 struct ip_conntrack *ct;
154 enum ip_conntrack_info ctinfo; 152 enum ip_conntrack_info ctinfo;
@@ -255,7 +253,7 @@ int ip_nat_rule_find(struct sk_buff **pskb,
255{ 253{
256 int ret; 254 int ret;
257 255
258 ret = ipt_do_table(pskb, hooknum, in, out, &nat_table, NULL); 256 ret = ipt_do_table(pskb, hooknum, in, out, &nat_table);
259 257
260 if (ret == NF_ACCEPT) { 258 if (ret == NF_ACCEPT) {
261 if (!ip_nat_initialized(ct, HOOK2MANIP(hooknum))) 259 if (!ip_nat_initialized(ct, HOOK2MANIP(hooknum)))
diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tables.c
index 048514f15f2f..8ce5b6f76447 100644
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
@@ -180,8 +180,7 @@ ipt_error(struct sk_buff **pskb,
180 const struct net_device *out, 180 const struct net_device *out,
181 unsigned int hooknum, 181 unsigned int hooknum,
182 const struct xt_target *target, 182 const struct xt_target *target,
183 const void *targinfo, 183 const void *targinfo)
184 void *userinfo)
185{ 184{
186 if (net_ratelimit()) 185 if (net_ratelimit())
187 printk("ip_tables: error: `%s'\n", (char *)targinfo); 186 printk("ip_tables: error: `%s'\n", (char *)targinfo);
@@ -217,8 +216,7 @@ ipt_do_table(struct sk_buff **pskb,
217 unsigned int hook, 216 unsigned int hook,
218 const struct net_device *in, 217 const struct net_device *in,
219 const struct net_device *out, 218 const struct net_device *out,
220 struct ipt_table *table, 219 struct ipt_table *table)
221 void *userdata)
222{ 220{
223 static const char nulldevname[IFNAMSIZ] __attribute__((aligned(sizeof(long)))); 221 static const char nulldevname[IFNAMSIZ] __attribute__((aligned(sizeof(long))));
224 u_int16_t offset; 222 u_int16_t offset;
@@ -308,8 +306,7 @@ ipt_do_table(struct sk_buff **pskb,
308 in, out, 306 in, out,
309 hook, 307 hook,
310 t->u.kernel.target, 308 t->u.kernel.target,
311 t->data, 309 t->data);
312 userdata);
313 310
314#ifdef CONFIG_NETFILTER_DEBUG 311#ifdef CONFIG_NETFILTER_DEBUG
315 if (((struct ipt_entry *)table_base)->comefrom 312 if (((struct ipt_entry *)table_base)->comefrom
diff --git a/net/ipv4/netfilter/ipt_CLUSTERIP.c b/net/ipv4/netfilter/ipt_CLUSTERIP.c
index d994c5f5744c..a08383cf9e7a 100644
--- a/net/ipv4/netfilter/ipt_CLUSTERIP.c
+++ b/net/ipv4/netfilter/ipt_CLUSTERIP.c
@@ -302,8 +302,7 @@ target(struct sk_buff **pskb,
302 const struct net_device *out, 302 const struct net_device *out,
303 unsigned int hooknum, 303 unsigned int hooknum,
304 const struct xt_target *target, 304 const struct xt_target *target,
305 const void *targinfo, 305 const void *targinfo)
306 void *userinfo)
307{ 306{
308 const struct ipt_clusterip_tgt_info *cipinfo = targinfo; 307 const struct ipt_clusterip_tgt_info *cipinfo = targinfo;
309 enum ip_conntrack_info ctinfo; 308 enum ip_conntrack_info ctinfo;
diff --git a/net/ipv4/netfilter/ipt_ECN.c b/net/ipv4/netfilter/ipt_ECN.c
index 7e30e6d2b5da..1c3da4a48e5f 100644
--- a/net/ipv4/netfilter/ipt_ECN.c
+++ b/net/ipv4/netfilter/ipt_ECN.c
@@ -85,8 +85,7 @@ target(struct sk_buff **pskb,
85 const struct net_device *out, 85 const struct net_device *out,
86 unsigned int hooknum, 86 unsigned int hooknum,
87 const struct xt_target *target, 87 const struct xt_target *target,
88 const void *targinfo, 88 const void *targinfo)
89 void *userinfo)
90{ 89{
91 const struct ipt_ECN_info *einfo = targinfo; 90 const struct ipt_ECN_info *einfo = targinfo;
92 91
diff --git a/net/ipv4/netfilter/ipt_LOG.c b/net/ipv4/netfilter/ipt_LOG.c
index b98f7b08b084..a8d356c6191f 100644
--- a/net/ipv4/netfilter/ipt_LOG.c
+++ b/net/ipv4/netfilter/ipt_LOG.c
@@ -416,8 +416,7 @@ ipt_log_target(struct sk_buff **pskb,
416 const struct net_device *out, 416 const struct net_device *out,
417 unsigned int hooknum, 417 unsigned int hooknum,
418 const struct xt_target *target, 418 const struct xt_target *target,
419 const void *targinfo, 419 const void *targinfo)
420 void *userinfo)
421{ 420{
422 const struct ipt_log_info *loginfo = targinfo; 421 const struct ipt_log_info *loginfo = targinfo;
423 struct nf_loginfo li; 422 struct nf_loginfo li;
diff --git a/net/ipv4/netfilter/ipt_MASQUERADE.c b/net/ipv4/netfilter/ipt_MASQUERADE.c
index ebd94f2abf0d..9659793c66c0 100644
--- a/net/ipv4/netfilter/ipt_MASQUERADE.c
+++ b/net/ipv4/netfilter/ipt_MASQUERADE.c
@@ -64,8 +64,7 @@ masquerade_target(struct sk_buff **pskb,
64 const struct net_device *out, 64 const struct net_device *out,
65 unsigned int hooknum, 65 unsigned int hooknum,
66 const struct xt_target *target, 66 const struct xt_target *target,
67 const void *targinfo, 67 const void *targinfo)
68 void *userinfo)
69{ 68{
70 struct ip_conntrack *ct; 69 struct ip_conntrack *ct;
71 enum ip_conntrack_info ctinfo; 70 enum ip_conntrack_info ctinfo;
diff --git a/net/ipv4/netfilter/ipt_NETMAP.c b/net/ipv4/netfilter/ipt_NETMAP.c
index 736c4b5a86a7..fd5e74a19fb5 100644
--- a/net/ipv4/netfilter/ipt_NETMAP.c
+++ b/net/ipv4/netfilter/ipt_NETMAP.c
@@ -55,8 +55,7 @@ target(struct sk_buff **pskb,
55 const struct net_device *out, 55 const struct net_device *out,
56 unsigned int hooknum, 56 unsigned int hooknum,
57 const struct xt_target *target, 57 const struct xt_target *target,
58 const void *targinfo, 58 const void *targinfo)
59 void *userinfo)
60{ 59{
61 struct ip_conntrack *ct; 60 struct ip_conntrack *ct;
62 enum ip_conntrack_info ctinfo; 61 enum ip_conntrack_info ctinfo;
diff --git a/net/ipv4/netfilter/ipt_REDIRECT.c b/net/ipv4/netfilter/ipt_REDIRECT.c
index f290463232de..839fe99f71d4 100644
--- a/net/ipv4/netfilter/ipt_REDIRECT.c
+++ b/net/ipv4/netfilter/ipt_REDIRECT.c
@@ -58,8 +58,7 @@ redirect_target(struct sk_buff **pskb,
58 const struct net_device *out, 58 const struct net_device *out,
59 unsigned int hooknum, 59 unsigned int hooknum,
60 const struct xt_target *target, 60 const struct xt_target *target,
61 const void *targinfo, 61 const void *targinfo)
62 void *userinfo)
63{ 62{
64 struct ip_conntrack *ct; 63 struct ip_conntrack *ct;
65 enum ip_conntrack_info ctinfo; 64 enum ip_conntrack_info ctinfo;
diff --git a/net/ipv4/netfilter/ipt_REJECT.c b/net/ipv4/netfilter/ipt_REJECT.c
index 95c6662b663c..1dfd8e56be8b 100644
--- a/net/ipv4/netfilter/ipt_REJECT.c
+++ b/net/ipv4/netfilter/ipt_REJECT.c
@@ -228,8 +228,7 @@ static unsigned int reject(struct sk_buff **pskb,
228 const struct net_device *out, 228 const struct net_device *out,
229 unsigned int hooknum, 229 unsigned int hooknum,
230 const struct xt_target *target, 230 const struct xt_target *target,
231 const void *targinfo, 231 const void *targinfo)
232 void *userinfo)
233{ 232{
234 const struct ipt_reject_info *reject = targinfo; 233 const struct ipt_reject_info *reject = targinfo;
235 234
diff --git a/net/ipv4/netfilter/ipt_SAME.c b/net/ipv4/netfilter/ipt_SAME.c
index 7169b09b5a67..cf801749490f 100644
--- a/net/ipv4/netfilter/ipt_SAME.c
+++ b/net/ipv4/netfilter/ipt_SAME.c
@@ -133,8 +133,7 @@ same_target(struct sk_buff **pskb,
133 const struct net_device *out, 133 const struct net_device *out,
134 unsigned int hooknum, 134 unsigned int hooknum,
135 const struct xt_target *target, 135 const struct xt_target *target,
136 const void *targinfo, 136 const void *targinfo)
137 void *userinfo)
138{ 137{
139 struct ip_conntrack *ct; 138 struct ip_conntrack *ct;
140 enum ip_conntrack_info ctinfo; 139 enum ip_conntrack_info ctinfo;
diff --git a/net/ipv4/netfilter/ipt_TCPMSS.c b/net/ipv4/netfilter/ipt_TCPMSS.c
index 0fce85e05507..6d668dcfc22a 100644
--- a/net/ipv4/netfilter/ipt_TCPMSS.c
+++ b/net/ipv4/netfilter/ipt_TCPMSS.c
@@ -41,8 +41,7 @@ ipt_tcpmss_target(struct sk_buff **pskb,
41 const struct net_device *out, 41 const struct net_device *out,
42 unsigned int hooknum, 42 unsigned int hooknum,
43 const struct xt_target *target, 43 const struct xt_target *target,
44 const void *targinfo, 44 const void *targinfo)
45 void *userinfo)
46{ 45{
47 const struct ipt_tcpmss_info *tcpmssinfo = targinfo; 46 const struct ipt_tcpmss_info *tcpmssinfo = targinfo;
48 struct tcphdr *tcph; 47 struct tcphdr *tcph;
diff --git a/net/ipv4/netfilter/ipt_TOS.c b/net/ipv4/netfilter/ipt_TOS.c
index 52e9d705d48e..043df0137084 100644
--- a/net/ipv4/netfilter/ipt_TOS.c
+++ b/net/ipv4/netfilter/ipt_TOS.c
@@ -26,8 +26,7 @@ target(struct sk_buff **pskb,
26 const struct net_device *out, 26 const struct net_device *out,
27 unsigned int hooknum, 27 unsigned int hooknum,
28 const struct xt_target *target, 28 const struct xt_target *target,
29 const void *targinfo, 29 const void *targinfo)
30 void *userinfo)
31{ 30{
32 const struct ipt_tos_target_info *tosinfo = targinfo; 31 const struct ipt_tos_target_info *tosinfo = targinfo;
33 struct iphdr *iph = (*pskb)->nh.iph; 32 struct iphdr *iph = (*pskb)->nh.iph;
diff --git a/net/ipv4/netfilter/ipt_TTL.c b/net/ipv4/netfilter/ipt_TTL.c
index 2afb2a8aa8c5..164007107b5e 100644
--- a/net/ipv4/netfilter/ipt_TTL.c
+++ b/net/ipv4/netfilter/ipt_TTL.c
@@ -23,7 +23,7 @@ static unsigned int
23ipt_ttl_target(struct sk_buff **pskb, 23ipt_ttl_target(struct sk_buff **pskb,
24 const struct net_device *in, const struct net_device *out, 24 const struct net_device *in, const struct net_device *out,
25 unsigned int hooknum, const struct xt_target *target, 25 unsigned int hooknum, const struct xt_target *target,
26 const void *targinfo, void *userinfo) 26 const void *targinfo)
27{ 27{
28 struct iphdr *iph; 28 struct iphdr *iph;
29 const struct ipt_TTL_info *info = targinfo; 29 const struct ipt_TTL_info *info = targinfo;
diff --git a/net/ipv4/netfilter/ipt_ULOG.c b/net/ipv4/netfilter/ipt_ULOG.c
index d46fd677fa11..4c5f0a117862 100644
--- a/net/ipv4/netfilter/ipt_ULOG.c
+++ b/net/ipv4/netfilter/ipt_ULOG.c
@@ -308,7 +308,7 @@ static unsigned int ipt_ulog_target(struct sk_buff **pskb,
308 const struct net_device *out, 308 const struct net_device *out,
309 unsigned int hooknum, 309 unsigned int hooknum,
310 const struct xt_target *target, 310 const struct xt_target *target,
311 const void *targinfo, void *userinfo) 311 const void *targinfo)
312{ 312{
313 struct ipt_ulog_info *loginfo = (struct ipt_ulog_info *) targinfo; 313 struct ipt_ulog_info *loginfo = (struct ipt_ulog_info *) targinfo;
314 314
diff --git a/net/ipv4/netfilter/iptable_filter.c b/net/ipv4/netfilter/iptable_filter.c
index 7f417484bfbf..e2e7dd8d7903 100644
--- a/net/ipv4/netfilter/iptable_filter.c
+++ b/net/ipv4/netfilter/iptable_filter.c
@@ -90,7 +90,7 @@ ipt_hook(unsigned int hook,
90 const struct net_device *out, 90 const struct net_device *out,
91 int (*okfn)(struct sk_buff *)) 91 int (*okfn)(struct sk_buff *))
92{ 92{
93 return ipt_do_table(pskb, hook, in, out, &packet_filter, NULL); 93 return ipt_do_table(pskb, hook, in, out, &packet_filter);
94} 94}
95 95
96static unsigned int 96static unsigned int
@@ -108,7 +108,7 @@ ipt_local_out_hook(unsigned int hook,
108 return NF_ACCEPT; 108 return NF_ACCEPT;
109 } 109 }
110 110
111 return ipt_do_table(pskb, hook, in, out, &packet_filter, NULL); 111 return ipt_do_table(pskb, hook, in, out, &packet_filter);
112} 112}
113 113
114static struct nf_hook_ops ipt_ops[] = { 114static struct nf_hook_ops ipt_ops[] = {
diff --git a/net/ipv4/netfilter/iptable_mangle.c b/net/ipv4/netfilter/iptable_mangle.c
index 4e7998beda63..79336cb42527 100644
--- a/net/ipv4/netfilter/iptable_mangle.c
+++ b/net/ipv4/netfilter/iptable_mangle.c
@@ -119,7 +119,7 @@ ipt_route_hook(unsigned int hook,
119 const struct net_device *out, 119 const struct net_device *out,
120 int (*okfn)(struct sk_buff *)) 120 int (*okfn)(struct sk_buff *))
121{ 121{
122 return ipt_do_table(pskb, hook, in, out, &packet_mangler, NULL); 122 return ipt_do_table(pskb, hook, in, out, &packet_mangler);
123} 123}
124 124
125static unsigned int 125static unsigned int
@@ -148,7 +148,7 @@ ipt_local_hook(unsigned int hook,
148 daddr = (*pskb)->nh.iph->daddr; 148 daddr = (*pskb)->nh.iph->daddr;
149 tos = (*pskb)->nh.iph->tos; 149 tos = (*pskb)->nh.iph->tos;
150 150
151 ret = ipt_do_table(pskb, hook, in, out, &packet_mangler, NULL); 151 ret = ipt_do_table(pskb, hook, in, out, &packet_mangler);
152 /* Reroute for ANY change. */ 152 /* Reroute for ANY change. */
153 if (ret != NF_DROP && ret != NF_STOLEN && ret != NF_QUEUE 153 if (ret != NF_DROP && ret != NF_STOLEN && ret != NF_QUEUE
154 && ((*pskb)->nh.iph->saddr != saddr 154 && ((*pskb)->nh.iph->saddr != saddr
diff --git a/net/ipv4/netfilter/iptable_raw.c b/net/ipv4/netfilter/iptable_raw.c
index 7912cce1e1b8..bcbeb4aeacd9 100644
--- a/net/ipv4/netfilter/iptable_raw.c
+++ b/net/ipv4/netfilter/iptable_raw.c
@@ -95,7 +95,7 @@ ipt_hook(unsigned int hook,
95 const struct net_device *out, 95 const struct net_device *out,
96 int (*okfn)(struct sk_buff *)) 96 int (*okfn)(struct sk_buff *))
97{ 97{
98 return ipt_do_table(pskb, hook, in, out, &packet_raw, NULL); 98 return ipt_do_table(pskb, hook, in, out, &packet_raw);
99} 99}
100 100
101/* 'raw' is the very first table. */ 101/* 'raw' is the very first table. */