mbox series

[russell-kings-net-queue,0/2] net: dsa: mv88e6xxx: fill phylink's supported interfaces to make SFP modules work under DSA ports

Message ID 20201020170912.25959-1-kabel@kernel.org (mailing list archive)
Headers show
Series net: dsa: mv88e6xxx: fill phylink's supported interfaces to make SFP modules work under DSA ports | expand

Message

Marek Behún Oct. 20, 2020, 5:09 p.m. UTC
Hi Russell,

this series applies on your net-queue branch.

It adds a new DSA switch operation which is used to determine a DSA
switch port's supported PHY interface modes to fill in phylink's config
supported_interfaces member to make SFP modules work under DSA ports.

This operation is then implemented for mv88e6xxx.

I was thinking whether this method should be renamed to something like
serdes_supported_interfaces or what, so that it is clear that we are
not interested in RGMII and other non-SERDES modes...

BTW: You once complained that you don't like that this needs again to
add a new op to DSA switch and for mv88e6xxx driver to add a new op for
the each chip... So maybe phylink_validate code can be refactored to do
this?
My opinion is that it is cleaner if we just add another op, but I am
open to other opinions.

Marek

Marek Behún (2):
  net: dsa: fill phylink's config supported_interfaces member
  net: dsa: mv88e6xxx: implement .phylink_get_interfaces operation

 drivers/net/dsa/mv88e6xxx/chip.c | 57 ++++++++++++++++++++++++++++++++
 drivers/net/dsa/mv88e6xxx/chip.h |  2 ++
 include/net/dsa.h                |  2 ++
 net/dsa/slave.c                  |  4 +++
 4 files changed, 65 insertions(+)


base-commit: a32e90737c1c92653767d3c95c63c16b9b72c6c2
prerequisite-patch-id: 74af250a98f8d7d48da6b7655000995dd9d9310b
prerequisite-patch-id: 1ab9d0fedae2be621a821aac01ebf680627279d3
prerequisite-patch-id: 24af4837bacf2f8c9afcedd497a7d61c7cb7cdf1