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: <CAHp75Vfdt9CCHY+tpYXf-jPTxkN0v5Jo5CHojgfz=DAb3hcAmg@mail.gmail.com>
Date:   Tue, 12 Jan 2021 17:52:03 +0200
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Calvin Johnson <calvin.johnson@....nxp.com>
Cc:     Grant Likely <grant.likely@....com>,
        "Rafael J . Wysocki" <rafael@...nel.org>,
        Jeremy Linton <jeremy.linton@....com>,
        Andrew Lunn <andrew@...n.ch>,
        Florian Fainelli <f.fainelli@...il.com>,
        Russell King - ARM Linux admin <linux@...linux.org.uk>,
        Cristi Sovaiala <cristian.sovaiala@....com>,
        Florin Laurentiu Chiculita <florinlaurentiu.chiculita@....com>,
        Ioana Ciornei <ioana.ciornei@....com>,
        Madalin Bucur <madalin.bucur@....nxp.com>,
        Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
        Marcin Wojtas <mw@...ihalf.com>,
        Pieter Jansen Van Vuuren <pieter.jansenvv@...boosystems.io>,
        Jon <jon@...id-run.com>,
        Diana Madalina Craciun <diana.craciun@....com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        netdev <netdev@...r.kernel.org>,
        Laurentiu Tudor <laurentiu.tudor@....com>,
        ACPI Devel Maling List <linux-acpi@...r.kernel.org>,
        "linux.cj" <linux.cj@...il.com>,
        linux-arm Mailing List <linux-arm-kernel@...ts.infradead.org>,
        "David S. Miller" <davem@...emloft.net>,
        Heiner Kallweit <hkallweit1@...il.com>,
        Jakub Kicinski <kuba@...nel.org>
Subject: Re: [net-next PATCH v3 11/15] net: mdiobus: Introduce fwnode_mdiobus_register()

On Tue, Jan 12, 2021 at 3:42 PM Calvin Johnson
<calvin.johnson@....nxp.com> wrote:
>
> Introduce fwnode_mdiobus_register() to register PHYs on the  mdiobus.
> If the fwnode is DT node, then call of_mdiobus_register().
> If it is an ACPI node, then call acpi_mdiobus_register().

...

> +/**
> + * fwnode_mdiobus_register - Register mii_bus and create PHYs from fwnode
> + * @mdio: pointer to mii_bus structure
> + * @fwnode: pointer to fwnode of MDIO bus.
> + *
> + * This function returns of_mdiobus_register() for DT and
> + * acpi_mdiobus_register() for ACPI.
> + */
> +int fwnode_mdiobus_register(struct mii_bus *mdio, struct fwnode_handle *fwnode)
> +{
> +       if (is_of_node(fwnode))
> +               return of_mdiobus_register(mdio, to_of_node(fwnode));
> +       else if (is_acpi_node(fwnode))

Redundant 'else'

> +               return acpi_mdiobus_register(mdio, fwnode);
> +
> +       return -EINVAL;
> +}

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ