From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gordon Messmer Subject: Re: Device pass-through Date: Sun, 15 Jan 2012 22:52:20 -0800 Message-ID: <4F13C924.7010108@eburg.com> References: <4F02086A.6050607@eburg.com> <1325626484.4305.15.camel@bling.home> <4F039D66.103@eburg.com> <1325648683.4305.54.camel@bling.home> <4F05F4EE.3050003@eburg.com> <4F06A205.9080502@eburg.com> <4F06BF7F.4040704@web.de> <4F07A8E4.4020700@eburg.com> <4F08C56D.2040008@eburg.com> <4F0A87B8.2090109@eburg.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit To: kvm@vger.kernel.org Return-path: Received: from home.dragonsdawn.net ([173.160.248.33]:44821 "EHLO ascension.private.dragonsdawn.net" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750740Ab2APGqD (ORCPT ); Mon, 16 Jan 2012 01:46:03 -0500 In-Reply-To: <4F0A87B8.2090109@eburg.com> Sender: kvm-owner@vger.kernel.org List-ID: I still poke at this when I get time. I notice that pci_update_mappings calls pci_bar_address, and the latter will always return PCI_BAR_UNMAPPED for this device. For the emulated devices, pci_bar_address will get an address with PCI_ROM_ADDRESS_ENABLE at some point, and pci_map_option_rom will be called. With the card that I'm passing in, that never happens. Could anyone point me in the direction I should go from here? What sets that bit for the emulated devices that might not happen for the PCI card? if (type & PCI_BASE_ADDRESS_MEM_TYPE_64) { new_addr = pci_get_quad(d->config + bar); } else { new_addr = pci_get_long(d->config + bar); } /* the ROM slot has a specific enable bit */ if (reg == PCI_ROM_SLOT && !(new_addr & PCI_ROM_ADDRESS_ENABLE)) { return PCI_BAR_UNMAPPED; }