From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: kvm PCI assignment & VFIO ramblings Date: Mon, 22 Aug 2011 09:30:26 +0300 Message-ID: <4E51F782.7060005@redhat.com> References: <1311983933.8793.42.camel@pasglop> <1312050011.2265.185.camel@x201.home> <20110802082848.GD29719@yookeroo.fritz.box> <1312308847.2653.467.camel@bling.home> <1312310121.2653.470.camel@bling.home> <20110803020422.GF29719@yookeroo.fritz.box> <4E3F9E33.5000706@redhat.com> <1312932258.4524.55.camel@bling.home> <1312944513.29273.28.camel@pasglop> <1313859105.6866.192.camel@x201.home> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: chrisw , Alexey Kardashevskiy , kvm@vger.kernel.org, Paul Mackerras , qemu-devel , aafabbri , iommu , "linux-pci@vger.kernel.org" , linuxppc-dev , benve@cisco.com To: Alex Williamson Return-path: In-Reply-To: <1313859105.6866.192.camel@x201.home> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org Sender: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org List-Id: kvm.vger.kernel.org On 08/20/2011 07:51 PM, Alex Williamson wrote: > We need to address both the description and enforcement of device > groups. Groups are formed any time the iommu does not have resolution > between a set of devices. On x86, this typically happens when a > PCI-to-PCI bridge exists between the set of devices and the iommu. For > Power, partitionable endpoints define a group. Grouping information > needs to be exposed for both userspace and kernel internal usage. This > will be a sysfs attribute setup by the iommu drivers. Perhaps: > > # cat /sys/devices/pci0000:00/0000:00:19.0/iommu_group > 42 > $ readlink /sys/devices/pci0000:00/0000:00:19.0/iommu_group ../../../path/to/device/which/represents/the/resource/constraint (the pci-to-pci bridge on x86, or whatever node represents partitionable endpoints on power) -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by ozlabs.org (Postfix) with ESMTP id 00FE0B6F7F for ; Mon, 22 Aug 2011 16:31:10 +1000 (EST) Message-ID: <4E51F782.7060005@redhat.com> Date: Mon, 22 Aug 2011 09:30:26 +0300 From: Avi Kivity MIME-Version: 1.0 To: Alex Williamson Subject: Re: kvm PCI assignment & VFIO ramblings References: <1311983933.8793.42.camel@pasglop> <1312050011.2265.185.camel@x201.home> <20110802082848.GD29719@yookeroo.fritz.box> <1312308847.2653.467.camel@bling.home> <1312310121.2653.470.camel@bling.home> <20110803020422.GF29719@yookeroo.fritz.box> <4E3F9E33.5000706@redhat.com> <1312932258.4524.55.camel@bling.home> <1312944513.29273.28.camel@pasglop> <1313859105.6866.192.camel@x201.home> In-Reply-To: <1313859105.6866.192.camel@x201.home> Content-Type: text/plain; charset=UTF-8; format=flowed Cc: chrisw , Alexey Kardashevskiy , kvm@vger.kernel.org, Paul Mackerras , qemu-devel , aafabbri , iommu , Anthony Liguori , "linux-pci@vger.kernel.org" , linuxppc-dev , benve@cisco.com List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On 08/20/2011 07:51 PM, Alex Williamson wrote: > We need to address both the description and enforcement of device > groups. Groups are formed any time the iommu does not have resolution > between a set of devices. On x86, this typically happens when a > PCI-to-PCI bridge exists between the set of devices and the iommu. For > Power, partitionable endpoints define a group. Grouping information > needs to be exposed for both userspace and kernel internal usage. This > will be a sysfs attribute setup by the iommu drivers. Perhaps: > > # cat /sys/devices/pci0000:00/0000:00:19.0/iommu_group > 42 > $ readlink /sys/devices/pci0000:00/0000:00:19.0/iommu_group ../../../path/to/device/which/represents/the/resource/constraint (the pci-to-pci bridge on x86, or whatever node represents partitionable endpoints on power) -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain. From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:42097) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvO2W-0006D3-9S for qemu-devel@nongnu.org; Mon, 22 Aug 2011 02:31:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QvO2V-0004uL-CU for qemu-devel@nongnu.org; Mon, 22 Aug 2011 02:31:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:11911) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvO2U-0004u4-TL for qemu-devel@nongnu.org; Mon, 22 Aug 2011 02:31:15 -0400 Message-ID: <4E51F782.7060005@redhat.com> Date: Mon, 22 Aug 2011 09:30:26 +0300 From: Avi Kivity MIME-Version: 1.0 References: <1311983933.8793.42.camel@pasglop> <1312050011.2265.185.camel@x201.home> <20110802082848.GD29719@yookeroo.fritz.box> <1312308847.2653.467.camel@bling.home> <1312310121.2653.470.camel@bling.home> <20110803020422.GF29719@yookeroo.fritz.box> <4E3F9E33.5000706@redhat.com> <1312932258.4524.55.camel@bling.home> <1312944513.29273.28.camel@pasglop> <1313859105.6866.192.camel@x201.home> In-Reply-To: <1313859105.6866.192.camel@x201.home> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] kvm PCI assignment & VFIO ramblings List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alex Williamson Cc: chrisw , Alexey Kardashevskiy , kvm@vger.kernel.org, Paul Mackerras , qemu-devel , aafabbri , iommu , "linux-pci@vger.kernel.org" , linuxppc-dev , benve@cisco.com On 08/20/2011 07:51 PM, Alex Williamson wrote: > We need to address both the description and enforcement of device > groups. Groups are formed any time the iommu does not have resolution > between a set of devices. On x86, this typically happens when a > PCI-to-PCI bridge exists between the set of devices and the iommu. For > Power, partitionable endpoints define a group. Grouping information > needs to be exposed for both userspace and kernel internal usage. This > will be a sysfs attribute setup by the iommu drivers. Perhaps: > > # cat /sys/devices/pci0000:00/0000:00:19.0/iommu_group > 42 > $ readlink /sys/devices/pci0000:00/0000:00:19.0/iommu_group ../../../path/to/device/which/represents/the/resource/constraint (the pci-to-pci bridge on x86, or whatever node represents partitionable endpoints on power) -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain.