[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2e5e9280-5c02-7032-b6f3-c5a3f75eba35@gmail.com>
Date: Mon, 6 Nov 2017 15:17:44 -0800
From: Florian Fainelli <f.fainelli@...il.com>
To: Andrew Lunn <andrew@...n.ch>, David Miller <davem@...emloft.net>
Cc: netdev <netdev@...r.kernel.org>,
Vivien Didelot <vivien.didelot@...oirfairelinux.com>
Subject: Re: [PATCH v2 net-next 1/6] net: dsa: Fix
SWITCHDEV_ATTR_ID_PORT_PARENT_ID
On 11/06/2017 03:02 PM, Andrew Lunn wrote:
> SWITCHDEV_ATTR_ID_PORT_PARENT_ID is used by the software bridge when
> determining which ports to flood a packet out. If the packet
> originated from a switch, it assumes the switch has already flooded
> the packet out the switches ports, so the bridge should not flood the
> packet itself out switch ports. Ports on the same switch are expected
> to return the same parent ID when SWITCHDEV_ATTR_ID_PORT_PARENT_ID is
> called.
>
> DSA gets this wrong with clusters of switches. As far as the software
> bridge is concerned, the cluster is all one switch. A packet from any
> switch in the cluster can be assumed to have been flooded as needed
> out of all ports of the cluster, not just the switch it originated
> from. Hence all ports of a cluster should return the same parent. The
> old implementation did not, each switch in the cluster had its own ID.
>
> Also wrong was that the ID was not unique if multiple DSA instances
> are in operation.
>
> Use the tree ID as the parent ID, which is the same for all switches
> in a cluster and unique across switch clusters.
>
> Signed-off-by: Andrew Lunn <andrew@...n.ch>
> Reviewed-by: Vivien Didelot <vivien.didelot@...oirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
--
Florian
Powered by blists - more mailing lists