[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+h21hq8G2fMZenAF_inYxQXePJe41Lk6U8AsJ-7e19YYTp7Wg@mail.gmail.com>
Date: Fri, 4 Oct 2019 11:44:02 +0300
From: Vladimir Oltean <olteanv@...il.com>
To: Andrew Lunn <andrew@...n.ch>
Cc: David Miller <davem@...emloft.net>,
netdev <netdev@...r.kernel.org>,
Vivien Didelot <vivien.didelot@...il.com>,
Florian Fainelli <f.fainelli@...il.com>
Subject: Re: [PATCH net-next 0/2] mv88e6xxx: Allow config of ATU hash algorithm
Hi Andrew,
On Fri, 4 Oct 2019 at 10:55, Andrew Lunn <andrew@...n.ch> wrote:
>
> The Marvell switches allow the hash algorithm for MAC addresses in the
> address translation unit to be configured. Add support to the DSA core
> to allow DSA drivers to make use of devlink parameters, and allow the
> ATU hash to be get/set via such a parameter.
>
What is the hash algorithm used by mv88e6xxx? In sja1105 it is simply
crc32 over the {DMAC, VLAN} key, with a configurable polynomial
(stored in Koopman notation, but that is maybe irrelevant).
Are you really changing the algorithm, but only the hashing function's seed?
If the sja1105 is in any way similar to mv88e6xxx, maybe it would make
sense to devise a more generic devlink attribute?
Also, I believe the hashing function is only relevant if the ATU's CAM
is set- (not fully-) associative. Then it would make sense to maybe
let the user know what the total number of FDB entries and buckets is?
I am not clear even after looking at the mv88e6xxx_g1_atu_* functions.
How would they know they need to change the hash function, and what to
change it to?
> Andrew Lunn (2):
> net: dsa: Add support for devlink device parameters
> net: dsa: mv88e6xxx: Add devlink param for ATU hash algorithm.
>
> drivers/net/dsa/mv88e6xxx/chip.c | 136 +++++++++++++++++++++++-
> drivers/net/dsa/mv88e6xxx/chip.h | 4 +
> drivers/net/dsa/mv88e6xxx/global1.h | 3 +
> drivers/net/dsa/mv88e6xxx/global1_atu.c | 30 ++++++
> include/net/dsa.h | 23 ++++
> net/dsa/dsa.c | 48 +++++++++
> net/dsa/dsa2.c | 7 +-
> 7 files changed, 249 insertions(+), 2 deletions(-)
>
> --
> 2.23.0
>
Regards,
-Vladimir
Powered by blists - more mailing lists