From 3b17804fc6c876a06edec009066a5bb44df1caa9 Mon Sep 17 00:00:00 2001 From: mycroft Date: Mon, 27 Dec 2004 10:17:38 +0000 Subject: Use the last descriptor to count collisions and failed transmissions, too. --- sys/dev/ic/rtw.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sys/dev/ic/rtw.c b/sys/dev/ic/rtw.c index 311159d4db2..799f7e39791 100644 --- a/sys/dev/ic/rtw.c +++ b/sys/dev/ic/rtw.c @@ -1,4 +1,4 @@ -/* $NetBSD: rtw.c,v 1.27 2004/12/27 09:40:18 mycroft Exp $ */ +/* $NetBSD: rtw.c,v 1.28 2004/12/27 10:17:38 mycroft Exp $ */ /*- * Copyright (c) 2004, 2005 David Young. All rights reserved. * @@ -34,7 +34,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: rtw.c,v 1.27 2004/12/27 09:40:18 mycroft Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rtw.c,v 1.28 2004/12/27 10:17:38 mycroft Exp $"); #include "bpfilter.h" @@ -1464,17 +1464,16 @@ rtw_collect_txpkt(struct rtw_softc *sc, struct rtw_txdesc_blk *htc, { uint32_t hstat; int data_retry, rts_retry; - struct rtw_txdesc *htx0, *htxn; + struct rtw_txdesc *htxn; const char *condstring; rtw_txbuf_release(sc->sc_dmat, &sc->sc_ic, stx); htc->htc_nfree += ndesc; - htx0 = &htc->htc_desc[stx->stx_first]; htxn = &htc->htc_desc[stx->stx_last]; - hstat = le32toh(htx0->htx_stat); + hstat = le32toh(htxn->htx_stat); rts_retry = MASK_AND_RSHIFT(hstat, RTW_TXSTAT_RTSRETRY_MASK); data_retry = MASK_AND_RSHIFT(hstat, RTW_TXSTAT_DRC_MASK); -- cgit