From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:32845) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLZMb-0002TM-Qa for qemu-devel@nongnu.org; Thu, 06 Mar 2014 09:33:39 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLZMV-0003fS-S2 for qemu-devel@nongnu.org; Thu, 06 Mar 2014 09:33:33 -0500 Message-ID: <5318872E.5040301@redhat.com> Date: Thu, 06 Mar 2014 15:33:18 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1393591540-32435-1-git-send-email-wudxw@linux.vnet.ibm.com> <53108919.10103@redhat.com> <53187A32.5000001@linux.vnet.ibm.com> In-Reply-To: <53187A32.5000001@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 1/2] Add a generic vga device type for that specified by '-device' List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Mark Wu , qemu-devel@nongnu.org, qemu-ppc@nongnu.org Cc: Alexander Graf , nikunj@linux.vnet.ibm.com, Anthony Liguori Il 06/03/2014 14:37, Mark Wu ha scritto: > Thanks for your reply! I need confirm I am understanding your comments > correctly. I think you're suggesting to traverse the pci devices and > check if it owns the I/O port 0x3d4 to detect if the vga device > is initialized. But it seems not be able to resolve the bug. Because > the machine initialization code runs before the generic device > initialization, the I/O port 0x3d4 will not be registered at the time > machine initializes. So it can't change the return value of > pci_vga_init. The return value is checked in ppc code, which causes the > bug. Right. What about looking for any PCI device with VGA class? Paolo