Commit 19223f26 authored by Alexey Dobriyan's avatar Alexey Dobriyan Committed by Patrick McHardy

netfilter: arptable_filter: merge forward hook

It's identical to NF_ARP_IN hook.
Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
parent d4ec52ba
...@@ -75,16 +75,6 @@ static unsigned int arpt_out_hook(unsigned int hook, ...@@ -75,16 +75,6 @@ static unsigned int arpt_out_hook(unsigned int hook,
dev_net(out)->ipv4.arptable_filter); dev_net(out)->ipv4.arptable_filter);
} }
static unsigned int arpt_forward_hook(unsigned int hook,
struct sk_buff *skb,
const struct net_device *in,
const struct net_device *out,
int (*okfn)(struct sk_buff *))
{
return arpt_do_table(skb, hook, in, out,
dev_net(in)->ipv4.arptable_filter);
}
static struct nf_hook_ops arpt_ops[] __read_mostly = { static struct nf_hook_ops arpt_ops[] __read_mostly = {
{ {
.hook = arpt_in_hook, .hook = arpt_in_hook,
...@@ -101,7 +91,7 @@ static struct nf_hook_ops arpt_ops[] __read_mostly = { ...@@ -101,7 +91,7 @@ static struct nf_hook_ops arpt_ops[] __read_mostly = {
.priority = NF_IP_PRI_FILTER, .priority = NF_IP_PRI_FILTER,
}, },
{ {
.hook = arpt_forward_hook, .hook = arpt_in_hook,
.owner = THIS_MODULE, .owner = THIS_MODULE,
.pf = NFPROTO_ARP, .pf = NFPROTO_ARP,
.hooknum = NF_ARP_FORWARD, .hooknum = NF_ARP_FORWARD,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment