From fc054d563bfb676f808f26204dfe17c690eed1ba Mon Sep 17 00:00:00 2001 From: Claudiu Manoil Date: Mon, 25 Jan 2021 14:23:53 +0200 Subject: net: Introduce DSA class for Ethernet switches DSA stands for Distributed Switch Architecture and it covers switches that are connected to the CPU through an Ethernet link and generally use frame tags to pass information about the source/destination ports to/from CPU. Front panel ports are presented as regular ethernet devices in U-Boot and they are expected to support the typical networking commands. DSA switches may be cascaded, DSA class code does not currently support this. Signed-off-by: Alex Marginean Signed-off-by: Claudiu Manoil Reviewed-by: Simon Glass Signed-off-by: Vladimir Oltean --- include/net.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/net.h') diff --git a/include/net.h b/include/net.h index 13da69b7c14..b95d6a6f60e 100644 --- a/include/net.h +++ b/include/net.h @@ -499,7 +499,13 @@ struct icmp_hdr { * maximum packet size and multiple of 32 bytes = 1536 */ #define PKTSIZE 1522 +#ifndef CONFIG_DM_DSA #define PKTSIZE_ALIGN 1536 +#else +/* Maximum DSA tagging overhead (headroom and/or tailroom) */ +#define DSA_MAX_OVR 256 +#define PKTSIZE_ALIGN (1536 + DSA_MAX_OVR) +#endif /* * Maximum receive ring size; that is, the number of packets -- cgit v1.2.3