mpls: fix dependencies on mpls_gso.ko
Subsystems (3)
cover mpls: fix dependencies on mpls_gso.ko
Since commit b7c24497baea ("mpls: load mpls_gso after mpls_iptunnel"), mpls_iptunnel tries to load mpls_gso. Therefore, we need to build mpls_gso when mpls_iptunnel is selected (patch 1).
There's also the act_mpls module that can push MPLS headers on GSO packets. This module also depends on mpls_gso (patch 2).
Guillaume Nault (2):
mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
net/sched: act_mpls: Add softdep on mpls_gso.ko
net/mpls/Kconfig | 1 + net/sched/Kconfig | 2 ++ net/sched/act_mpls.c | 1 + 3 files changed, 4 insertions(+)
Signature · 1 line
2.21.3
PATCH 1/2 mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Since commit b7c24497baea ("mpls: load mpls_gso after mpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built whenever MPLS_IPTUNNEL is set.
--- net/mpls/Kconfig | 1 + 1 file changed, 1 insertion(+)
net/mpls/Kconfig +1 -0
@@ -33,6 +33,7 @@ config MPLS_ROUTING config MPLS_IPTUNNEL tristate "MPLS: IP over MPLS tunnel support" depends on LWTUNNEL && MPLS_ROUTING + select NET_MPLS_GSO help mpls ip tunnel support.
Signature · 1 line
2.21.3
Jakub Kicinski
maintainerRe: [PATCH net 1/2] mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Quoted 3 lines · On Fri, 23 Oct 2020 18:19:43 +0200 Guillaume Nault wrote:
Since commit
b7c24497baea("mpls: loadmpls_gsoaftermpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built wheneverMPLS_IPTUNNELis set.
Does it generate an error or a warning? I don't know much about soft dependencies, but I'd think it's optional.
Quoted 12 lines
net/mpls/Kconfig +1
-0@@ -33,6 +33,7 @@ config MPLS_ROUTING config MPLS_IPTUNNEL tristate "MPLS: IP over MPLS tunnel support" depends on LWTUNNEL && MPLS_ROUTING + select NET_MPLS_GSO help mpls ip tunnel support.
Re: [PATCH net 1/2] mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Quoted 7 lines · Jakub Kicinski
Quoted 3 lines · On Fri, 23 Oct 2020 18:19:43 +0200 Guillaume Nault wrote:
Since commit
b7c24497baea("mpls: loadmpls_gsoaftermpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built wheneverMPLS_IPTUNNELis set.Does it generate an error or a warning? I don't know much about soft dependencies, but I'd think it's optional.
Yes, it's optional from a softdep point of view. My point was that having a softdep isn't a complete solution, as a bad .config can still result in inability to properly transmit GSO packets.
Quoted 13 lines
Quoted 12 lines
net/mpls/Kconfig +1
-0@@ -33,6 +33,7 @@ config MPLS_ROUTING config MPLS_IPTUNNEL tristate "MPLS: IP over MPLS tunnel support" depends on LWTUNNEL && MPLS_ROUTING + select NET_MPLS_GSO help mpls ip tunnel support.
Jakub Kicinski
maintainerRe: [PATCH net 1/2] mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Quoted 6 lines · On Fri, 23 Oct 2020 20:48:16 +0200 Guillaume Nault wrote:
Quoted 5 lines · Jakub Kicinski
Quoted 3 lines · On Fri, 23 Oct 2020 18:19:43 +0200 Guillaume Nault wrote:
Since commit
b7c24497baea("mpls: loadmpls_gsoaftermpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built wheneverMPLS_IPTUNNELis set.
Quoted 6 lines
Quoted 2 lines
Does it generate an error or a warning? I don't know much about soft dependencies, but I'd think it's optional.
Yes, it's optional from a softdep point of view. My point was that having a softdep isn't a complete solution, as a bad .config can still result in inability to properly transmit GSO packets.
IMO the combination of select and softdep feels pretty strange.
It's either a softdep and therefore optional, or we really don't want to be missing it in a correctly functioning system, and the dependency should be made stronger.
Re: [PATCH net 1/2] mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Quoted 14 lines · Jakub Kicinski
Quoted 6 lines · On Fri, 23 Oct 2020 20:48:16 +0200 Guillaume Nault wrote:
Quoted 5 lines · Jakub Kicinski
Quoted 3 lines · On Fri, 23 Oct 2020 18:19:43 +0200 Guillaume Nault wrote:
Since commit
b7c24497baea("mpls: loadmpls_gsoaftermpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built wheneverMPLS_IPTUNNELis set.Quoted 6 lines
Quoted 2 lines
Does it generate an error or a warning? I don't know much about soft dependencies, but I'd think it's optional.
Yes, it's optional from a softdep point of view. My point was that having a softdep isn't a complete solution, as a bad .config can still result in inability to properly transmit GSO packets.
Quoted 6 lines
IMO the combination of select and softdep feels pretty strange.
It's either a softdep and therefore optional, or we really don't want to be missing it in a correctly functioning system, and the dependency should be made stronger.
That's why I liked the softdep solution - if the module is there, load it.
Re: [PATCH net 1/2] mpls: Make MPLS_IPTUNNEL select NET_MPLS_GSO
Quoted 15 lines · David Ahern
Quoted 14 lines · Jakub Kicinski
Quoted 12 lines · On Fri, 23 Oct 2020 20:48:16 +0200 Guillaume Nault wrote:
Quoted 7 lines · Jakub Kicinski
Quoted 3 lines · On Fri, 23 Oct 2020 18:19:43 +0200 Guillaume Nault wrote:
Since commit
b7c24497baea("mpls: loadmpls_gsoaftermpls_iptunnel"), mpls_iptunnel.ko has a softdep on mpls_gso.ko. For this to work, we need to ensure that mpls_gso.ko is built wheneverMPLS_IPTUNNELis set.Does it generate an error or a warning? I don't know much about soft dependencies, but I'd think it's optional.
Yes, it's optional from a softdep point of view. My point was that having a softdep isn't a complete solution, as a bad .config can still result in inability to properly transmit GSO packets.
Quoted 8 lines
Quoted 6 lines
IMO the combination of select and softdep feels pretty strange.
It's either a softdep and therefore optional, or we really don't want to be missing it in a correctly functioning system, and the dependency should be made stronger.
That's why I liked the softdep solution - if the module is there, load it.
Okay, then I'll resubmit without the Kconfig bits.
PATCH 2/2 net/sched: act_mpls: Add softdep on mpls_gso.ko
In reply to Guillaume NaultTCA_MPLS_ACT_PUSH and TCA_MPLS_ACT_MAC_PUSH might be used on gso packets. Such packets will thus require mpls_gso.ko for segmentation.
--- net/sched/Kconfig | 2 ++ net/sched/act_mpls.c | 1 + 2 files changed, 3 insertions(+)
net/sched/Kconfig +2 -0
@@ -879,6 +879,8 @@ config NET_ACT_CSUM config NET_ACT_MPLS tristate "MPLS manipulation" depends on NET_CLS_ACT + select MPLS + select NET_MPLS_GSO help Say Y here to push or pop MPLS headers.
net/sched/act_mpls.c +1 -0
@@ -426,6 +426,7 @@ static void __exit mpls_cleanup_module(void)module_init (mpls_init_module);module_exit (mpls_cleanup_module); +MODULE_SOFTDEP ("post: mpls_gso" );MODULE_AUTHOR ("Netronome Systems <[email protected]>" );MODULE_LICENSE ("GPL" );MODULE_DESCRIPTION ("MPLS manipulation actions" );
Signature · 1 line
2.21.3