Commit f319ca65 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by David S. Miller

openvswitch: Replace removed NF_NAT_NEEDED with IS_ENABLED(CONFIG_NF_NAT)

Commit 4806e975 ("netfilter: replace NF_NAT_NEEDED with
IS_ENABLED(CONFIG_NF_NAT)") removed CONFIG_NF_NAT_NEEDED, but a new user
popped up afterwards.

Fixes: fec9c271 ("openvswitch: load and reference the NAT helper.")
Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Acked-by: default avatarFlorian Westphal <fw@strlen.de>
Acked-by: default avatarFlavio Leitner <fbl@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 19e4e768
...@@ -1322,7 +1322,7 @@ static int ovs_ct_add_helper(struct ovs_conntrack_info *info, const char *name, ...@@ -1322,7 +1322,7 @@ static int ovs_ct_add_helper(struct ovs_conntrack_info *info, const char *name,
return -ENOMEM; return -ENOMEM;
} }
#ifdef CONFIG_NF_NAT_NEEDED #if IS_ENABLED(CONFIG_NF_NAT)
if (info->nat) { if (info->nat) {
ret = nf_nat_helper_try_module_get(name, info->family, ret = nf_nat_helper_try_module_get(name, info->family,
key->ip.proto); key->ip.proto);
...@@ -1811,7 +1811,7 @@ void ovs_ct_free_action(const struct nlattr *a) ...@@ -1811,7 +1811,7 @@ void ovs_ct_free_action(const struct nlattr *a)
static void __ovs_ct_free_action(struct ovs_conntrack_info *ct_info) static void __ovs_ct_free_action(struct ovs_conntrack_info *ct_info)
{ {
if (ct_info->helper) { if (ct_info->helper) {
#ifdef CONFIG_NF_NAT_NEEDED #if IS_ENABLED(CONFIG_NF_NAT)
if (ct_info->nat) if (ct_info->nat)
nf_nat_helper_put(ct_info->helper); nf_nat_helper_put(ct_info->helper);
#endif #endif
......
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