Skip to contentSkip to conversation

liquidio: fix VF driver off-by-one bug when setting ethtool -C ethX rx-frames

PATCH Applied Felix Manlunas 2 participants 2 messages Jun 14, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 liquidio: fix VF driver off-by-one bug when setting ethtool -C ethX rx-frames

From: Weilin Chang <[email protected]>

---
 drivers/net/ethernet/cavium/liquidio/lio_ethtool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/cavium/liquidio/lio_ethtool.c +1 -1
index 53856af..28ecda3 100644
@@ -1808,7 +1808,7 @@ oct_cfg_rx_intrcnt(struct lio *lio,
 			    (octeon_read_csr64(
 				 oct, CN23XX_VF_SLI_OQ_PKT_INT_LEVELS(q_no)) &
 			     (0x3fffff00000000UL)) |
-				rx_max_coalesced_frames);
+				(rx_max_coalesced_frames - 1));
 			/*consider writing to resend bit here*/
 		}
 		intrmod->rx_frames = rx_max_coalesced_frames;