]> git.itanic.dy.fi Git - linux-stable/commit
net: ravb: Count packets instead of descriptors in R-Car RX path
authorPaul Barker <paul.barker.ct@bp.renesas.com>
Tue, 16 Apr 2024 12:02:51 +0000 (13:02 +0100)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 18 Apr 2024 09:34:28 +0000 (11:34 +0200)
commitdef52db470df28d6f43cacbd21137f03b9502073
tree40691fca2a9c96d1716b102794595efc73d15c68
parent94667949ec3bbb2218c46ad0a0e7274c8832e494
net: ravb: Count packets instead of descriptors in R-Car RX path

The units of "work done" in the RX path should be packets instead of
descriptors.

Descriptors which are used by the hardware to record error conditions or
are empty in the case of a DMA mapping error should not count towards
our RX work budget.

Also make the limit variable unsigned as it can never be negative.

Fixes: c156633f1353 ("Renesas Ethernet AVB driver proper")
Signed-off-by: Paul Barker <paul.barker.ct@bp.renesas.com>
Reviewed-by: Sergey Shtylyov <s.shtylyov@omp.ru>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/renesas/ravb_main.c