]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: felix: use vcap policer to set flow meter for psfp
authorXiaoliang Yang <xiaoliang.yang_1@nxp.com>
Thu, 18 Nov 2021 10:12:03 +0000 (18:12 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 18 Nov 2021 12:07:24 +0000 (12:07 +0000)
commit630641c1090218dc521e8e73e71a18234c73cf94
tree96521f5bb457933c4a2e533ffe2513a0d26711a3
parent6d4d27aacbf401875fb837d5587f4d4e260e3b69
net: dsa: felix: use vcap policer to set flow meter for psfp

This patch add police action to set flow meter table which is defined
in IEEE802.1Qci. Flow metering is two rates two buckets and three color
marker to policing the frames, we only enable one rate one bucket in
this patch.

Flow metering shares a same policer pool with VCAP policers, so the PSFP
policer calls ocelot_vcap_policer_add() and ocelot_vcap_policer_del() to
set flow meter police.

Signed-off-by: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/ocelot/felix_vsc9959.c