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: <CAJq09z56YYBOe=N8be-4MPzXEMx7jUbWyEDcs=fgxe088A-a3g@mail.gmail.com>
Date: Tue, 9 Jan 2024 02:11:45 -0300
From: Luiz Angelo Daros de Luca <luizluca@...il.com>
To: Vladimir Oltean <olteanv@...il.com>
Cc: netdev@...r.kernel.org, linus.walleij@...aro.org, alsi@...g-olufsen.dk, 
	andrew@...n.ch, f.fainelli@...il.com, davem@...emloft.net, 
	edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com, 
	arinc.unal@...nc9.com
Subject: Re: [PATCH net-next v3 4/8] net: dsa: realtek: merge common and
 interface modules into realtek-dsa

> > +++ b/drivers/net/dsa/realtek/Makefile
> > @@ -1,8 +1,9 @@
> >  # SPDX-License-Identifier: GPL-2.0
> >  obj-$(CONFIG_NET_DSA_REALTEK)                += realtek-dsa.o
> > -realtek-dsa-objs                     := realtek-common.o
> > -obj-$(CONFIG_NET_DSA_REALTEK_MDIO)   += realtek-mdio.o
> > -obj-$(CONFIG_NET_DSA_REALTEK_SMI)    += realtek-smi.o
> > +realtek-dsa-objs-y                   := realtek-common.o
> > +realtek-dsa-objs-$(CONFIG_NET_DSA_REALTEK_MDIO) += realtek-mdio.o
> > +realtek-dsa-objs-$(CONFIG_NET_DSA_REALTEK_SMI) += realtek-smi.o
> > +realtek-dsa-objs                     := $(realtek-dsa-objs-y)
> >  obj-$(CONFIG_NET_DSA_REALTEK_RTL8366RB) += rtl8366.o
> >  rtl8366-objs                                 := rtl8366-core.o rtl8366rb.o
> >  obj-$(CONFIG_NET_DSA_REALTEK_RTL8365MB) += rtl8365mb.o
>
> Does "realtek-dsa-objs-y" have any particular meaning in the Kbuild
> system, or is it just a random variable name?
>
> Am I the only one for whom this is clearer in intent?
>
> diff --git a/drivers/net/dsa/realtek/Makefile b/drivers/net/dsa/realtek/Makefile
> index cea0e761d20f..418f8bff77b8 100644
> --- a/drivers/net/dsa/realtek/Makefile
> +++ b/drivers/net/dsa/realtek/Makefile
> @@ -1,9 +1,15 @@
>  # SPDX-License-Identifier: GPL-2.0
>  obj-$(CONFIG_NET_DSA_REALTEK)          += realtek-dsa.o
> -realtek-dsa-objs-y                     := realtek-common.o
> -realtek-dsa-objs-$(CONFIG_NET_DSA_REALTEK_MDIO) += realtek-mdio.o
> -realtek-dsa-objs-$(CONFIG_NET_DSA_REALTEK_SMI) += realtek-smi.o
> -realtek-dsa-objs                       := $(realtek-dsa-objs-y)
> +realtek-dsa-objs                       := realtek-common.o
> +
> +ifdef CONFIG_NET_DSA_REALTEK_MDIO
> +realtek-dsa-objs += realtek-mdio.o
> +endif
> +
> +ifdef CONFIG_NET_DSA_REALTEK_SMI
> +realtek-dsa-objs += realtek-smi.o
> +endif
> +
>  obj-$(CONFIG_NET_DSA_REALTEK_RTL8366RB) += rtl8366.o
>  rtl8366-objs                           := rtl8366-core.o rtl8366rb.o
>  obj-$(CONFIG_NET_DSA_REALTEK_RTL8365MB) += rtl8365mb.o

I also prefer ifdef but it was suggested to use the realtek-dsa-objs-y
magic and nobody argued about that. It is an easy fix.

Regards,

Luiz

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ