From owner-freebsd-embedded@FreeBSD.ORG Mon Jul 14 20:37:16 2014 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CC665EB6; Mon, 14 Jul 2014 20:37:16 +0000 (UTC) Received: from zibbi.meraka.csir.co.za (zibbi.meraka.csir.co.za [146.64.24.58]) by mx1.freebsd.org (Postfix) with ESMTP id 033882107; Mon, 14 Jul 2014 20:37:15 +0000 (UTC) Received: by zibbi.meraka.csir.co.za (Postfix, from userid 3973) id E3C3CB842; Mon, 14 Jul 2014 22:37:07 +0200 (SAST) Date: Mon, 14 Jul 2014 22:37:07 +0200 From: John Hay To: Adrian Chadd Subject: Re: CAMBRIA and more than one atheros card Message-ID: <20140714203707.GB54311@zibbi.meraka.csir.co.za> References: <20140714184209.GA21922@zibbi.meraka.csir.co.za> <20140714190946.GA49930@zibbi.meraka.csir.co.za> <20140714191416.GB49930@zibbi.meraka.csir.co.za> <20140714194932.GA51947@zibbi.meraka.csir.co.za> <20140714200015.GA54311@zibbi.meraka.csir.co.za> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: "freebsd-wireless@freebsd.org" , "freebsd-embedded@freebsd.org" , Ian Lepore X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Jul 2014 20:37:17 -0000 On Mon, Jul 14, 2014 at 01:02:03PM -0700, Adrian Chadd wrote: > On 14 July 2014 13:00, John Hay wrote: > > On Mon, Jul 14, 2014 at 12:55:19PM -0700, Adrian Chadd wrote: > >> Right. What's the output of hw.ath ? > > > > tst-11-arm:~ # sysctl hw.ath > > hw.ath.bstuck: 4 > > hw.ath.txbuf_mgmt: 32 > > hw.ath.txbuf: 200 > > hw.ath.rxbuf: 40 > > hw.ath.anical: 100 > > hw.ath.resetcal: 1200 > > hw.ath.shortcal: 100 > > hw.ath.longcal: 30 > > hw.ath.debug: 0 > > hw.ath.hal.debug: 0 > > > > All 3 interfaces are in adhoc mode if it makes a difference. > > Ah, you're not even using it in 11n mode. Ok. > > Well, that's 72 mbufs allocated, and up to 200 more being allocated > during transmit. Then there's the handful of pages being used for DMA > descriptors. So yeah, over time that may become a problem. > > Try doubling the number of bounce buffers available and see what happens. The first boot looks good, all 3 aths came up. Bounce buffers just after login: tst-11-arm:~ # sysctl hw.busdma hw.busdma.total_bpages: 128 hw.busdma.zone0.total_bpages: 128 hw.busdma.zone0.free_bpages: 128 hw.busdma.zone0.reserved_bpages: 0 hw.busdma.zone0.active_bpages: 0 hw.busdma.zone0.total_bounced: 0 hw.busdma.zone0.total_deferred: 0 hw.busdma.zone0.lowaddr: 0x4000fff hw.busdma.zone0.alignment: 4096 It stayed like that for about 6-7 minutes, then looked like this: tst-11-arm:~ # sysctl hw.busdma hw.busdma.total_bpages: 128 hw.busdma.zone0.total_bpages: 128 hw.busdma.zone0.free_bpages: 126 hw.busdma.zone0.reserved_bpages: 0 hw.busdma.zone0.active_bpages: 2 hw.busdma.zone0.total_bounced: 208 hw.busdma.zone0.total_deferred: 0 hw.busdma.zone0.lowaddr: 0x4000fff hw.busdma.zone0.alignment: 4096 After 13 minutes: tst-11-arm:~ # sysctl hw.busdma hw.busdma.total_bpages: 128 hw.busdma.zone0.total_bpages: 128 hw.busdma.zone0.free_bpages: 124 hw.busdma.zone0.reserved_bpages: 0 hw.busdma.zone0.active_bpages: 4 hw.busdma.zone0.total_bounced: 667 hw.busdma.zone0.total_deferred: 0 hw.busdma.zone0.lowaddr: 0x4000fff hw.busdma.zone0.alignment: 4096 After 26 minutes: tst-11-arm:~ # sysctl hw.busdma hw.busdma.total_bpages: 128 hw.busdma.zone0.total_bpages: 128 hw.busdma.zone0.free_bpages: 121 hw.busdma.zone0.reserved_bpages: 0 hw.busdma.zone0.active_bpages: 7 hw.busdma.zone0.total_bounced: 2433 hw.busdma.zone0.total_deferred: 0 hw.busdma.zone0.lowaddr: 0x4000fff hw.busdma.zone0.alignment: 4096 Great! At last it seems like we are making progress. I'll leave it till the morning and then do a few reboots and then some traffic. One question, should the active bounce pages keep growing or stabilize somewhere? How do I know if I have to few or if there is a leak? Thanks Adrian for your help. John -- John Hay -- jhay@meraka.csir.co.za / jhay@meraka.org.za