OpenCloudOS-Kernel/drivers/net/dsa/sja1105
Vladimir Oltean a372d66af4 net: dsa: sja1105: always enable the send_meta options
incl_srcpt has the limitation, mentioned in commit b4638af888 ("net:
dsa: sja1105: always enable the INCL_SRCPT option"), that frames with a
MAC DA of 01:80:c2:xx:yy:zz will be received as 01:80:c2:00:00:zz unless
PTP RX timestamping is enabled.

The incl_srcpt option was initially unconditionally enabled, then that
changed with commit 42824463d3 ("net: dsa: sja1105: Limit use of
incl_srcpt to bridge+vlan mode"), then again with b4638af888 ("net:
dsa: sja1105: always enable the INCL_SRCPT option"). Bottom line is that
it now needs to be always enabled, otherwise the driver does not have a
reliable source of information regarding source_port and switch_id for
link-local traffic (tag_8021q VLANs may be imprecise since now they
identify an entire bridging domain when ports are not standalone).

If we accept that PTP RX timestamping (and therefore, meta frame
generation) is always enabled in hardware, then that limitation could be
avoided and packets with any MAC DA can be properly received, because
meta frames do contain the original bytes from the MAC DA of their
associated link-local packet.

This change enables meta frame generation unconditionally, which also
has the nice side effects of simplifying the switch control path
(a switch reset is no longer required on hwtstamping settings change)
and the tagger data path (it no longer needs to be informed whether to
expect meta frames or not - it always does).

Fixes: 227d07a07e ("net: dsa: sja1105: Add support for traffic through standalone ports")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2023-07-04 19:42:27 +01:00
..
Kconfig ethernet: fix PTP_1588_CLOCK dependencies 2021-08-13 17:49:05 -07:00
Makefile net: dsa: sja1105: register the MDIO buses for 100base-T1 and 100base-TX 2021-06-08 14:37:16 -07:00
sja1105.h net: dsa: sja1105: always enable the send_meta options 2023-07-04 19:42:27 +01:00
sja1105_clocking.c net: dsa: sja1105: parse {rx, tx}-internal-delay-ps properties for RGMII delays 2021-10-20 11:32:28 +01:00
sja1105_devlink.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2022-12-08 18:19:59 -08:00
sja1105_dynamic_config.c net: dsa: sja1105: serialize access to the dynamic config interface 2021-10-25 12:59:41 +01:00
sja1105_dynamic_config.h net: dsa: sja1105: add support for the SJA1110 switch family 2021-06-08 14:37:16 -07:00
sja1105_ethtool.c net: dsa: sja1105: don't use burst SPI reads for port statistics 2021-05-21 14:01:41 -07:00
sja1105_flower.c flow_offload: reject offload for all drivers with invalid police parameters 2022-02-28 11:12:20 +00:00
sja1105_main.c net: dsa: sja1105: always enable the send_meta options 2023-07-04 19:42:27 +01:00
sja1105_mdio.c net: dsa: sja1105: use xpcs_create_mdiodev() 2023-06-05 11:26:02 +01:00
sja1105_ptp.c net: dsa: sja1105: always enable the send_meta options 2023-07-04 19:42:27 +01:00
sja1105_ptp.h Revert "net: dsa: move sja1110_process_meta_tstamp inside the tagging protocol driver" 2021-12-12 12:51:34 +00:00
sja1105_spi.c net: dsa: sja1105: C45 only transactions for PCS 2023-01-17 19:34:08 -08:00
sja1105_static_config.c net: update NXP copyright text 2021-09-17 13:52:17 +01:00
sja1105_static_config.h net: update NXP copyright text 2021-09-17 13:52:17 +01:00
sja1105_tas.c net/sched: taprio: replace tc_taprio_qopt_offload :: enable with a "cmd" enum 2023-05-31 10:00:30 +01:00
sja1105_tas.h net: dsa: sja1105: dimension the data structures for a larger port count 2021-05-24 13:59:03 -07:00
sja1105_vl.c net: dsa: tag_8021q: rename dsa_8021q_bridge_tx_fwd_offload_vid 2022-02-27 11:06:14 +00:00
sja1105_vl.h net: update NXP copyright text 2021-09-17 13:52:17 +01:00