From owner-freebsd-embedded@FreeBSD.ORG Mon Apr 21 11:06:46 2008 Return-Path: Delivered-To: freebsd-embedded@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 50D2910656AE for ; Mon, 21 Apr 2008 11:06:46 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 3F6A08FC24 for ; Mon, 21 Apr 2008 11:06:46 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m3LB6ksO095112 for ; Mon, 21 Apr 2008 11:06:46 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m3LB6jx4095108 for freebsd-embedded@FreeBSD.org; Mon, 21 Apr 2008 11:06:45 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 21 Apr 2008 11:06:45 GMT Message-Id: <200804211106.m3LB6jx4095108@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-embedded@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-embedded@FreeBSD.org X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Apr 2008 11:06:46 -0000 Current FreeBSD problem reports Critical problems Serious problems Non-critical problems S Tracker Resp. Description -------------------------------------------------------------------------------- o misc/15876 embedded [picobsd] PicoBSD message of the day problems o misc/28255 embedded [picobsd] picobsd documentation still references old . o kern/42728 embedded [picobsd] many problems in src/usr.sbin/ppp/* after c o misc/52256 embedded [picobsd] picobsd build script does not read in user/s o kern/101228 embedded [nanobsd] [patch] Two more entries for FlashDevice.sub 5 problems total. From owner-freebsd-embedded@FreeBSD.ORG Mon Apr 21 17:32:55 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 330451065671; Mon, 21 Apr 2008 17:32:55 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: from mail.eecs.harvard.edu (bowser.eecs.harvard.edu [140.247.60.24]) by mx1.freebsd.org (Postfix) with ESMTP id 189268FC0A; Mon, 21 Apr 2008 17:32:55 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: by mail.eecs.harvard.edu (Postfix, from userid 33141) id 1890E1A5273; Mon, 21 Apr 2008 13:13:05 -0400 (EDT) Date: Mon, 21 Apr 2008 13:13:05 -0400 From: Geoffrey Mainland To: freebsd-embedded@freebsd.org Message-ID: <20080421171305.GA19840@eecs.harvard.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i Cc: freebsd-usb@freebsd.org Subject: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Apr 2008 17:32:55 -0000 I have a number of Soekris 4826 boards with USB thumb drives attached that happily run FreeBSD 6.0. However, when I try to get them to run FreeBSD 7, the thumb drives stop working. A PR was recently filed by someone with a similar issue: kern/122380 (I see the same failure as in the PR). Looks like something changed in the USB stack from 6 to 7...any ideas where to look or how I can go about solving this? Geoff From owner-freebsd-embedded@FreeBSD.ORG Mon Apr 21 18:29:59 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 91A3D106566C; Mon, 21 Apr 2008 18:29:59 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 577738FC12; Mon, 21 Apr 2008 18:29:59 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.2/8.14.1) with ESMTP id m3LISZFF032517; Mon, 21 Apr 2008 12:28:35 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Mon, 21 Apr 2008 12:29:38 -0600 (MDT) Message-Id: <20080421.122938.1943336925.imp@bsdimp.com> To: mainland@eecs.harvard.edu From: "M. Warner Losh" In-Reply-To: <20080421171305.GA19840@eecs.harvard.edu> References: <20080421171305.GA19840@eecs.harvard.edu> X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-embedded@freebsd.org, freebsd-usb@freebsd.org Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Apr 2008 18:29:59 -0000 In message: <20080421171305.GA19840@eecs.harvard.edu> Geoffrey Mainland writes: : I have a number of Soekris 4826 boards with USB thumb drives attached : that happily run FreeBSD 6.0. However, when I try to get them to run : FreeBSD 7, the thumb drives stop working. A PR was recently filed by : someone with a similar issue: kern/122380 (I see the same failure as in : the PR). Looks like something changed in the USB stack from 6 to 7...any : ideas where to look or how I can go about solving this? Lots of cosmetic changes, lots of other changes that were for the better, lots and lots of quirks. I'm guessing something got quirked, or there was a bug fix that caused us to die. As to tracking it down, I'd suggest a binary search between 7.0-release and where RELENG_6 was branched. Not ideal, but that's the likeliest way to cope. Warner From owner-freebsd-embedded@FreeBSD.ORG Tue Apr 22 13:00:01 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C7E331065672 for ; Tue, 22 Apr 2008 13:00:01 +0000 (UTC) (envelope-from netslists@gmail.com) Received: from rn-out-0910.google.com (rn-out-0910.google.com [64.233.170.187]) by mx1.freebsd.org (Postfix) with ESMTP id 01AA18FC16 for ; Tue, 22 Apr 2008 13:00:00 +0000 (UTC) (envelope-from netslists@gmail.com) Received: by rn-out-0910.google.com with SMTP id j40so705963rnf.12 for ; Tue, 22 Apr 2008 06:00:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; bh=R5cXuVYLdHCfT6OJCcgUtU//q7rds8nP/bG87UvbRhA=; b=lnFWgCXLGBExSJ9CV2991VJwMi+a0l3Xgib/mJ16ySoFn8+2W6DwMhOGgNxTDgAGCvteZBemb6nIDKKWLb8I6hXuUYZ5DFJDF9oNjG7Up8KjtRPySDBb2RwNuk4QqZwJ4N9y3N1KlehQc60uT57hh+WLOPTvVKQ1cK1lRHy8/Ps= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=grSpt1HtlsNmlQHLzRLKkifYgP4QM7Nkhy6aK8XdMB59hvNUvdu1Q+oZW+yxOy2Kii+q6jPWIXec3ERMGqQKuAlIknZTd8ijRr1FtpziJthHvKUob04ayJlCnXkIn5uX8RqxU3WfKuL+00Vxv4b2NZFb79VUaxSQyBi83xca/OE= Received: by 10.114.150.1 with SMTP id x1mr145951wad.46.1208867606090; Tue, 22 Apr 2008 05:33:26 -0700 (PDT) Received: from ?192.168.12.8? ( [97.101.40.241]) by mx.google.com with ESMTPS id 6sm8465829ywp.3.2008.04.22.05.33.24 (version=SSLv3 cipher=RC4-MD5); Tue, 22 Apr 2008 05:33:25 -0700 (PDT) Message-ID: <480DDB0E.8060406@gmail.com> Date: Tue, 22 Apr 2008 08:33:18 -0400 From: Sten Daniel Soersdal User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: Aaron Siegel References: <200803231122.57251.aj@siegel-tech.net> In-Reply-To: <200803231122.57251.aj@siegel-tech.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-embedded@freebsd.org Subject: Re: Serial Communication: Terminals X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Apr 2008 13:00:01 -0000 Aaron Siegel wrote: > Hello > > I am trying to set up access the serial terminal I set up on my single board > computer (ALIX2) running FreeBSD. I followed the configuration provied in > the Terminal section of the Handbook, subsection 24.3.2.1 "Adding an Entry > to /etc/ttys forced init with the > #kill -HUP 1. > > The question is; if the login prompt is to appear where would it appear? Would > it be one of the virtual terminals? Do I need to use cu, tip, or minicom? > When I use cu program > # cu -l cuad1 > I receive a message > Connected > But I do not receive a prompt. > > The getty process is running > # ps -axwww | grep getty > 47126 ?? I 0:00.00 /usr/libexec/getty std.19200 ttyd1 > 47129 v0 Is+ 0:00.00 /usr/libexec/getty Pc ttyv0 > 47130 v1 Is+ 0:00.00 /usr/libexec/getty Pc ttyv1 > 702 v2 Is+ 0:00.00 /usr/libexec/getty Pc ttyv2 > 703 v3 Is+ 0:00.00 /usr/libexec/getty Pc ttyv3 > 704 v4 Is+ 0:00.00 /usr/libexec/getty Pc ttyv4 > 705 v5 Is+ 0:00.00 /usr/libexec/getty Pc ttyv5 > 706 v6 Is+ 0:00.00 /usr/libexec/getty Pc ttyv6 > 707 v7 Is+ 0:00.00 /usr/libexec/getty Pc ttyv7 > > My /etc/ttys file > # The 'dialup' keyword identifies dialin lines to login, fingerd etc. > ttyd0 "/usr/libexec/getty std.9600" dialup off secure > ttyd1 "/usr/libexec/getty std.9600" dialup on secure > ttyd2 "/usr/libexec/getty std.9600" dialup off secure > ttyd3 "/usr/libexec/getty std.9600" dialup off secure > > My setting on the single board computer > /etc/tty > ttyd0 "/usr/libexec/getty std.9600" dialup on secure > > /boot/loader.conf > console="comconsole" > comsonsole_speed="19200" #This may be the problem > > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/term.html > TinyBIOS prior to 0.98b would not do CTS/RTS properly. Could that be your problem? 0.99 is available from web site. -- Sten Daniel Soersdal From owner-freebsd-embedded@FreeBSD.ORG Tue Apr 22 21:52:30 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B53511065673; Tue, 22 Apr 2008 21:52:30 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: from mail.eecs.harvard.edu (bowser.eecs.harvard.edu [140.247.60.24]) by mx1.freebsd.org (Postfix) with ESMTP id 9BFC68FC19; Tue, 22 Apr 2008 21:52:30 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: by mail.eecs.harvard.edu (Postfix, from userid 33141) id 43B6B1A5FD6; Tue, 22 Apr 2008 17:52:27 -0400 (EDT) Date: Tue, 22 Apr 2008 17:52:27 -0400 From: Geoffrey Mainland To: "M. Warner Losh" Message-ID: <20080422215227.GA79245@eecs.harvard.edu> References: <20080421171305.GA19840@eecs.harvard.edu> <20080421.122938.1943336925.imp@bsdimp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080421.122938.1943336925.imp@bsdimp.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-embedded@freebsd.org, freebsd-usb@freebsd.org Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Apr 2008 21:52:30 -0000 Wow, this turns out to be much worse than I thought...I've tracked down the problem to the commit of the new physical memory allocator at Sat Jun 16 04:57:05 2007 UTC. Before that, no kern/122380; after that, kern/122380 applies. Any ideas where to go from here? Thanks, Geoff On Mon, Apr 21, 2008 at 12:29:38PM -0600, M. Warner Losh wrote: > In message: <20080421171305.GA19840@eecs.harvard.edu> > Geoffrey Mainland writes: > : I have a number of Soekris 4826 boards with USB thumb drives attached > : that happily run FreeBSD 6.0. However, when I try to get them to run > : FreeBSD 7, the thumb drives stop working. A PR was recently filed by > : someone with a similar issue: kern/122380 (I see the same failure as in > : the PR). Looks like something changed in the USB stack from 6 to 7...any > : ideas where to look or how I can go about solving this? > > Lots of cosmetic changes, lots of other changes that were for the > better, lots and lots of quirks. I'm guessing something got quirked, > or there was a bug fix that caused us to die. > > As to tracking it down, I'd suggest a binary search between > 7.0-release and where RELENG_6 was branched. Not ideal, but that's > the likeliest way to cope. > > Warner From owner-freebsd-embedded@FreeBSD.ORG Tue Apr 22 23:43:07 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1F8F4106564A for ; Tue, 22 Apr 2008 23:43:07 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 0539F8FC0A for ; Tue, 22 Apr 2008 23:43:06 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 158D01C805E; Tue, 22 Apr 2008 16:14:35 -0700 (PDT) Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 20967-01; Tue, 22 Apr 2008 16:14:34 -0700 (PDT) Received: from [10.47.1.154] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id 02DCE1C800F; Tue, 22 Apr 2008 16:14:33 -0700 (PDT) Message-ID: <480E7159.8080305@miralink.com> Date: Tue, 22 Apr 2008 16:14:33 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.12 (X11/20080226) MIME-Version: 1.0 To: Sten Daniel Soersdal References: <200803231122.57251.aj@siegel-tech.net> <480DDB0E.8060406@gmail.com> In-Reply-To: <480DDB0E.8060406@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-DSPAM-Result: Innocent X-DSPAM-Processed: Tue Apr 22 16:14:34 2008 X-DSPAM-Confidence: 0.9997 X-DSPAM-Probability: 0.0000 X-DSPAM-Signature: 480e715a220385260519334 X-DSPAM-Factors: 27, X-Virus-Scanned: amavisd-new at X-Spam-Status: No, score=-4.499 tagged_above=-10 required=6.6 autolearn=ham tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599, DSPAM_HAM=-0.1] X-Spam-Score: -4.499 X-Spam-Level: Cc: Aaron Siegel , freebsd-embedded@freebsd.org Subject: Re: Serial Communication: Terminals X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Apr 2008 23:43:07 -0000 Sten Daniel Soersdal wrote: > Aaron Siegel wrote: >> >> # ps -axwww | grep getty >> 47126 ?? I 0:00.00 /usr/libexec/getty std.19200 ttyd1 >> This looks suspicious. It looks like theres a getty running on ttyd1? But not on ttyd0? Typo? Sean From owner-freebsd-embedded@FreeBSD.ORG Wed Apr 23 18:31:00 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 483ED106564A for ; Wed, 23 Apr 2008 18:31:00 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe06.swip.net [212.247.154.161]) by mx1.freebsd.org (Postfix) with ESMTP id BBAAC8FC18 for ; Wed, 23 Apr 2008 18:30:59 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [62.113.133.152] (account mc467741@c2i.net [62.113.133.152] verified) by mailfe06.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 909104810; Wed, 23 Apr 2008 19:30:48 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Wed, 23 Apr 2008 19:31:59 +0200 User-Agent: KMail/1.9.7 References: <20080421171305.GA19840@eecs.harvard.edu> <20080421.122938.1943336925.imp@bsdimp.com> <20080422215227.GA79245@eecs.harvard.edu> In-Reply-To: <20080422215227.GA79245@eecs.harvard.edu> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804231932.00765.hselasky@c2i.net> Cc: Geoffrey Mainland , freebsd-embedded@freebsd.org Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Apr 2008 18:31:00 -0000 On Tuesday 22 April 2008, Geoffrey Mainland wrote: > Wow, this turns out to be much worse than I thought...I've tracked down > the problem to the commit of the new physical memory allocator at Sat > Jun 16 04:57:05 2007 UTC. Before that, no kern/122380; after that, > kern/122380 applies. Any ideas where to go from here? > Hi, I've sometimes seen that the USB HC's do not always support 32 address lines. Not sure if that is the case for you. Then all DMA memory has to be allocated at a lower physical memory address. You can easily check this by changing the parameters used when creating DMA tags in the USB code. --HPS From owner-freebsd-embedded@FreeBSD.ORG Thu Apr 24 03:34:56 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 19BE0106567C; Thu, 24 Apr 2008 03:34:56 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: from mail.eecs.harvard.edu (bowser.eecs.harvard.edu [140.247.60.24]) by mx1.freebsd.org (Postfix) with ESMTP id 0A24B8FC12; Thu, 24 Apr 2008 03:34:55 +0000 (UTC) (envelope-from mainland@eecs.harvard.edu) Received: by mail.eecs.harvard.edu (Postfix, from userid 33141) id DCEB81A5156; Wed, 23 Apr 2008 23:34:52 -0400 (EDT) Date: Wed, 23 Apr 2008 23:34:52 -0400 From: Geoffrey Mainland To: Hans Petter Selasky Message-ID: <20080424033452.GA39119@eecs.harvard.edu> References: <20080421171305.GA19840@eecs.harvard.edu> <20080421.122938.1943336925.imp@bsdimp.com> <20080422215227.GA79245@eecs.harvard.edu> <200804231932.00765.hselasky@c2i.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200804231932.00765.hselasky@c2i.net> User-Agent: Mutt/1.4.2.3i Cc: freebsd-usb@freebsd.org, freebsd-embedded@freebsd.org Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 03:34:56 -0000 On Wed, Apr 23, 2008 at 07:31:59PM +0200, Hans Petter Selasky wrote: > On Tuesday 22 April 2008, Geoffrey Mainland wrote: > > Wow, this turns out to be much worse than I thought...I've tracked down > > the problem to the commit of the new physical memory allocator at Sat > > Jun 16 04:57:05 2007 UTC. Before that, no kern/122380; after that, > > kern/122380 applies. Any ideas where to go from here? > > > > Hi, > > I've sometimes seen that the USB HC's do not always support 32 address lines. > Not sure if that is the case for you. Then all DMA memory has to be allocated > at a lower physical memory address. You can easily check this by changing the > parameters used when creating DMA tags in the USB code. > > --HPS The new page allocator obviously tickled a bug somewhere in the current USB stack, but I'm happy to report that replacing it with the USB stack from your subversion repository fixed everything. Thank you! This fix has allowed me to move a large wireless testbed forward to FreeBSD 7. Geoff From owner-freebsd-embedded@FreeBSD.ORG Thu Apr 24 08:15:24 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 166CB106564A for ; Thu, 24 Apr 2008 08:15:24 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe14.swipnet.se [212.247.155.161]) by mx1.freebsd.org (Postfix) with ESMTP id BEA1B8FC24 for ; Thu, 24 Apr 2008 08:15:23 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [62.113.133.152] (account mc467741@c2i.net [62.113.133.152] verified) by mailfe14.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 171340962; Thu, 24 Apr 2008 09:15:20 +0200 From: Hans Petter Selasky To: Geoffrey Mainland Date: Thu, 24 Apr 2008 09:16:38 +0200 User-Agent: KMail/1.9.7 References: <20080421171305.GA19840@eecs.harvard.edu> <200804231932.00765.hselasky@c2i.net> <20080424033452.GA39119@eecs.harvard.edu> In-Reply-To: <20080424033452.GA39119@eecs.harvard.edu> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804240916.39607.hselasky@c2i.net> Cc: freebsd-usb@freebsd.org, freebsd-embedded@freebsd.org Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 08:15:24 -0000 On Thursday 24 April 2008, Geoffrey Mainland wrote: > On Wed, Apr 23, 2008 at 07:31:59PM +0200, Hans Petter Selasky wrote: > > On Tuesday 22 April 2008, Geoffrey Mainland wrote: > > > Wow, this turns out to be much worse than I thought...I've tracked down > > > the problem to the commit of the new physical memory allocator at Sat > > > Jun 16 04:57:05 2007 UTC. Before that, no kern/122380; after that, > > > kern/122380 applies. Any ideas where to go from here? > > > > Hi, > > > > I've sometimes seen that the USB HC's do not always support 32 address > > lines. Not sure if that is the case for you. Then all DMA memory has to > > be allocated at a lower physical memory address. You can easily check > > this by changing the parameters used when creating DMA tags in the USB > > code. > > > > --HPS > > The new page allocator obviously tickled a bug somewhere in the current > USB stack, but I'm happy to report that replacing it with the USB stack > from your subversion repository fixed everything. Thank you! This fix > has allowed me to move a large wireless testbed forward to FreeBSD 7. > > Geoff Hi, A wild guess of mine why the official USB stack in the 7-branch does not work: It might be that the loading of KVA into DMA is broken. I've found a couple of corner cases during my development where you have to generate the physaddr of the last page yourself in the busdma callback: static void usbd_pc_common_mem_cb(void *arg, bus_dma_segment_t *segs, int nseg, int error, uint8_t isload) ... if (nseg < ((pc->page_offset_end + (USB_PAGE_SIZE - 1)) / USB_PAGE_SIZE)) { ext_seg = 1; } else { ext_seg = 0; } ... if (ext_seg && pc->ismultiseg) { (pg + 1)->physaddr = pg->physaddr + USB_PAGE_SIZE; } --HPS From owner-freebsd-embedded@FreeBSD.ORG Thu Apr 24 13:25:54 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 075671065673; Thu, 24 Apr 2008 13:25:54 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 12D8C8FC26; Thu, 24 Apr 2008 13:25:54 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from zion.baldwin.cx (unknown [208.65.91.234]) by elvis.mu.org (Postfix) with ESMTP id 571FE1A4D84; Thu, 24 Apr 2008 06:07:00 -0700 (PDT) From: John Baldwin To: freebsd-embedded@freebsd.org Date: Thu, 24 Apr 2008 08:06:54 -0400 User-Agent: KMail/1.9.7 References: <20080421171305.GA19840@eecs.harvard.edu> <20080424033452.GA39119@eecs.harvard.edu> <200804240916.39607.hselasky@c2i.net> In-Reply-To: <200804240916.39607.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804240806.54354.jhb@freebsd.org> Cc: Geoffrey Mainland , freebsd-usb@freebsd.org, Hans Petter Selasky Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 13:25:54 -0000 On Thursday 24 April 2008 03:16:38 am Hans Petter Selasky wrote: > On Thursday 24 April 2008, Geoffrey Mainland wrote: > > On Wed, Apr 23, 2008 at 07:31:59PM +0200, Hans Petter Selasky wrote: > > > On Tuesday 22 April 2008, Geoffrey Mainland wrote: > > > > Wow, this turns out to be much worse than I thought...I've tracked > > > > down the problem to the commit of the new physical memory allocator > > > > at Sat Jun 16 04:57:05 2007 UTC. Before that, no kern/122380; after > > > > that, kern/122380 applies. Any ideas where to go from here? > > > > > > Hi, > > > > > > I've sometimes seen that the USB HC's do not always support 32 address > > > lines. Not sure if that is the case for you. Then all DMA memory has to > > > be allocated at a lower physical memory address. You can easily check > > > this by changing the parameters used when creating DMA tags in the USB > > > code. > > > > > > --HPS > > > > The new page allocator obviously tickled a bug somewhere in the current > > USB stack, but I'm happy to report that replacing it with the USB stack > > from your subversion repository fixed everything. Thank you! This fix > > has allowed me to move a large wireless testbed forward to FreeBSD 7. > > > > Geoff > > Hi, > > A wild guess of mine why the official USB stack in the 7-branch does not > work: It might be that the loading of KVA into DMA is broken. I've found a > couple of corner cases during my development where you have to generate the > physaddr of the last page yourself in the busdma callback: This would indicate a bug in the bus_dmamap_load() call (wrong length?) and that is going to hose you when you do the bus_dmamap_sync() for systems with bounce pages (not enough data will get copied back and forth?). You need to track down the real bug and fix it rather than adding a hack in your callback routine. -- John Baldwin From owner-freebsd-embedded@FreeBSD.ORG Thu Apr 24 15:36:58 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 93F23106566B; Thu, 24 Apr 2008 15:36:58 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe02.swip.net [212.247.154.33]) by mx1.freebsd.org (Postfix) with ESMTP id 3AC208FC1B; Thu, 24 Apr 2008 15:36:55 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [62.113.133.152] (account mc467741@c2i.net [62.113.133.152] verified) by mailfe02.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 912991824; Thu, 24 Apr 2008 17:36:54 +0200 From: Hans Petter Selasky To: John Baldwin Date: Thu, 24 Apr 2008 17:38:09 +0200 User-Agent: KMail/1.9.7 References: <20080421171305.GA19840@eecs.harvard.edu> <200804240916.39607.hselasky@c2i.net> <200804240806.54354.jhb@freebsd.org> In-Reply-To: <200804240806.54354.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804241738.09805.hselasky@c2i.net> Cc: freebsd-embedded@freebsd.org, freebsd-usb@freebsd.org, Geoffrey Mainland Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 15:36:58 -0000 On Thursday 24 April 2008, John Baldwin wrote: > > This would indicate a bug in the bus_dmamap_load() call (wrong length?) and > that is going to hose you when you do the bus_dmamap_sync() for systems > with bounce pages (not enough data will get copied back and forth?). You > need to track down the real bug and fix it rather than adding a hack in > your callback routine. Hi John, The minimum segment size is PAGE_SIZE bytes in my DMA-tag. Bus-dma starts counting at the memory location of the allocation. And not the memory location aligned to PAGE_SIZE bytes. Memory pages: |--------------|--------------| My allocation: |---------XXXXXXXXXXXXX-------| Sometimes when I allocate DMA memory I can end up having an allocation crossing two contiguous memory pages in physical memory. In those cases bus_dma does not give me the segment address of the second page in the segment list, because the allocation is less than PAGE_SIZE bytes. It fits within the values specified in the DMA tag. But in other cases, where the pages are not contiguous in RAM, bus_dma will return two different segment addresses. The question is: Is this a bug or is it a feature? --HPS From owner-freebsd-embedded@FreeBSD.ORG Thu Apr 24 20:26:46 2008 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 90BE11065670; Thu, 24 Apr 2008 20:26:46 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 866FA8FC22; Thu, 24 Apr 2008 20:26:46 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unknown [208.65.91.234]) by elvis.mu.org (Postfix) with ESMTP id 0CEF01A4D83; Thu, 24 Apr 2008 13:26:45 -0700 (PDT) Received: from localhost.corp.yahoo.com (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.14.2/8.14.2) with ESMTP id m3OKQS9q044310; Thu, 24 Apr 2008 16:26:34 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: Hans Petter Selasky Date: Thu, 24 Apr 2008 16:01:51 -0400 User-Agent: KMail/1.9.7 References: <20080421171305.GA19840@eecs.harvard.edu> <200804240806.54354.jhb@freebsd.org> <200804241738.09805.hselasky@c2i.net> In-Reply-To: <200804241738.09805.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804241601.51441.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Thu, 24 Apr 2008 16:26:34 -0400 (EDT) X-Virus-Scanned: ClamAV 0.91.2/6926/Thu Apr 24 14:23:40 2008 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: freebsd-embedded@freebsd.org, freebsd-usb@freebsd.org, Geoffrey Mainland Subject: Re: Soekris 4826 USB failure on FreeBSD 7.0 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 20:26:46 -0000 On Thursday 24 April 2008 11:38:09 am Hans Petter Selasky wrote: > On Thursday 24 April 2008, John Baldwin wrote: > > > > This would indicate a bug in the bus_dmamap_load() call (wrong length?) and > > that is going to hose you when you do the bus_dmamap_sync() for systems > > with bounce pages (not enough data will get copied back and forth?). You > > need to track down the real bug and fix it rather than adding a hack in > > your callback routine. > > Hi John, > > The minimum segment size is PAGE_SIZE bytes in my DMA-tag. Bus-dma starts > counting at the memory location of the allocation. And not the memory > location aligned to PAGE_SIZE bytes. > > Memory pages: |--------------|--------------| > My allocation: |---------XXXXXXXXXXXXX-------| > > Sometimes when I allocate DMA memory I can end up having an allocation > crossing two contiguous memory pages in physical memory. In those cases > bus_dma does not give me the segment address of the second page in the > segment list, because the allocation is less than PAGE_SIZE bytes. It fits > within the values specified in the DMA tag. But in other cases, where the > pages are not contiguous in RAM, bus_dma will return two different segment > addresses. > > The question is: Is this a bug or is it a feature? If you can't have a S/G element cross a page boundary, then use a 'boundary' of PAGE_SIZE when you create your tag. As it is, you are (correctly for the tag you are creating) getting a single S/G entry that spans the entire region. It sounds like you want two regions that is split on the page boundary. If so, that is what the 'boundary' argument to bus_dmatag_create() is for. -- John Baldwin