Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-25 Thread Michael S. Tsirkin
On Thu, Jul 25, 2019 at 08:00:23AM -0600, Alex Williamson wrote: > On Thu, 25 Jul 2019 06:43:04 -0400 > "Michael S. Tsirkin" wrote: > > > On Thu, Jul 25, 2019 at 02:37:33PM +0800, Peter Xu wrote: > > > After re-read Michael's reply, I feel like what Michael suggested is > > > that we can simply

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-25 Thread Singh, Brijesh
On 7/24/19 2:42 PM, Alex Williamson wrote: > On Wed, 24 Jul 2019 08:43:55 -0600 > Alex Williamson wrote: > >> On Wed, 24 Jul 2019 18:03:31 +0800 >> Peter Xu wrote: >> >>> On Wed, Jul 24, 2019 at 05:39:22AM -0400, Michael S. Tsirkin wrote: On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-25 Thread Alex Williamson
On Thu, 25 Jul 2019 06:43:04 -0400 "Michael S. Tsirkin" wrote: > On Thu, Jul 25, 2019 at 02:37:33PM +0800, Peter Xu wrote: > > After re-read Michael's reply, I feel like what Michael suggested is > > that we can simply ignore the bus-number-change case by the guest OS > > for now, but I might be

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-25 Thread Michael S. Tsirkin
On Thu, Jul 25, 2019 at 02:37:33PM +0800, Peter Xu wrote: > After re-read Michael's reply, I feel like what Michael suggested is > that we can simply ignore the bus-number-change case by the guest OS > for now, but I might be wrong. That's what I suggested, yes.

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-25 Thread Peter Xu
On Wed, Jul 24, 2019 at 08:43:55AM -0600, Alex Williamson wrote: > On Wed, 24 Jul 2019 18:03:31 +0800 > Peter Xu wrote: > > > On Wed, Jul 24, 2019 at 05:39:22AM -0400, Michael S. Tsirkin wrote: > > > On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter Xu wrote: > > > > On Tue, Jul 23, 2019 at

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-24 Thread Alex Williamson
On Wed, 24 Jul 2019 08:43:55 -0600 Alex Williamson wrote: > On Wed, 24 Jul 2019 18:03:31 +0800 > Peter Xu wrote: > > > On Wed, Jul 24, 2019 at 05:39:22AM -0400, Michael S. Tsirkin wrote: > > > On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter Xu wrote: > > > > On Tue, Jul 23, 2019 at

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-24 Thread Alex Williamson
On Wed, 24 Jul 2019 18:03:31 +0800 Peter Xu wrote: > On Wed, Jul 24, 2019 at 05:39:22AM -0400, Michael S. Tsirkin wrote: > > On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter Xu wrote: > > > On Tue, Jul 23, 2019 at 11:26:18AM -0600, Alex Williamson wrote: > > > > > On 3/29/19 11:49 AM, Alex

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-24 Thread Peter Xu
On Wed, Jul 24, 2019 at 05:39:22AM -0400, Michael S. Tsirkin wrote: > On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter Xu wrote: > > On Tue, Jul 23, 2019 at 11:26:18AM -0600, Alex Williamson wrote: > > > > On 3/29/19 11:49 AM, Alex Williamson wrote: > > > > > [Cc +Brijesh] > > > > > > > > > > Hi

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-24 Thread Michael S. Tsirkin
On Wed, Jul 24, 2019 at 03:14:39PM +0800, Peter Xu wrote: > On Tue, Jul 23, 2019 at 11:26:18AM -0600, Alex Williamson wrote: > > > On 3/29/19 11:49 AM, Alex Williamson wrote: > > > > [Cc +Brijesh] > > > > > > > > Hi Brijesh, will the change below require the IVRS to be updated to > > > > include

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-24 Thread Peter Xu
On Tue, Jul 23, 2019 at 11:26:18AM -0600, Alex Williamson wrote: > > On 3/29/19 11:49 AM, Alex Williamson wrote: > > > [Cc +Brijesh] > > > > > > Hi Brijesh, will the change below require the IVRS to be updated to > > > include aliases for all BDF ranges behind a conventional bridge? I > > >

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-23 Thread Michael S. Tsirkin
On Tue, Jul 23, 2019 at 11:26:18AM -0600, Alex Williamson wrote: > On Mon, 1 Apr 2019 13:41:39 + > "Singh, Brijesh" wrote: > > > Thanks for adding Alex. > > > > Adding Suravee. > > > > > > On 3/29/19 11:49 AM, Alex Williamson wrote: > > > [Cc +Brijesh] > > > > > > Hi Brijesh, will the

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-07-23 Thread Alex Williamson
On Mon, 1 Apr 2019 13:41:39 + "Singh, Brijesh" wrote: > Thanks for adding Alex. > > Adding Suravee. > > > On 3/29/19 11:49 AM, Alex Williamson wrote: > > [Cc +Brijesh] > > > > Hi Brijesh, will the change below require the IVRS to be updated to > > include aliases for all BDF ranges

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-04-01 Thread Singh, Brijesh
Thanks for adding Alex. Adding Suravee. On 3/29/19 11:49 AM, Alex Williamson wrote: > [Cc +Brijesh] > > Hi Brijesh, will the change below require the IVRS to be updated to > include aliases for all BDF ranges behind a conventional bridge? I > think the Linux code handles this regardless of

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-29 Thread Alex Williamson
[Cc +Brijesh] Hi Brijesh, will the change below require the IVRS to be updated to include aliases for all BDF ranges behind a conventional bridge? I think the Linux code handles this regardless of the firmware provided aliases, but is it required per spec for the ACPI tables to include bridge

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-28 Thread Robin Murphy
On 28/03/2019 12:53, Auger Eric wrote: Hi Robin, On 3/28/19 11:56 AM, Robin Murphy wrote: On 28/03/2019 10:38, Auger Eric wrote: Hi Alex, [+ Robin] On 3/27/19 5:37 PM, Alex Williamson wrote: On Wed, 27 Mar 2019 14:25:00 +0800 Peter Xu wrote: On Tue, Mar 26, 2019 at 04:55:19PM -0600,

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-28 Thread Robin Murphy
On 28/03/2019 10:38, Auger Eric wrote: Hi Alex, [+ Robin] On 3/27/19 5:37 PM, Alex Williamson wrote: On Wed, 27 Mar 2019 14:25:00 +0800 Peter Xu wrote: On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: Conventional PCI buses pre-date requester IDs. An IOMMU cannot

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-28 Thread Auger Eric
Hi Robin, On 3/28/19 11:56 AM, Robin Murphy wrote: > On 28/03/2019 10:38, Auger Eric wrote: >> Hi Alex, >> >> [+ Robin] >> >> On 3/27/19 5:37 PM, Alex Williamson wrote: >>> On Wed, 27 Mar 2019 14:25:00 +0800 >>> Peter Xu wrote: >>> On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-28 Thread Auger Eric
Hi Alex, [+ Robin] On 3/27/19 5:37 PM, Alex Williamson wrote: > On Wed, 27 Mar 2019 14:25:00 +0800 > Peter Xu wrote: > >> On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: >>> Conventional PCI buses pre-date requester IDs. An IOMMU cannot >>> distinguish by devfn & bus between

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Peter Xu
On Wed, Mar 27, 2019 at 11:35:35AM -0400, Michael S. Tsirkin wrote: > On Wed, Mar 27, 2019 at 02:25:00PM +0800, Peter Xu wrote: > > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > > distinguish by devfn &

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Peter Xu
On Wed, Mar 27, 2019 at 10:37:09AM -0600, Alex Williamson wrote: > On Wed, 27 Mar 2019 14:25:00 +0800 > Peter Xu wrote: > > > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > > distinguish by devfn & bus

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Alex Williamson
On Wed, 27 Mar 2019 19:07:44 +0100 Auger Eric wrote: > Hi Alex, > > On 3/27/19 7:02 PM, Alex Williamson wrote: > > On Wed, 27 Mar 2019 12:46:41 +0100 > > Auger Eric wrote: > > > >> Hi Alex, > >> > >> On 3/26/19 11:55 PM, Alex Williamson wrote: > >>> Conventional PCI buses pre-date

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Alex Williamson
On Wed, 27 Mar 2019 12:46:41 +0100 Auger Eric wrote: > Hi Alex, > > On 3/26/19 11:55 PM, Alex Williamson wrote: > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > distinguish by devfn & bus between devices in a conventional PCI > > topology and therefore we cannot assign

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Auger Eric
Hi Alex, On 3/27/19 7:02 PM, Alex Williamson wrote: > On Wed, 27 Mar 2019 12:46:41 +0100 > Auger Eric wrote: > >> Hi Alex, >> >> On 3/26/19 11:55 PM, Alex Williamson wrote: >>> Conventional PCI buses pre-date requester IDs. An IOMMU cannot >>> distinguish by devfn & bus between devices in a

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Alex Williamson
On Wed, 27 Mar 2019 17:43:45 +0100 Auger Eric wrote: > Hi, > > On 3/27/19 4:32 PM, Michael S. Tsirkin wrote: > > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > >> Conventional PCI buses pre-date requester IDs. An IOMMU cannot > >> distinguish by devfn & bus between

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Alex Williamson
On Wed, 27 Mar 2019 11:32:55 -0400 "Michael S. Tsirkin" wrote: > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > distinguish by devfn & bus between devices in a conventional PCI > > topology and therefore we

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Michael S. Tsirkin
On Wed, Mar 27, 2019 at 05:43:45PM +0100, Auger Eric wrote: > Hi, > > On 3/27/19 4:32 PM, Michael S. Tsirkin wrote: > > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > >> Conventional PCI buses pre-date requester IDs. An IOMMU cannot > >> distinguish by devfn & bus between

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Auger Eric
Hi, On 3/27/19 4:32 PM, Michael S. Tsirkin wrote: > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: >> Conventional PCI buses pre-date requester IDs. An IOMMU cannot >> distinguish by devfn & bus between devices in a conventional PCI >> topology and therefore we cannot assign

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Alex Williamson
On Wed, 27 Mar 2019 14:25:00 +0800 Peter Xu wrote: > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > distinguish by devfn & bus between devices in a conventional PCI > > topology and therefore we cannot

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Michael S. Tsirkin
On Wed, Mar 27, 2019 at 02:25:00PM +0800, Peter Xu wrote: > On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > > distinguish by devfn & bus between devices in a conventional PCI > > topology and therefore we cannot

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Michael S. Tsirkin
On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > distinguish by devfn & bus between devices in a conventional PCI > topology and therefore we cannot assign them separate AddressSpaces. > By taking this requester ID

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Auger Eric
Hi Alex, On 3/26/19 11:55 PM, Alex Williamson wrote: > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > distinguish by devfn & bus between devices in a conventional PCI > topology and therefore we cannot assign them separate AddressSpaces. > By taking this requester ID aliasing

Re: [Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-27 Thread Peter Xu
On Tue, Mar 26, 2019 at 04:55:19PM -0600, Alex Williamson wrote: > Conventional PCI buses pre-date requester IDs. An IOMMU cannot > distinguish by devfn & bus between devices in a conventional PCI > topology and therefore we cannot assign them separate AddressSpaces. > By taking this requester ID

[Qemu-devel] [RFC PATCH] pci: Use PCI aliases when determining device IOMMU address space

2019-03-26 Thread Alex Williamson
Conventional PCI buses pre-date requester IDs. An IOMMU cannot distinguish by devfn & bus between devices in a conventional PCI topology and therefore we cannot assign them separate AddressSpaces. By taking this requester ID aliasing into account, QEMU better matches the bare metal behavior and