summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorStefan Sperling <stsp@cvs.openbsd.org>2017-05-19 11:30:41 +0000
committerStefan Sperling <stsp@cvs.openbsd.org>2017-05-19 11:30:41 +0000
commit24ef1453340684961a82ae17005e9ba43aa6455d (patch)
tree52d54d0d6f8a603a9b9680b72064be0e75e4e67a /sys/dev
parent0ba85a9c19a0fb2be753fce73f6c775ee94437d7 (diff)
Make rtwn(4) add frames which failed to transmit to AMRR's transmit counter.
More closely matches what other drivers are doing.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/if_rtwn.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/pci/if_rtwn.c b/sys/dev/pci/if_rtwn.c
index 38708a34c77..754af774d44 100644
--- a/sys/dev/pci/if_rtwn.c
+++ b/sys/dev/pci/if_rtwn.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_rtwn.c,v 1.27 2017/05/19 10:53:33 stsp Exp $ */
+/* $OpenBSD: if_rtwn.c,v 1.28 2017/05/19 11:30:40 stsp Exp $ */
/*-
* Copyright (c) 2010 Damien Bergamini <damien.bergamini@free.fr>
@@ -1761,9 +1761,8 @@ rtwn_tx_report(struct rtwn_pci_softc *sc, uint8_t *buf, int len)
over = (rpt->rptb6 & R92C_RPTB6_RETRY_OVER);
if (packets > 0) {
- if (tx_ok)
- sc->amn.amn_txcnt += packets;
- if (tries > 1 || drop || expire || over)
+ sc->amn.amn_txcnt += packets;
+ if (!tx_ok || tries > 1 || drop || expire || over)
sc->amn.amn_retrycnt++;
}
}