From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:57814) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TsJfN-0008OV-Gh for qemu-devel@nongnu.org; Mon, 07 Jan 2013 15:51:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TsJfM-0001Ed-Gy for qemu-devel@nongnu.org; Mon, 07 Jan 2013 15:51:29 -0500 Received: from e9.ny.us.ibm.com ([32.97.182.139]:43746) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TsJfM-0001EX-Cw for qemu-devel@nongnu.org; Mon, 07 Jan 2013 15:51:28 -0500 Received: from /spool/local by e9.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 7 Jan 2013 15:51:27 -0500 Received: from d01relay04.pok.ibm.com (d01relay04.pok.ibm.com [9.56.227.236]) by d01dlp03.pok.ibm.com (Postfix) with ESMTP id 39010C90044 for ; Mon, 7 Jan 2013 15:51:25 -0500 (EST) Received: from d03av06.boulder.ibm.com (d03av06.boulder.ibm.com [9.17.195.245]) by d01relay04.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r07KpNVA292724 for ; Mon, 7 Jan 2013 15:51:24 -0500 Received: from d03av06.boulder.ibm.com (loopback [127.0.0.1]) by d03av06.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r07KrXKP031179 for ; Mon, 7 Jan 2013 13:53:33 -0700 From: Anthony Liguori In-Reply-To: References: <1355761490-10073-1-git-send-email-pbonzini@redhat.com> <877gnovmgj.fsf@codemonkey.ws> <87mwwkg2y4.fsf@codemonkey.ws> Date: Mon, 07 Jan 2013 14:51:17 -0600 Message-ID: <87zk0kd8e2.fsf@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: [Qemu-devel] [PATCH 00/15] qdev: make reset semantics more clear and consistent, reset qbuses under virtio devices List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Paolo Bonzini , qemu-devel@nongnu.org, mst@redhat.com Peter Maydell writes: > On 7 January 2013 20:20, Anthony Liguori wrote: >> Peter Maydell writes: >>> On 7 January 2013 19:10, Anthony Liguori wrote: >>>> I think reset really ought to just be a bus level concept with >>>> individual implementations for each bus. >>> >>> I'm not sure I really agree here, especially since QOM/qdev are >>> moving away from the idea that there is a single bus tree and every >>> device is on a single bus. >> >> I don't mean a BusState level concept, I mean a PCIBus concept. >> >> There is clearly such a thing as a PCI bus reset. In fact, there are >> multiple types of PCI bus resets. There should be a PCIBus method that >> calls out to PCIDevices on the bus. >> >> But that isn't something that should be fitted into generalized to a >> BusState::reset method. > > Ah, I see what you mean now -- yes, definitely. > >>> If we want to model reset properly we should model actual reset >>> lines (and/or power-cycling). If we don't care we can continue with >>> whatever fudge we like :-) >> >> Yes, and that's basically what qemu_system_reset() is. Of course, we >> model it like everything is directly connected to a single power source >> which is true 99% of the time. That's why we've gotten away with it for >> so long. > > I think the bit that's most creaky here is what you do about devices > that want to assert outgoing irq/whatever lines immediately on > powerup. This isn't so much a reset problem as a consequence of stateless IRQ lines. If IRQ lines were stateful, this problem wouldn't exist. And yes, I will post Pins one day... Regards, Anthony Liguori > > -- PMM