OSDN Git Service

net: dsa: hellcreek: Report FDB table occupancy
authorKurt Kanzenbach <kurt@kmk-computers.de>
Sat, 30 Jan 2021 13:59:34 +0000 (14:59 +0100)
committerJakub Kicinski <kuba@kernel.org>
Tue, 2 Feb 2021 02:28:34 +0000 (18:28 -0800)
commit8486e83fe1d8534ae964cb12c6852a824c12318b
treeb38b5970bd9d6360bf7809b921de0a6865a3c7a8
parent7f976d5cf16d0a747098f67831d746fa25f18dbe
net: dsa: hellcreek: Report FDB table occupancy

Report the FDB table size and occupancy via devlink. The actual size depends on
the used Hellcreek version:

|root@tsn:~# devlink resource show platform/ff240000.switch
|platform/ff240000.switch:
|  name VLAN size 4096 occ 2 unit entry dpipe_tables none
|  name FDB size 256 occ 6 unit entry dpipe_tables none

Suggested-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Kurt Kanzenbach <kurt@kmk-computers.de>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/dsa/hirschmann/hellcreek.c
drivers/net/dsa/hirschmann/hellcreek.h