aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShannon Nelson <[email protected]>2024-09-06 16:26:17 -0700
committerJakub Kicinski <[email protected]>2024-09-09 19:18:14 -0700
commit4a0ec34870a2d278373897cf182cbe662d559eb2 (patch)
tree9065cc6bbca9910e27c32477db64ce6d34223a02
parent760664b72c415e349dc4e64a74cd220c131f3948 (diff)
ionic: debug line for Tx completion errors
Here's a little debugging aid in case the device starts throwing Tx completion errors. Signed-off-by: Shannon Nelson <[email protected]> Signed-off-by: Brett Creeley <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
-rw-r--r--drivers/net/ethernet/pensando/ionic/ionic_txrx.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/net/ethernet/pensando/ionic/ionic_txrx.c b/drivers/net/ethernet/pensando/ionic/ionic_txrx.c
index fc79baad4561..ccdc0eefabe4 100644
--- a/drivers/net/ethernet/pensando/ionic/ionic_txrx.c
+++ b/drivers/net/ethernet/pensando/ionic/ionic_txrx.c
@@ -648,7 +648,14 @@ static void ionic_rx_clean(struct ionic_queue *q,
stats = q_to_rx_stats(q);
- if (comp->status) {
+ if (unlikely(comp->status)) {
+ /* Most likely status==2 and the pkt received was bigger
+ * than the buffer available: comp->len will show the
+ * pkt size received that didn't fit the advertised desc.len
+ */
+ dev_dbg(q->dev, "q%d drop comp->status %d comp->len %d desc->len %d\n",
+ q->index, comp->status, comp->len, q->rxq[q->head_idx].len);
+
stats->dropped++;
return;
}