Received: from eggs.gnu.org ([2001:4830:134:3::10]:46337) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRe2g-0004OO-0x for qemu-devel@nongnu.org; Wed, 10 Sep 2014 05:18:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XRe2T-0000vu-Ir for qemu-devel@nongnu.org; Wed, 10 Sep 2014 05:18:21 -0400 Received: from e28smtp07.in.ibm.com ([122.248.162.7]:42029) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRe2S-0000uP-Dw for qemu-devel@nongnu.org; Wed, 10 Sep 2014 05:18:09 -0400 Received: from /spool/local by e28smtp07.in.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 10 Sep 2014 14:48:04 +0530 From: Nikunj A Dadhania In-Reply-To: <20140910110148.6eaf913f@bahia.local> References: <1410192283-4026-1-git-send-email-mst@redhat.com> <20140910003532.22d72602@bahia.local> <87oaunops6.fsf@abhimanyu.in.ibm.com> <20140910093230.GB7902@redhat.com> <20140910110148.6eaf913f@bahia.local> Date: Wed, 10 Sep 2014 14:48:01 +0530 Message-ID: <87ha0fomuu.fsf@abhimanyu.in.ibm.com> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Greg Kurz , "Michael S. Tsirkin" Cc: Alexey Kardashevskiy , Jan Kiszka , qemu-devel@nongnu.org, Anthony Liguori , qemu-stable@nongnu.org Greg Kurz writes: >> > > I did some debugging: it looks like the guest kernel calls the OF >> > > quisece call to flush pending DMA and disables bus master on the >> > > virtio-blk device (PCI_COMMAND == 0x3). >> > >> > Getting confused, above you are talking about virtio-net and here it is >> > virtio-blk. >> > >> > Anyways, the routines still remains same for both of them. From SLOF >> > during init we set DRIVER_OK, and after using the device during the >> > quiesce, called from linux kernel VIRTIO_CONFIG_S_FAILED is set and then >> > a VIRTIO_DEVICE_RESET is done. >> >> BTW, you really should start enabling bus mastering, avoid relying >> on the work-around we have for broken guests. >> > > FWIW during my debug session, I see that SLOF enables bus mastering... > unfortunately, it gets disabled at some point after the guest kernel > is started (around the ppc64 prom_init() call). Is it before quiesce call? Regards Nikunj