]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_qdisc: Extract a common leaf unoffload function
authorPetr Machata <petrm@mellanox.com>
Fri, 24 Jan 2020 13:23:09 +0000 (15:23 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sat, 25 Jan 2020 09:56:31 +0000 (10:56 +0100)
commit4512d9ffc33a89db5513716cb4cee4242d5aab0b
tree51431676f7d2f1e616f63dcc5f1bcb652ccddb42
parent36e8fe75875556aea4b6eb3323a25514b449b4a2
mlxsw: spectrum_qdisc: Extract a common leaf unoffload function

When the RED Qdisc is unoffloaded, it needs to reduce the reported backlog
by the amount that is in the HW, so that only the SW backlog is contained
in the counter. The same thing will need to be done by TBF, and likely any
other leaf Qdisc as well.

Extract a helper mlxsw_sp_qdisc_leaf_unoffload() and call it from
mlxsw_sp_qdisc_red_unoffload().

Signed-off-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c