From owner-svn-src-user@FreeBSD.ORG Fri Sep 2 08:13:07 2011 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC2931065673; Fri, 2 Sep 2011 08:13:07 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9BD028FC17; Fri, 2 Sep 2011 08:13:07 +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 p828D77l088541; Fri, 2 Sep 2011 08:13:07 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id p828D74f088539; Fri, 2 Sep 2011 08:13:07 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201109020813.p828D74f088539@svn.freebsd.org> From: Adrian Chadd Date: Fri, 2 Sep 2011 08:13:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r225324 - user/adrian/if_ath_tx/sys/dev/ath X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 Sep 2011 08:13:07 -0000 Author: adrian Date: Fri Sep 2 08:13:07 2011 New Revision: 225324 URL: http://svn.freebsd.org/changeset/base/225324 Log: If the RX link pointer is NULL, RX DMA has been halted. This means the first buffer re-added to the list should be given to the hardware. This doesn't restart DMA by itself; I'l follow up with some tinkering to try and re-enable it without having to forcibly stop and restart the PCU. Whilst here, add a comment to point out another thing I need to tinker with. Obtained from: Linux, Atheros Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath.c ============================================================================== --- user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Fri Sep 2 08:00:57 2011 (r225323) +++ user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Fri Sep 2 08:13:07 2011 (r225324) @@ -3418,7 +3418,9 @@ ath_rxbuf_init(struct ath_softc *sc, str , 0 ); - if (sc->sc_rxlink != NULL) + if (sc->sc_rxlink == NULL) + ath_hal_putrxbuf(sc->sc_ah, bf->bf_daddr); + else *sc->sc_rxlink = bf->bf_daddr; sc->sc_rxlink = &ds->ds_link; return 0; @@ -3931,6 +3933,11 @@ rx_next: */ if (sc->sc_kickpcu) { sc->sc_kickpcu = 0; + /* + * XXX this causes a 3ms delay; and shuts down a lof + * XXX is it really needed? Or is it just enough to + * XXX kick the PCU again to continue RXing? + */ ath_stoprecv(sc); sc->sc_imask |= (HAL_INT_RXEOL | HAL_INT_RXORN); if (ath_startrecv(sc) != 0) {