Commit 4b1e27e9 authored by Jan Engelhardt's avatar Jan Engelhardt

netfilter: queue: use NFPROTO_ for queue callsites

af is an nfproto.
Signed-off-by: default avatarJan Engelhardt <jengelh@medozas.de>
parent 383ca5b8
...@@ -596,7 +596,7 @@ static int __init ip_queue_init(void) ...@@ -596,7 +596,7 @@ static int __init ip_queue_init(void)
#ifdef CONFIG_SYSCTL #ifdef CONFIG_SYSCTL
ipq_sysctl_header = register_sysctl_paths(net_ipv4_ctl_path, ipq_table); ipq_sysctl_header = register_sysctl_paths(net_ipv4_ctl_path, ipq_table);
#endif #endif
status = nf_register_queue_handler(PF_INET, &nfqh); status = nf_register_queue_handler(NFPROTO_IPV4, &nfqh);
if (status < 0) { if (status < 0) {
printk(KERN_ERR "ip_queue: failed to register queue handler\n"); printk(KERN_ERR "ip_queue: failed to register queue handler\n");
goto cleanup_sysctl; goto cleanup_sysctl;
......
...@@ -598,7 +598,7 @@ static int __init ip6_queue_init(void) ...@@ -598,7 +598,7 @@ static int __init ip6_queue_init(void)
#ifdef CONFIG_SYSCTL #ifdef CONFIG_SYSCTL
ipq_sysctl_header = register_sysctl_paths(net_ipv6_ctl_path, ipq_table); ipq_sysctl_header = register_sysctl_paths(net_ipv6_ctl_path, ipq_table);
#endif #endif
status = nf_register_queue_handler(PF_INET6, &nfqh); status = nf_register_queue_handler(NFPROTO_IPV6, &nfqh);
if (status < 0) { if (status < 0) {
printk(KERN_ERR "ip6_queue: failed to register queue handler\n"); printk(KERN_ERR "ip6_queue: failed to register queue handler\n");
goto cleanup_sysctl; goto cleanup_sysctl;
......
...@@ -204,10 +204,10 @@ int nf_queue(struct sk_buff *skb, ...@@ -204,10 +204,10 @@ int nf_queue(struct sk_buff *skb,
queuenum); queuenum);
switch (pf) { switch (pf) {
case AF_INET: case NFPROTO_IPV4:
skb->protocol = htons(ETH_P_IP); skb->protocol = htons(ETH_P_IP);
break; break;
case AF_INET6: case NFPROTO_IPV6:
skb->protocol = htons(ETH_P_IPV6); skb->protocol = htons(ETH_P_IPV6);
break; break;
} }
......
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