Message ID | 20220620150225.1307946-5-mw@semihalf.com (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | ACPI support for DSA | expand |
Context | Check | Description |
---|---|---|
netdev/tree_selection | success | Clearly marked for net-next, async |
netdev/fixes_present | success | Fixes tag not required for -next series |
netdev/subject_prefix | success | Link |
netdev/cover_letter | success | Series has a cover letter |
netdev/patch_count | success | Link |
netdev/header_inline | success | No static functions without inline keyword in header files |
netdev/build_32bit | success | Errors and warnings before: 6 this patch: 6 |
netdev/cc_maintainers | success | CCed 7 of 7 maintainers |
netdev/build_clang | success | Errors and warnings before: 0 this patch: 0 |
netdev/module_param | success | Was 0 now: 0 |
netdev/verify_signedoff | success | Signed-off-by tag matches author and committer |
netdev/check_selftest | success | No net selftest shell script |
netdev/verify_fixes | success | No Fixes tag |
netdev/build_allmodconfig_warn | success | Errors and warnings before: 6 this patch: 6 |
netdev/checkpatch | success | total: 0 errors, 0 warnings, 0 checks, 7 lines checked |
netdev/kdoc | success | Errors and warnings before: 0 this patch: 0 |
netdev/source_inline | success | Was 0 now: 0 |
On Mon, Jun 20, 2022 at 05:02:17PM +0200, Marcin Wojtas wrote: > As a preparation to switch the DSA subsystem from using > of_find_net_device_by_node() to its more generic fwnode_ > equivalent, the port's device structure should be updated > with its fwnode pointer, similarly to of_node - see analogous > commit c4053ef32208 ("net: mvpp2: initialize port of_node pointer"). > > This patch is required to prevent a regression before updating > the DSA API on boards that connect the mvpp2 port to switch, > such as Clearfog GT-8K or CN913x CEx7 Evaluation Board. ... > dev->dev.of_node = port_node; > + dev->dev.fwnode = port_fwnode; device_set_node() ?
On Mon, Jun 20, 2022 at 08:43:05PM +0300, Andy Shevchenko wrote: > On Mon, Jun 20, 2022 at 05:02:17PM +0200, Marcin Wojtas wrote: > > As a preparation to switch the DSA subsystem from using > > of_find_net_device_by_node() to its more generic fwnode_ > > equivalent, the port's device structure should be updated > > with its fwnode pointer, similarly to of_node - see analogous > > commit c4053ef32208 ("net: mvpp2: initialize port of_node pointer"). > > > > This patch is required to prevent a regression before updating > > the DSA API on boards that connect the mvpp2 port to switch, > > such as Clearfog GT-8K or CN913x CEx7 Evaluation Board. > > ... > > > dev->dev.of_node = port_node; > > + dev->dev.fwnode = port_fwnode; > > device_set_node() ? Ah, important remark to all device_set_node() comments. It assumes that you replace _both_ assignments with _single_ call.
pon., 20 cze 2022 o 19:44 Andy Shevchenko <andriy.shevchenko@linux.intel.com> napisał(a): > > On Mon, Jun 20, 2022 at 08:43:05PM +0300, Andy Shevchenko wrote: > > On Mon, Jun 20, 2022 at 05:02:17PM +0200, Marcin Wojtas wrote: > > > As a preparation to switch the DSA subsystem from using > > > of_find_net_device_by_node() to its more generic fwnode_ > > > equivalent, the port's device structure should be updated > > > with its fwnode pointer, similarly to of_node - see analogous > > > commit c4053ef32208 ("net: mvpp2: initialize port of_node pointer"). > > > > > > This patch is required to prevent a regression before updating > > > the DSA API on boards that connect the mvpp2 port to switch, > > > such as Clearfog GT-8K or CN913x CEx7 Evaluation Board. > > > > ... > > > > > dev->dev.of_node = port_node; > > > + dev->dev.fwnode = port_fwnode; > > > > device_set_node() ? > > Ah, important remark to all device_set_node() comments. It assumes that you > replace _both_ assignments with _single_ call. > OK, will do. Thanks, Marcin
diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c index b84128b549b4..cd2f113bb1a4 100644 --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c @@ -6869,6 +6869,7 @@ static int mvpp2_port_probe(struct platform_device *pdev, /* 9704 == 9728 - 20 and rounding to 8 */ dev->max_mtu = MVPP2_BM_JUMBO_PKT_SIZE; dev->dev.of_node = port_node; + dev->dev.fwnode = port_fwnode; port->pcs_gmac.ops = &mvpp2_phylink_gmac_pcs_ops; port->pcs_xlg.ops = &mvpp2_phylink_xlg_pcs_ops;
As a preparation to switch the DSA subsystem from using of_find_net_device_by_node() to its more generic fwnode_ equivalent, the port's device structure should be updated with its fwnode pointer, similarly to of_node - see analogous commit c4053ef32208 ("net: mvpp2: initialize port of_node pointer"). This patch is required to prevent a regression before updating the DSA API on boards that connect the mvpp2 port to switch, such as Clearfog GT-8K or CN913x CEx7 Evaluation Board. Signed-off-by: Marcin Wojtas <mw@semihalf.com> --- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 1 + 1 file changed, 1 insertion(+)