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: <CAL_JsqLRQRmhXZm25WKzUSBUyK6q5d-BspW4zQcztW3Qf56EKg@mail.gmail.com>
Date:   Wed, 6 Oct 2021 11:58:07 -0500
From:   Rob Herring <robh+dt@...nel.org>
To:     Andrew Lunn <andrew@...n.ch>
Cc:     Jakub Kicinski <kuba@...nel.org>,
        David Miller <davem@...emloft.net>,
        netdev <netdev@...r.kernel.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        Saravana Kannan <saravanak@...gle.com>,
        Marcin Wojtas <mw@...ihalf.com>,
        Jeremy Linton <jeremy.linton@....com>,
        Heiner Kallweit <hkallweit1@...il.com>,
        Russell King <linux@...linux.org.uk>,
        Frank Rowand <frowand.list@...il.com>,
        Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
        devicetree@...r.kernel.org
Subject: Re: [PATCH net-next v2 1/9] of: net: move of_net under net/

On Wed, Oct 6, 2021 at 11:34 AM Andrew Lunn <andrew@...n.ch> wrote:
>
> On Wed, Oct 06, 2021 at 11:18:19AM -0500, Rob Herring wrote:
> > On Wed, Oct 6, 2021 at 10:45 AM Jakub Kicinski <kuba@...nel.org> wrote:
> > >
> > > Rob suggests to move of_net.c from under drivers/of/ somewhere
> > > to the networking code.
> > >
> > > Suggested-by: Rob Herring <robh@...nel.org>
> > > Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> > > ---
> > > v2: new patch
> > > ---
> > >  drivers/of/Makefile               | 1 -
> > >  net/core/Makefile                 | 1 +
> > >  {drivers/of => net/core}/of_net.c | 0
> > >  3 files changed, 1 insertion(+), 1 deletion(-)
> > >  rename {drivers/of => net/core}/of_net.c (100%)
> > >
> > > diff --git a/drivers/of/Makefile b/drivers/of/Makefile
> > > index c13b982084a3..e0360a44306e 100644
> > > --- a/drivers/of/Makefile
> > > +++ b/drivers/of/Makefile
> > > @@ -7,7 +7,6 @@ obj-$(CONFIG_OF_EARLY_FLATTREE) += fdt_address.o
> > >  obj-$(CONFIG_OF_PROMTREE) += pdt.o
> > >  obj-$(CONFIG_OF_ADDRESS)  += address.o
> > >  obj-$(CONFIG_OF_IRQ)    += irq.o
> > > -obj-$(CONFIG_OF_NET)   += of_net.o
> > >  obj-$(CONFIG_OF_UNITTEST) += unittest.o
> > >  obj-$(CONFIG_OF_RESERVED_MEM) += of_reserved_mem.o
> > >  obj-$(CONFIG_OF_RESOLVE)  += resolver.o
> > > diff --git a/net/core/Makefile b/net/core/Makefile
> > > index 35ced6201814..37b1befc39aa 100644
> > > --- a/net/core/Makefile
> > > +++ b/net/core/Makefile
> > > @@ -36,3 +36,4 @@ obj-$(CONFIG_FAILOVER) += failover.o
> > >  obj-$(CONFIG_NET_SOCK_MSG) += skmsg.o
> > >  obj-$(CONFIG_BPF_SYSCALL) += sock_map.o
> > >  obj-$(CONFIG_BPF_SYSCALL) += bpf_sk_storage.o
> > > +obj-$(CONFIG_OF_NET)   += of_net.o
> >
> > The OF_NET kconfig should move or disappear too. I imagine you can do just:
>
> It is used in a few places:

Okay, then just move it for now.

I suspect though that most of these can either be dropped or replaced
with just 'OF' dependency.

> net/ethernet/litex/Kconfig:     depends on OF_NET
> net/ethernet/amd/Kconfig:       depends on ((OF_NET && OF_ADDRESS) || ACPI || PCI) && HAS_IOMEM

If the driver depends on OF or ACPI, then the dependency should just
be removed because one of those is almost always enabled.

> net/ethernet/mscc/Kconfig:      depends on OF_NET
> net/ethernet/ezchip/Kconfig:    depends on OF_IRQ && OF_NET
> net/ethernet/arc/Kconfig:       depends on OF_IRQ && OF_NET
> net/ethernet/arc/Kconfig:       depends on OF_IRQ && OF_NET && REGULATOR

I don't see any OF_IRQ dependency (which would be odd). The OF_NET
dependency is just of_get_phy_mode() from a quick glance and we have a
stub for it.

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ