mbox series

[v2,net-next,0/4] Validate OF nodes for DSA shared ports

Message ID 20220729132119.1191227-1-vladimir.oltean@nxp.com (mailing list archive)
Headers show
Series Validate OF nodes for DSA shared ports | expand

Message

Vladimir Oltean July 29, 2022, 1:21 p.m. UTC
This is the first set of measures taken so that more drivers can be
transitioned towards phylink on shared (CPU and DSA) ports some time in
the future. It consists of:

- introducing warnings for drivers that currently skip phylink due to
  incomplete DT descriptions.
- introducing warning for drivers that currently skip phylink due to
  using platform data (search for struct dsa_chip_data).
- closing the possibility for new(ish) drivers to skip phylink, by
  validating their DT descriptions.
- making the code paths used by shared ports more evident.
- preparing the code paths used by shared ports for further work to fake
  a link description where that is possible.

More details in patch 4/4. Patches 2 and 3 are DSA cleanups, and patch 1
is a dependency for patch 4.

v1 at
https://patchwork.kernel.org/project/netdevbpf/patch/20220723164635.1621911-1-vladimir.oltean@nxp.com/

Cc: Rob Herring <robh+dt@kernel.org>
Cc: Frank Rowand <frowand.list@gmail.com>

Vladimir Oltean (4):
  of: base: export of_device_compatible_match() for use in modules
  net: dsa: avoid dsa_port_link_{,un}register_of() calls with platform
    data
  net: dsa: rename dsa_port_link_{,un}register_of
  net: dsa: validate that DT nodes of shared ports have the properties
    they need

 drivers/of/base.c  |   1 +
 net/dsa/dsa2.c     |  36 ++++++---
 net/dsa/dsa_priv.h |   4 +-
 net/dsa/port.c     | 193 +++++++++++++++++++++++++++++++++++++++++----
 4 files changed, 207 insertions(+), 27 deletions(-)