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]
Date:   Fri, 15 Jul 2022 22:25:40 +0300
From:   Andy Shevchenko <>
To:     Marcin Wojtas <>
Subject: Re: [net-next: PATCH v2 3/8] net: dsa: switch to device_/fwnode_ APIs

On Fri, Jul 15, 2022 at 10:50:07AM +0200, Marcin Wojtas wrote:
> In order to support both ACPI and DT, modify the generic
> DSA code to use device_/fwnode_ equivalent routines.
> Drop using port's dn field and use only fwnode - update
> all dependent drivers.
> Because support for more generic fwnode is added,
> replace '_of' suffix with '_fw' in related routines.
> No functional change is introduced by this patch.

It's a bit too narrow text in the commit message, can you use more width?


> -		ret = of_get_phy_mode(dsa_to_port(ds, 5)->dn, &interface);
> +		ret = of_get_phy_mode(to_of_node(dsa_to_port(ds, 5)->fwnode), &interface);

So, I believe this is expected to be a temporary change and something like
fwnode_get_phy_mode() is on its way, correct?


> -			phy_handle = of_parse_phandle(dp->dn, "phy-handle", 0);
> +			phy_handle = of_parse_phandle(to_of_node(dp->fwnode), "phy-handle", 0);

This can be translated to fwnode_find_reference(), but it might require more

Actually you may start from converting drivers one-by-one to fwnode
APIs (as much as it's possible), and then do with a library call. Up to you.

With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists