net: dsa: felix: print error message in felix_check_xtr_pkt()

Packet extraction failures over register-based MMIO are silent, and
difficult to pinpoint. Add an error message to remedy this.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Vladimir Oltean 2022-03-03 16:01:25 +02:00 committed by David S. Miller
parent dbd032856b
commit 5d3bb7dda4
1 changed files with 5 additions and 1 deletions

View File

@ -1506,8 +1506,12 @@ static bool felix_check_xtr_pkt(struct ocelot *ocelot)
}
out:
if (err < 0)
if (err < 0) {
dev_err_ratelimited(ocelot->dev,
"Error during packet extraction: %pe\n",
ERR_PTR(err));
ocelot_drain_cpu_queue(ocelot, 0);
}
return true;
}