From owner-freebsd-arm@freebsd.org Fri Jul 31 15:11:40 2015 Return-Path: Delivered-To: freebsd-arm@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 640909AFAA9 for ; Fri, 31 Jul 2015 15:11:40 +0000 (UTC) (envelope-from onwahe@gmail.com) Received: from mail-ig0-x236.google.com (mail-ig0-x236.google.com [IPv6:2607:f8b0:4001:c05::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 294D313D3 for ; Fri, 31 Jul 2015 15:11:40 +0000 (UTC) (envelope-from onwahe@gmail.com) Received: by igr7 with SMTP id 7so18309744igr.0 for ; Fri, 31 Jul 2015 08:11:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=J22MTLdBUhQxTiemN+YOKKU7wmhPemwmHgW6qXjxPXw=; b=ck7GKgEcmGcXePg8aJxDIzq6X2s+1GjqlPfRzg79sYUGtuwRjmOrpvLns7zR1e3mye PFYX2+n5D4hlIrexKtuACXi6SDURYUuRZ9rkkX/q/qNVm6i/LK+gEHh1rhGwf5qMWlEs Cab3bdRl9lIy5HZdSMUuN9avyOaor6yIyqX3BwrCDTdraUcEZ5n+Kk7PIZRvrqIHgW8n dlGpGAF94pf8kMugAMejq2MpD5W1xbdvjC5sV9xEzHoEvaB8hwEIUOZrgYxQqPQb9CcJ aJsLa9HvE8tWg6BoBPunl2BWxLg/HWE7g1RO7YecccsIIAVIlsapWX8X44LHU805dcaV DeHg== MIME-Version: 1.0 X-Received: by 10.50.2.9 with SMTP id 9mr6294078igq.42.1438355499431; Fri, 31 Jul 2015 08:11:39 -0700 (PDT) Received: by 10.64.148.84 with HTTP; Fri, 31 Jul 2015 08:11:39 -0700 (PDT) In-Reply-To: <55BB6A7F.3060402@selasky.org> References: <55A7D8CE.4020809@selasky.org> <55B23276.8090703@selasky.org> <55B73113.2020308@selasky.org> <55B8AB76.7030603@selasky.org> <55B8B297.1010008@selasky.org> <20150729154516.GH78154@funkthat.com> <55B8F5EC.2050908@selasky.org> <46ad096c958.1a82a175@mail.schwarzes.net> <55B9C3E2.5040501@selasky.org> <46ae815c7c3.447237c8@mail.schwarzes.net> <46aece00b53.3c1cdc1f@mail.schwarzes.net> <55BB2A5F.9000502@selasky.org> <55BB3CC6.4030002@selasky.org> <55BB6A7F.3060402@selasky.org> Date: Fri, 31 Jul 2015 17:11:39 +0200 Message-ID: Subject: Re: DWC OTG TX path optimisation for 11-current From: Svatopluk Kraus To: Hans Petter Selasky Cc: "freebsd-arm@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 Jul 2015 15:11:40 -0000 On Fri, Jul 31, 2015 at 2:30 PM, Hans Petter Selasky wrote: > On 07/31/15 13:55, Svatopluk Kraus wrote: >> >> On Fri, Jul 31, 2015 at 11:15 AM, Hans Petter Selasky >> wrote: >>> >>> Hi, >>> >>> I did some testing myself and I see the polling handler can loop many >>> times >>> when USB is active. Instead of 2 as a polling limit I've set 16. Hope >>> this >>> works too. Works fine over here. >>> >>> https://svnweb.freebsd.org/changeset/base/286118 >>> > > Hi, > >> >> Definitely, some limitation was needed there. Thanks. >> >> Unfortunatelly, it turned out that it does not help with my problem. >> It has affected system response time in good way for some time after >> the trigger is pulled. However, after 17 hours when buildworld >> finished, system response time is bad again. >> >> It also turns out that I have a problem with booting my kernels. So I >> cannot test the extra "clear RX FIFO level interrupt" patch as even >> this one line of code causes that kernel does not boot. It freezes at >> very beginning and even first printf is not printed. Thus I have to >> debug this problem firstly. It will be very funny without either jtag >> or early printf. ;) >> > > I'll possibly order an RPI2 for myself. Well, the reason why some of my kernels did not boot is that kernel start address is changing from 0x100 offset to 0x180 offset for some strange unknown reason when I change one line of code for example. If I change more lines in same file on another place, it does not happen. I will not investigate that now, but I'm able to arrange my boot script according to actual starting address. ;) Thus I was able to test both your patches and none of them makes difference. > >> Meantime, I have noticed that after reboot (system is 99% idle), I'm >> getting the following output from vmstat: >> >> > >> IMO, 24000 interrupts per a second for bcm283x_dwco is too many. > > > Yes, that's right. Note that I got about 24000 interrupts per a second during buildworld too. If I remember it correctly, it was about 4000 before r285935. When the trigger is pulled, the count is changing (in range of 4000 to 21000). It looks like something is taking more time (interrupt servicing probably). According to "systat -v", disk is going to be 100% (and more) busy very often for example. Svata > > BTW: I see you are using RPI2 while I'm using an RPI-B. That's probably why > this won't preproduce over here. > > I've made another patch to not write the GINTMSK with same values. Not sure > if it makes any difference. > > --HPS >