From owner-freebsd-current@FreeBSD.ORG Wed Oct 5 16:10:48 2005 Return-Path: X-Original-To: freebsd-current@FreeBSD.org Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0BB1E16A41F for ; Wed, 5 Oct 2005 16:10:48 +0000 (GMT) (envelope-from jkim@FreeBSD.org) Received: from anuket.mj.niksun.com (gwnew.niksun.com [65.115.46.162]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8435543D48 for ; Wed, 5 Oct 2005 16:10:45 +0000 (GMT) (envelope-from jkim@FreeBSD.org) Received: from niksun.com (anuket [10.70.0.5]) by anuket.mj.niksun.com (8.13.1/8.13.1) with ESMTP id j95GHiqO082911; Wed, 5 Oct 2005 12:17:45 -0400 (EDT) (envelope-from jkim@FreeBSD.org) From: Jung-uk Kim To: Peter Edwards Date: Wed, 5 Oct 2005 12:10:28 -0400 User-Agent: KMail/1.6.2 References: <34cb7c8405092815247dc89bf6@mail.gmail.com> <200509291303.41181.jhb@FreeBSD.org> <34cb7c840510050613u36e76be1pef82c41130da8804@mail.gmail.com> In-Reply-To: <34cb7c840510050613u36e76be1pef82c41130da8804@mail.gmail.com> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="euc-kr" Content-Transfer-Encoding: 7bit Message-Id: <200510051210.30452.jkim@FreeBSD.org> X-Virus-Scanned: ClamAV devel-20050919/1113/Wed Oct 5 07:13:44 2005 on anuket.mj.niksun.com X-Virus-Status: Clean Cc: freebsd-current@FreeBSD.org Subject: Re: biodone panics X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Oct 2005 16:10:48 -0000 On Wednesday 05 October 2005 09:13 am, Peter Edwards wrote: > Take 2 for the biodone() panics: > > acd_geom_start() implements request limiting by breaking up a large > request in the passed bio into a sequence of smaller ones. As each > request is created, acd_strategy is invoked to start the IO. > > However, I think this IO can complete while still issuing the child > requests, leading to the parent being retired early. (ie, when a > child operation completes, it checks if its the last operation to > complete, and, if so, retires the parent: see g_std_done.) > > The attached patch makes my qemu box much more reliable (I could > crash a qemu hosted system 100% with a "tar fc" of the 6.0-BETA > bootonly ISO without the patch, and it's gone through many > iterations fine with it) > > Any opinions/testing results welcome. I think you nailed it! It's a shame that I had the same theory and I was staring at the same code with scratching my head for hours but I couldn't find proper fix. :-( Tested with QEMU 0.7.2 from ports/qemu for a while with no regression. BTW, minor style comment. Please do s/0/NULL/. Thanks a bunch! Jung-uk Kim