[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d2cd2da8-ff65-fa63-96a6-a388c228854b@gmail.com>
Date: Mon, 7 Feb 2022 19:02:26 -0800
From: Florian Fainelli <f.fainelli@...il.com>
To: Prasanna Vengateshan <prasanna.vengateshan@...rochip.com>,
andrew@...n.ch, netdev@...r.kernel.org, olteanv@...il.com,
robh+dt@...nel.org
Cc: UNGLinuxDriver@...rochip.com, woojung.huh@...rochip.com,
hkallweit1@...il.com, linux@...linux.org.uk, davem@...emloft.net,
kuba@...nel.org, linux-kernel@...r.kernel.org,
vivien.didelot@...il.com, devicetree@...r.kernel.org
Subject: Re: [PATCH v8 net-next 09/10] net: dsa: microchip: add support for
fdb and mdb management
On 2/7/2022 9:22 AM, Prasanna Vengateshan wrote:
> Support for fdb_add, mdb_add, fdb_del, mdb_del and
> fdb_dump operations. ALU1 and ALU2 are used for fdb operations.
>
> fdb_add: find any existing entries and update the port map.
> if ALU1 write is failed and attempt to write ALU2.
> If ALU2 is also failed then exit. Clear WRITE_FAIL for both ALU1
> & ALU2.
>
> fdb_del: find the matching entry and clear the respective port
> in the port map by writing the ALU tables
>
> fdb_dump: read and dump 2 ALUs upto last entry. ALU_START bit is
> used to find the last entry. If the read is timed out, then pass
> the error message.
>
> mdb_add: Find the empty slot in ALU and update the port map &
> mac address by writing the ALU
>
> mdb_del: find the matching entry and delete the respective port
> in port map by writing the ALU
>
> For MAC address, could not use upper_32_bits() & lower_32_bits()
> as per Vladimir proposal since it gets accessed in terms of 16bits.
> I tried to have common API to get 16bits based on index but shifting
> seems to be straight-forward.
>
> Signed-off-by: Prasanna Vengateshan <prasanna.vengateshan@...rochip.com>
> Reviewed-by: Vladimir Oltean <olteanv@...il.com>
Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
--
Florian
Powered by blists - more mailing lists