From owner-svn-src-all@freebsd.org Mon Dec 18 02:34:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A3CBEE9E15F; Mon, 18 Dec 2017 02:34:38 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6E1A766AE7; Mon, 18 Dec 2017 02:34:38 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBI2Ybsk034656; Mon, 18 Dec 2017 02:34:37 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBI2YbnB034655; Mon, 18 Dec 2017 02:34:37 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201712180234.vBI2YbnB034655@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Mon, 18 Dec 2017 02:34:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r326925 - head/sys/arm/broadcom/bcm2835 X-SVN-Group: head X-SVN-Commit-Author: ian X-SVN-Commit-Paths: head/sys/arm/broadcom/bcm2835 X-SVN-Commit-Revision: 326925 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 02:34:38 -0000 Author: ian Date: Mon Dec 18 02:34:37 2017 New Revision: 326925 URL: https://svnweb.freebsd.org/changeset/base/326925 Log: Do not attempt to refill the TX fifo if there is no data left to transfer. A comment in bcm_bsc_fill_tx_fifo() even lists sc_totlen > 0 as a precondition for calling the routine. I apparently forgot to make the code do what my comment said. Modified: head/sys/arm/broadcom/bcm2835/bcm2835_bsc.c Modified: head/sys/arm/broadcom/bcm2835/bcm2835_bsc.c ============================================================================== --- head/sys/arm/broadcom/bcm2835/bcm2835_bsc.c Mon Dec 18 00:15:53 2017 (r326924) +++ head/sys/arm/broadcom/bcm2835/bcm2835_bsc.c Mon Dec 18 02:34:37 2017 (r326925) @@ -508,7 +508,7 @@ bcm_bsc_intr(void *arg) * transfer is complete; TXD will be asserted along with ERR or * DONE if there is room in the fifo. */ - if (status & BCM_BSC_STATUS_TXD) + if ((status & BCM_BSC_STATUS_TXD) && sc->sc_totlen > 0) bcm_bsc_fill_tx_fifo(sc); }