lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <69f12f34-bedb-4d1a-b359-7488530ab4e4@intel.com>
Date: Thu, 16 May 2024 10:58:37 +0200
From: Alexander Lobakin <aleksander.lobakin@...el.com>
To: Florian Fainelli <florian.fainelli@...adcom.com>
CC: <netdev@...r.kernel.org>, <masahiroy@...nel.org>, Stephen Langstaff
	<stephenlangstaff1@...il.com>, "David S. Miller" <davem@...emloft.net>, "Eric
 Dumazet" <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>, Paolo Abeni
	<pabeni@...hat.com>, Alexander Lobakin <alobakin@...me>, Florian Fainelli
	<f.fainelli@...il.com>, Vladimir Oltean <olteanv@...il.com>, open list
	<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net] net: Always descend into dsa/ folder

From: Florian Fainelli <florian.fainelli@...adcom.com>
Date: Wed, 15 May 2024 20:33:45 -0700

> Stephen reported that he was unable to get the dsa_loop driver to get
> probed, and the reason ended up being because he had CONFIG_FIXED_PHY=y
> in his kernel configuration. As Masahiro explained it:
> 
>   "obj-m += dsa/" means everything under dsa/ must be modular.
> 
>   If there is a built-in object under dsa/ with CONFIG_NET_DSA=m,
>   you cannot do  "obj-$(CONFIG_NET_DSA) += dsa/".
> 
>   You need to change it back to "obj-y += dsa/".
> 
> This was the case here whereby CONFIG_NET_DSA=m, and so the
> obj-$(CONFIG_FIXED_PHY) += dsa_loop_bdinfo.o rule is not executed and
> the DSA loop mdio_board info structure is not registered with the
> kernel, and eventually the device is simply not found.
> 
> Fixes: 227d72063fcc ("dsa: simplify Kconfig symbols and dependencies")
> Reported-by: Stephen Langstaff <stephenlangstaff1@...il.com>
> Signed-off-by: Florian Fainelli <florian.fainelli@...adcom.com>
> ---
>  drivers/net/Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/Makefile b/drivers/net/Makefile
> index 9c053673d6b2..0f6f0f091e0e 100644
> --- a/drivers/net/Makefile
> +++ b/drivers/net/Makefile
> @@ -49,7 +49,7 @@ obj-$(CONFIG_MHI_NET) += mhi_net.o
>  obj-$(CONFIG_ARCNET) += arcnet/
>  obj-$(CONFIG_CAIF) += caif/
>  obj-$(CONFIG_CAN) += can/
> -obj-$(CONFIG_NET_DSA) += dsa/
> +obj-y += dsa/

obj-$(CONFIG_NET_DSA:m=y) += dsa/

?

or

ifdef CONFIG_NET_DSA
obj-y += dsa/
endif

I don't like always adding folders even if nothing will be built there
as we then have a lot of folders with just empty built-in.a.

>  obj-$(CONFIG_ETHERNET) += ethernet/
>  obj-$(CONFIG_FDDI) += fddi/
>  obj-$(CONFIG_HIPPI) += hippi/

Thanks,
Olek

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ