From owner-freebsd-firewire@FreeBSD.ORG Sun Dec 21 02:49:22 2008 Return-Path: Delivered-To: freebsd-firewire@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DA1C21065670; Sun, 21 Dec 2008 02:49:22 +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 A86988FC08; Sun, 21 Dec 2008 02:49:22 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 0DD4B1A9121; Sat, 20 Dec 2008 19:49:21 -0800 (PST) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] 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 rWf4rQ+2bc3L; Sat, 20 Dec 2008 19:49:20 -0800 (PST) Received: from [10.47.1.6] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id 671CF1A911A; Sat, 20 Dec 2008 19:49:20 -0800 (PST) Message-ID: <494DAEB1.1070909@miralink.com> Date: Sat, 20 Dec 2008 18:49:21 -0800 From: Sean Bruno User-Agent: Thunderbird 2.0.0.18 (X11/20081119) MIME-Version: 1.0 To: Dieter References: <200812191902.TAA01939@sopwith.solgatos.com> In-Reply-To: <200812191902.TAA01939@sopwith.solgatos.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-firewire@freebsd.org, bug-followup@freebsd.org Subject: Re: kern/118093: firewire bus reset hogs CPU, causing data to be lost X-BeenThere: freebsd-firewire@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Firewire support in FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Dec 2008 02:49:22 -0000 Dieter wrote: > Here are the results of two more experiments: > > I tried to verify what spl the firewire code is at when calling > printf(9) by adding the following block into fwohci.c just > before one of the printfs. > > { > #include > #include > intrmask_t debug_spl; /* __uint32_t */ > intrmask_t debug_spl_high; > intrmask_t debug_spl_tty; > intrmask_t debug_spl_fw; > intrmask_t debug_spl_0; > intrmask_t debug_spl_net; > > debug_spl = splhigh(); > debug_spl_high = spltty(); > debug_spl_tty = splfw(); > debug_spl_fw = splnet(); > debug_spl_net = splhigh(); > spl0(); /* void */ > debug_spl_0 = splhigh(); > splx(debug_spl); > > printf("fwohci_intr_core(): spl = 0x%x\n splhigh=0x%x spltty=0x%x splfw=0x%x splnet=0x%x spl0=0x%x\n", > debug_spl, debug_spl_high, debug_spl_tty, debug_spl_fw, debug_spl_net, debug_spl_0); > } > > But my results appear bogus: > > fwohci_intr_core(): spl = 0x0 > splhigh=0x0 spltty=0x0 splfw=0x0 splnet=0x0 spl0=0x0 > > I have examined my code and the spl(9) man page several times > but I can't find what is wrong. Any clues? > > -------------------------------------------------------- > > To isolate the effects of printf(9) from the firewire bus reset, > I picked a trivial system call (chown(2)) and added some printf(9) > calls. > > Calling chown several times and monitoring with systat -vmstat gives: > 1098 interrupts on the console IRQ > 93.1%Sys 6.7%Intr 0.2%User 0.0%Nice 0.0%Idle > > This did NOT interfere with Ethernet. > > So printf(9) interferes with Ethernet when called from the > firewire driver, but not when called from a vanilla system call. > > I setup my system to execute a bus reset every 1 second, simultaneously, I started copying a large file onto the system see if anything would happen. I saw no change to copy speed reported by SCP during the entire transaction. I also see no change to the system load while this is occurring. This seems indicative of "something else" going on. > -------------------------------------------------------- > > sio0: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0 > sio0: type 16550A, console > sio0: [FILTER] > > What does [FILTER] mean? I don't see an explanation on the sio man page. > Did you mean to ask a different list? Because I have no idea. :)