Skip to contentSkip to conversation

nftables: minor Kconfig fixes

PATCH Applied Eric Leblond 2 participants 5 messages Dec 29, 2013 – Dec 30, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover nftables: minor Kconfig fixes

Hello,

This patchset only contains two small patches aiming to improve nftables configuration inside the kernel.

BR,
--
Eric Leblond

#1 lore raw

PATCH 1/2 netfilter: nft: select NFNETLINK

In Kconfig, nft is set as depending on NFNETLINK so building nft as a module or inside kernel is depending of the state of NFNETLINK inside the kernel config. If someone wants to build nftables inside the kernel, it is necessary to also build NFNETLINK inside the kernel. But NFNETLINK can not be set in the menu so it is necessary to toggle an external value such as logging or nfacct to have a switch of NFNETLINK to kernel build.
This patch change the dependency to a select inside Kconfig to be able to set the build of nftables as modules or inside kernel independently.

---
 net/netfilter/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/netfilter/Kconfig +1 -1
index 4371c98..01f9f64 100644
@@ -414,7 +414,7 @@ config NETFILTER_SYNPROXY
 endif # NF_CONNTRACK
 
 config NF_TABLES
-	depends on NETFILTER_NETLINK
+	select NETFILTER_NETLINK
 	tristate "Netfilter nf_tables support"
 
 config NFT_EXTHDR
Signature · 1 line
1.8.5.2
maintainer Applied
#2 lore raw

Re: [PATCH 1/2] netfilter: nft: select NFNETLINK

Quoted 9 lines · Eric Leblond

In Kconfig, nft is set as depending on NFNETLINK so building nft as a module or inside kernel is depending of the state of NFNETLINK inside the kernel config. If someone wants to build nftables inside the kernel, it is necessary to also build NFNETLINK inside the kernel. But NFNETLINK can not be set in the menu so it is necessary to toggle an external value such as logging or nfacct to have a switch of NFNETLINK to kernel build.
This patch change the dependency to a select inside Kconfig to be able to set the build of nftables as modules or inside kernel independently.

Applied, thanks Eric.

#3 lore raw

PATCH 2/2 netfilter: nft: explicit dependency to IPv6

In reply to Eric Leblond

nftables IPv6 tables could be selected independently of other Netfilter component so it needs to be dependent of IPv6.

---
 net/ipv6/netfilter/Kconfig | 1 +
 1 file changed, 1 insertion(+)
net/ipv6/netfilter/Kconfig +1 -0
index 7702f9e..36c71da 100644
@@ -27,6 +27,7 @@ config NF_CONNTRACK_IPV6
 
 config NF_TABLES_IPV6
 	depends on NF_TABLES
+	depends on INET && IPV6
 	tristate "IPv6 nf_tables support"
 
 config NFT_CHAIN_ROUTE_IPV6
Signature · 1 line
1.8.5.2
#4 lore raw

Re: [PATCH 2/2] netfilter: nft: explicit dependency to IPv6

Hi Eric,

Quoted 13 lines · Eric Leblond

nftables IPv6 tables could be selected independently of other Netfilter component so it needs to be dependent of IPv6.

---
 net/ipv6/netfilter/Kconfig | 1 +
 1 file changed, 1 insertion(+)
net/ipv6/netfilter/Kconfig +0 -0
index 7702f9e..36c71da 100644

net/ipv6/netfilter/Kconfig config NF_CONNTRACK_IPV6 · line 31

Quoted 5 lines
net/ipv6/netfilter/Kconfig +1 -0
@@ -27,6 +27,7 @@ config NF_CONNTRACK_IPV6
 
 config NF_TABLES_IPV6
 	depends on NF_TABLES
+	depends on INET && IPV6
 	tristate "IPv6 nf_tables support"

We already have this dependency in the parent menu

#
# IP netfilter configuration
#

menu "IPv6: Netfilter Configuration"

         depends on INET && IPV6 && NETFILTER

So I think that should be enough, let me know if you're noticing any problem. Thanks.