From owner-svn-src-stable-8@FreeBSD.ORG Sat Jun 18 11:54:44 2011 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 831CD106566B; Sat, 18 Jun 2011 11:54:44 +0000 (UTC) (envelope-from bschmidt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 71FB08FC08; Sat, 18 Jun 2011 11:54:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id p5IBsidh039626; Sat, 18 Jun 2011 11:54:44 GMT (envelope-from bschmidt@svn.freebsd.org) Received: (from bschmidt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id p5IBsioO039624; Sat, 18 Jun 2011 11:54:44 GMT (envelope-from bschmidt@svn.freebsd.org) Message-Id: <201106181154.p5IBsioO039624@svn.freebsd.org> From: Bernhard Schmidt Date: Sat, 18 Jun 2011 11:54:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r223246 - stable/8/sys/dev/iwn X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 Jun 2011 11:54:44 -0000 Author: bschmidt Date: Sat Jun 18 11:54:44 2011 New Revision: 223246 URL: http://svn.freebsd.org/changeset/base/223246 Log: MFC r220719: Remove if_ierrors which do not necessarily indicate a RX error, also do account send packets. While here use the IWN_TX_FAIL constant. Modified: stable/8/sys/dev/iwn/if_iwn.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) Modified: stable/8/sys/dev/iwn/if_iwn.c ============================================================================== --- stable/8/sys/dev/iwn/if_iwn.c Sat Jun 18 11:52:58 2011 (r223245) +++ stable/8/sys/dev/iwn/if_iwn.c Sat Jun 18 11:54:44 2011 (r223246) @@ -2069,7 +2069,6 @@ iwn_rx_done(struct iwn_softc *sc, struct if (!sc->last_rx_valid) { DPRINTF(sc, IWN_DEBUG_ANY, "%s: missing RX_PHY\n", __func__); - ifp->if_ierrors++; return; } sc->last_rx_valid = 0; @@ -2083,7 +2082,6 @@ iwn_rx_done(struct iwn_softc *sc, struct device_printf(sc->sc_dev, "%s: invalid rx statistic header, len %d\n", __func__, stat->cfg_phy_len); - ifp->if_ierrors++; return; } if (desc->type == IWN_MPDU_RX_DONE) { @@ -2427,11 +2425,12 @@ iwn_tx_done(struct iwn_softc *sc, struct /* * Update rate control statistics for the node. */ - if (status & 0x80) { + if (status & IWN_TX_FAIL) { ifp->if_oerrors++; ieee80211_ratectl_tx_complete(vap, ni, IEEE80211_RATECTL_TX_FAILURE, &ackfailcnt, NULL); } else { + ifp->if_opackets++; ieee80211_ratectl_tx_complete(vap, ni, IEEE80211_RATECTL_TX_SUCCESS, &ackfailcnt, NULL); }