From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MGqIF-00064e-LR for qemu-devel@nongnu.org; Wed, 17 Jun 2009 04:14:51 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MGqIA-00060f-Tc for qemu-devel@nongnu.org; Wed, 17 Jun 2009 04:14:50 -0400 Received: from [199.232.76.173] (port=55332 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MGqIA-00060Y-Dj for qemu-devel@nongnu.org; Wed, 17 Jun 2009 04:14:46 -0400 Received: from mx2.redhat.com ([66.187.237.31]:48429) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MGqI9-0003jC-Up for qemu-devel@nongnu.org; Wed, 17 Jun 2009 04:14:46 -0400 Date: Wed, 17 Jun 2009 11:12:42 +0300 From: Gleb Natapov Subject: Re: [Qemu-devel] [PATCH] Register usb-uhci reset function. Message-ID: <20090617081242.GV19508@redhat.com> References: <20090616124702.GS19508@redhat.com> <200906161941.06191.paul@codesourcery.com> <20090616191148.GI782@redhat.com> <200906162038.25324.paul@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200906162038.25324.paul@codesourcery.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paul Brook Cc: qemu-devel@nongnu.org On Tue, Jun 16, 2009 at 08:38:24PM +0100, Paul Brook wrote: > >What about the mantra that we should be as close to HW as possible? > >Reseting state only on a bus level will not work for hot-unplug anyway > > Real hardware consists of electrical signals. Qemu emulates the logical > effects of a device/subsystem, often at a much higher level. Thus "close to HW > as possible" is no longer a straightforward concept. > You keep changing the story to suit your agenda. When I proposed a patch to change qemu_irq() to propagate status of irq delivery back to the caller you were against it because "this is not how real HW work" and no amount of "Real hardware consists of electrical signals. Qemu emulates the logical effects of a device/subsystem, often at a much higher level." from other people haven't convince you a bit. But now, when it comes from your mouth it is a gospel. > Apart from anything else, I'm pretty sure than on all real hotplug PCI systems > each socket is on its own PCI bus to allow electrical isolation of the device > before physical hotplug occurs. > > > > However having the device explicit set its IRQ line during a full system > > > reset is a different matter. This is probably harmless most of the time, > > > and may paper over other bugs (e.g. the PCI bus not being reset > > > properly). However I do not believe it is the correct justification for > > > these changes. > > > > The IRQ state inside piix3 code is QEMU implementation detail. There is > > now such thing on real HW. > > Yes there is. It's a long strip of copper wire with a pullup resistor on the > end. > And guess who drives this long strip of copper wire? a. Device. b. Pci bridge c. Lightning stroke And BTW "pullup resistor" is there just in case no device is present. -- Gleb.