From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:41356) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SB25G-0005ii-Fo for qemu-devel@nongnu.org; Fri, 23 Mar 2012 06:51:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SB256-0007SH-9G for qemu-devel@nongnu.org; Fri, 23 Mar 2012 06:51:02 -0400 Received: from mail-lb0-f173.google.com ([209.85.217.173]:39750) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SB255-0007Rt-V0 for qemu-devel@nongnu.org; Fri, 23 Mar 2012 06:50:52 -0400 Received: by lbon3 with SMTP id n3so2399725lbo.4 for ; Fri, 23 Mar 2012 03:50:48 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20120323104327.GE19671@arachsys.com> References: <1331603611-9103-1-git-send-email-zwu.kernel@gmail.com> <4F685230.9040209@redhat.com> <4F6854B2.8000209@redhat.com> <20120320114442.GA30819@stefanha-thinkpad.localdomain> <20120322190751.GA12145@arachsys.com> <20120323103814.GA21835@stefanha-thinkpad.localdomain> <20120323104327.GE19671@arachsys.com> Date: Fri, 23 Mar 2012 10:50:48 +0000 Message-ID: From: Stefan Hajnoczi Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] block: add the support to drain throttled requests List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Chris Webb Cc: Kevin Wolf , Stefan Hajnoczi , qemu-devel@nongnu.org, Zhi Yong Wu , Zhi Yong Wu , Paolo Bonzini On Fri, Mar 23, 2012 at 10:43 AM, Chris Webb wrote: > Stefan Hajnoczi writes: > >> On Thu, Mar 22, 2012 at 07:07:52PM +0000, Chris Webb wrote: >> > Stefan Hajnoczi writes: >> > >> > > Yesterday I only posted an analysis of the bug but here are some >> > > thoughts on how to move forward. =A0Throttling itself is not the pro= blem. >> > > We've known that synchronous operations in the vcpu thread are a pro= blem >> > > long before throttling. =A0This is just another reason to convert de= vice >> > > emulation to use asynchronous interfaces. >> > > >> > > Here is the list of device models that perform synchronous block I/O= : >> > > hw/fdc.c >> > > hw/ide/atapi.c >> > > hw/ide/core.c >> > > hw/nand.c >> > > hw/onenand.c >> > > hw/pflash_cfi01.c >> > > hw/pflash_cfi02.c >> > > hw/sd.c >> > > >> > > Zhi Hui Li is working on hw/fdc.c and recently sent a patch. >> > > >> > > I think it's too close to QEMU 1.1 to convert all the remaining devi= ces >> > > and test them properly before the soft-freeze. =A0But it's probably >> > > possible to convert IDE before the soft-freeze. >> > >> > IDE is the only of these that would affect us as a typical user of >> > throttling. The others aren't really the kind of devices which you'd b= e >> > using in a hosting setting in any case. >> >> Can you check whether your Windows guest has DMA or PIO mode enabled? >> >> http://msdn.microsoft.com/en-us/windows/hardware/gg463526 > > Hi. We were producing the IDE assert()s and deadlocks with linux kernels. > Although I believe the same symptoms exist on windows, I haven't actually > tested it myself. Typically they would show up in the 16-bit bootloader > code, even before the 32-bit OS has started. Okay, that makes sense. Bootloaders and the BIOS may use the simplest driver interface - which may be PIO in the case. I asked because the IDE DMA code path should work with I/O throttling and Windows is known for sometimes falling back to the PIO code path when some heuristics trigger. Stefan