From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=58906 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQQA0-0000Bx-Du for qemu-devel@nongnu.org; Wed, 08 Dec 2010 14:58:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PQQ9z-0000o8-5f for qemu-devel@nongnu.org; Wed, 08 Dec 2010 14:58:44 -0500 Received: from mx1.redhat.com ([209.132.183.28]:2499) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PQQ9y-0000ns-V0 for qemu-devel@nongnu.org; Wed, 08 Dec 2010 14:58:43 -0500 Date: Wed, 8 Dec 2010 21:58:35 +0200 From: Gleb Natapov Message-ID: <20101208195835.GD20507@redhat.com> References: <20101208170858.GA10056@amt.cnet> <20101208173442.GC20507@redhat.com> <20101208180118.GA11016@amt.cnet> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20101208180118.GA11016@amt.cnet> Subject: [Qemu-devel] Re: seabios: acpi: add _RMV control method for PCI devices List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Marcelo Tosatti Cc: seabios@seabios.org, qemu-devel@nongnu.org, Gerd Hoffmann On Wed, Dec 08, 2010 at 04:01:18PM -0200, Marcelo Tosatti wrote: > On Wed, Dec 08, 2010 at 07:34:42PM +0200, Gleb Natapov wrote: > > On Wed, Dec 08, 2010 at 03:08:59PM -0200, Marcelo Tosatti wrote: > > > Use _RMV method to indicate whether device can be removed. > > > > > But Windows still shows device as removable in the gui and allows to > > remove it, correct? > > No. From "Designing Hardware for Surprise Removal under Windows XP" > document: > > "An ACPI BIOS can override the Removable capability by using the _RMV > method ..." > Cool. I wonder how it co-exists with _EJ0 method for the same device. > > > +#define gen_pci_device(name, nr) \ > > > + Device(SL##name) { \ > > > + Name (_ADR, nr##0000) \ > > > + Method (_RMV) { \ > > > + If (And(\_SB.PCI0.PCRM, ShiftLeft(1, nr))) { \ > > > + Return (0x1) \ > > > + } \ > > > + Return (0x0) \ > > > + } \ > > > + Name (_SUN, name) \ > > > + } > > Why not add this to hotplug_slot() macro? > > Because its ignored if declared in the device object thats a child > of SB.PCI0 (hotplug_slot). Any idea why? -- Gleb.