Message ID | 2ba3394abf87c940fe036b2e18e1afc2a2d37ad0.1660320356.git.stefan@agner.ch |
---|---|
State | Changes Requested |
Headers | show |
Series | package/docker-engine: use kernel modules for extra network drivers | expand |
Stefan, All, On 2022-08-12 18:07 +0200, Stefan Agner spake thusly: > Docker network driver "overlay", "macvlan" and "ipvlan" are not used > by default. Make them a module. > > The main aim here is to get rid of the dummy0 network interface which > is generated by the dummy driver by default. For consistency, make > all kernel drivers required for Docker network drivers a module. Also > add the currently missing CONFIG_BRIDGE_VLAN_FILTERING (mandatory > for the Docker network driver "overlay"). > > Signed-off-by: Stefan Agner <stefan@agner.ch> > --- > package/docker-engine/docker-engine.mk | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) > > diff --git a/package/docker-engine/docker-engine.mk b/package/docker-engine/docker-engine.mk > index 293af1858c..730f2e3b86 100644 > --- a/package/docker-engine/docker-engine.mk > +++ b/package/docker-engine/docker-engine.mk > @@ -124,10 +124,11 @@ define DOCKER_ENGINE_LINUX_CONFIG_FIXUPS > $(call KCONFIG_ENABLE_OPT,CONFIG_IP_NF_TARGET_MASQUERADE) > $(call KCONFIG_ENABLE_OPT,CONFIG_BRIDGE) > $(call KCONFIG_ENABLE_OPT,CONFIG_NET_CORE) > - $(call KCONFIG_ENABLE_OPT,CONFIG_DUMMY) > - $(call KCONFIG_ENABLE_OPT,CONFIG_MACVLAN) > - $(call KCONFIG_ENABLE_OPT,CONFIG_IPVLAN) > - $(call KCONFIG_ENABLE_OPT,CONFIG_VXLAN) > + $(call KCONFIG_SET_OPT,CONFIG_DUMMY,m) > + $(call KCONFIG_SET_OPT,CONFIG_MACVLAN,m) > + $(call KCONFIG_SET_OPT,CONFIG_IPVLAN,m) > + $(call KCONFIG_SET_OPT,CONFIG_VXLAN,m) > + $(call KCONFIG_SET_OPT,CONFIG_BRIDGE_VLAN_FILTERING,m) That entirely overrides the options from the configuration file provided by the user, if they have and require any of those options set as =y. I think that what we need, is to have a helper KCONFIG_ENABLE_OPT_MOD, which only sets an option to 'm' if it is not already 'y' (i.e. the opposite of KCONFIG_ENABLE_OPT). Regards, Yann E. MORIN. > $(call KCONFIG_ENABLE_OPT,CONFIG_VETH) > $(call KCONFIG_ENABLE_OPT,CONFIG_OVERLAY_FS) > $(call KCONFIG_ENABLE_OPT,CONFIG_KEYS) > -- > 2.37.1 > > _______________________________________________ > buildroot mailing list > buildroot@buildroot.org > https://lists.buildroot.org/mailman/listinfo/buildroot
On 13/08/2022 13:51, Yann E. MORIN wrote: > Stefan, All, > > On 2022-08-12 18:07 +0200, Stefan Agner spake thusly: >> Docker network driver "overlay", "macvlan" and "ipvlan" are not used >> by default. Make them a module. >> >> The main aim here is to get rid of the dummy0 network interface which >> is generated by the dummy driver by default. For consistency, make >> all kernel drivers required for Docker network drivers a module. Also >> add the currently missing CONFIG_BRIDGE_VLAN_FILTERING (mandatory >> for the Docker network driver "overlay"). >> >> Signed-off-by: Stefan Agner <stefan@agner.ch> >> --- >> package/docker-engine/docker-engine.mk | 9 +++++---- >> 1 file changed, 5 insertions(+), 4 deletions(-) >> >> diff --git a/package/docker-engine/docker-engine.mk b/package/docker-engine/docker-engine.mk >> index 293af1858c..730f2e3b86 100644 >> --- a/package/docker-engine/docker-engine.mk >> +++ b/package/docker-engine/docker-engine.mk >> @@ -124,10 +124,11 @@ define DOCKER_ENGINE_LINUX_CONFIG_FIXUPS >> $(call KCONFIG_ENABLE_OPT,CONFIG_IP_NF_TARGET_MASQUERADE) >> $(call KCONFIG_ENABLE_OPT,CONFIG_BRIDGE) >> $(call KCONFIG_ENABLE_OPT,CONFIG_NET_CORE) >> - $(call KCONFIG_ENABLE_OPT,CONFIG_DUMMY) >> - $(call KCONFIG_ENABLE_OPT,CONFIG_MACVLAN) >> - $(call KCONFIG_ENABLE_OPT,CONFIG_IPVLAN) >> - $(call KCONFIG_ENABLE_OPT,CONFIG_VXLAN) >> + $(call KCONFIG_SET_OPT,CONFIG_DUMMY,m) >> + $(call KCONFIG_SET_OPT,CONFIG_MACVLAN,m) >> + $(call KCONFIG_SET_OPT,CONFIG_IPVLAN,m) >> + $(call KCONFIG_SET_OPT,CONFIG_VXLAN,m) >> + $(call KCONFIG_SET_OPT,CONFIG_BRIDGE_VLAN_FILTERING,m) > > That entirely overrides the options from the configuration file provided > by the user, if they have and require any of those options set as =y. > > I think that what we need, is to have a helper KCONFIG_ENABLE_OPT_MOD, > which only sets an option to 'm' if it is not already 'y' (i.e. the > opposite of KCONFIG_ENABLE_OPT). Actually, if they're optional, I wouldn't configure them at all. Someone who doesn't need this feature may very well want to build a kernel that doesn't have them at all, even as modules. Or you may even build a kernel that doesn't have module support. We don't have a good way to make those options "suggested", other than mentioning them in the help text. But I do think that that's enough. Regards, Arnout > > Regards, > Yann E. MORIN. > >> $(call KCONFIG_ENABLE_OPT,CONFIG_VETH) >> $(call KCONFIG_ENABLE_OPT,CONFIG_OVERLAY_FS) >> $(call KCONFIG_ENABLE_OPT,CONFIG_KEYS) >> -- >> 2.37.1 >> >> _______________________________________________ >> buildroot mailing list >> buildroot@buildroot.org >> https://lists.buildroot.org/mailman/listinfo/buildroot >
Arnout, Stefan, All, On 2022-08-14 23:27 +0200, Arnout Vandecappelle spake thusly: > On 13/08/2022 13:51, Yann E. MORIN wrote: > >On 2022-08-12 18:07 +0200, Stefan Agner spake thusly: > >>Docker network driver "overlay", "macvlan" and "ipvlan" are not used > >>by default. Make them a module. [--SNIP--] > Actually, if they're optional, I wouldn't configure them at all. Someone > who doesn't need this feature may very well want to build a kernel that > doesn't have them at all, even as modules. Or you may even build a kernel > that doesn't have module support. > > We don't have a good way to make those options "suggested", other than > mentioning them in the help text. But I do think that that's enough. Agreed. Regards, Yann E. MORIN.
On Fri, 12 Aug 2022 18:07:01 +0200 Stefan Agner <stefan@agner.ch> wrote: > Docker network driver "overlay", "macvlan" and "ipvlan" are not used > by default. Make them a module. > > The main aim here is to get rid of the dummy0 network interface which > is generated by the dummy driver by default. For consistency, make > all kernel drivers required for Docker network drivers a module. Also > add the currently missing CONFIG_BRIDGE_VLAN_FILTERING (mandatory > for the Docker network driver "overlay"). > > Signed-off-by: Stefan Agner <stefan@agner.ch> > --- > package/docker-engine/docker-engine.mk | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) Based on the feedback from Yann and Arnout, I have marked this patch as Changes Requested in our patch tracking system. Best regards, Thomas
diff --git a/package/docker-engine/docker-engine.mk b/package/docker-engine/docker-engine.mk index 293af1858c..730f2e3b86 100644 --- a/package/docker-engine/docker-engine.mk +++ b/package/docker-engine/docker-engine.mk @@ -124,10 +124,11 @@ define DOCKER_ENGINE_LINUX_CONFIG_FIXUPS $(call KCONFIG_ENABLE_OPT,CONFIG_IP_NF_TARGET_MASQUERADE) $(call KCONFIG_ENABLE_OPT,CONFIG_BRIDGE) $(call KCONFIG_ENABLE_OPT,CONFIG_NET_CORE) - $(call KCONFIG_ENABLE_OPT,CONFIG_DUMMY) - $(call KCONFIG_ENABLE_OPT,CONFIG_MACVLAN) - $(call KCONFIG_ENABLE_OPT,CONFIG_IPVLAN) - $(call KCONFIG_ENABLE_OPT,CONFIG_VXLAN) + $(call KCONFIG_SET_OPT,CONFIG_DUMMY,m) + $(call KCONFIG_SET_OPT,CONFIG_MACVLAN,m) + $(call KCONFIG_SET_OPT,CONFIG_IPVLAN,m) + $(call KCONFIG_SET_OPT,CONFIG_VXLAN,m) + $(call KCONFIG_SET_OPT,CONFIG_BRIDGE_VLAN_FILTERING,m) $(call KCONFIG_ENABLE_OPT,CONFIG_VETH) $(call KCONFIG_ENABLE_OPT,CONFIG_OVERLAY_FS) $(call KCONFIG_ENABLE_OPT,CONFIG_KEYS)
Docker network driver "overlay", "macvlan" and "ipvlan" are not used by default. Make them a module. The main aim here is to get rid of the dummy0 network interface which is generated by the dummy driver by default. For consistency, make all kernel drivers required for Docker network drivers a module. Also add the currently missing CONFIG_BRIDGE_VLAN_FILTERING (mandatory for the Docker network driver "overlay"). Signed-off-by: Stefan Agner <stefan@agner.ch> --- package/docker-engine/docker-engine.mk | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)