| Submitter | Ben Hutchings |
|---|---|
| Date | Dec. 12, 2008, 12:53 p.m. |
| Message ID | <20081212125306.GM10372@solarflare.com> |
| Download | mbox | patch |
| Permalink | /patch/13715/ |
| State | Accepted |
| Delegated to: | David Miller |
| Headers | show |
Comments
From: Ben Hutchings <bhutchings@solarflare.com> Date: Fri, 12 Dec 2008 12:53:07 +0000 > The loopback self-test checks that IP packets with incorrect checksums > are not altered when sent on a queue with checksum generation off. > These should not contribute to RX error statistics. > > Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Applied. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Patch
diff --git a/drivers/net/sfc/falcon.c b/drivers/net/sfc/falcon.c index 7421945..dbab9db 100644 --- a/drivers/net/sfc/falcon.c +++ b/drivers/net/sfc/falcon.c @@ -784,15 +784,18 @@ static void falcon_handle_rx_not_ok(struct efx_rx_queue *rx_queue, rx_ev_buf_owner_id_err | rx_ev_eth_crc_err | rx_ev_frm_trunc | rx_ev_ip_hdr_chksum_err); - /* Count errors that are not in MAC stats. */ + /* Count errors that are not in MAC stats. Ignore expected + * checksum errors during self-test. */ if (rx_ev_frm_trunc) ++rx_queue->channel->n_rx_frm_trunc; else if (rx_ev_tobe_disc) ++rx_queue->channel->n_rx_tobe_disc; - else if (rx_ev_ip_hdr_chksum_err) - ++rx_queue->channel->n_rx_ip_hdr_chksum_err; - else if (rx_ev_tcp_udp_chksum_err) - ++rx_queue->channel->n_rx_tcp_udp_chksum_err; + else if (!efx->loopback_selftest) { + if (rx_ev_ip_hdr_chksum_err) + ++rx_queue->channel->n_rx_ip_hdr_chksum_err; + else if (rx_ev_tcp_udp_chksum_err) + ++rx_queue->channel->n_rx_tcp_udp_chksum_err; + } if (rx_ev_ip_frag_err) ++rx_queue->channel->n_rx_ip_frag_err;
The loopback self-test checks that IP packets with incorrect checksums are not altered when sent on a queue with checksum generation off. These should not contribute to RX error statistics. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> --- drivers/net/sfc/falcon.c | 13 ++++++++----- 1 files changed, 8 insertions(+), 5 deletions(-)