Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-18 Thread David Gibson
On Wed, Jun 10, 2020 at 11:37:14PM +0200, Halil Pasic wrote: > On Wed, 10 Jun 2020 14:25:54 +1000 > David Gibson wrote: > > > > > I'm going to definitely have a good look at that. What I think special > > > > about s390 is that F_ACCESS_PLATFORM is hurting us because all IO needs > > > > to go

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-18 Thread David Gibson
On Wed, Jun 10, 2020 at 03:57:03PM +0200, Halil Pasic wrote: > On Wed, 10 Jun 2020 14:29:29 +1000 > David Gibson wrote: > > > On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > > > On Tue, 9 Jun 2020 17:47:47 +0200 > > > Claudio Imbrenda wrote: > > > > > > > On Tue, 9 Jun 2020

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-18 Thread David Gibson
On Wed, Jun 10, 2020 at 03:19:22PM +0200, Viktor Mihajlovski wrote: > > > On 6/10/20 12:24 PM, David Hildenbrand wrote: > > On 10.06.20 12:07, David Gibson wrote: > > > On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: > > > > On 10.06.20 06:31, David Gibson wrote: > > > > > On

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-18 Thread David Gibson
On Wed, Jun 10, 2020 at 12:24:14PM +0200, David Hildenbrand wrote: > On 10.06.20 12:07, David Gibson wrote: > > On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: > >> On 10.06.20 06:31, David Gibson wrote: > >>> On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Halil Pasic
On Wed, 10 Jun 2020 14:25:54 +1000 David Gibson wrote: > > > I'm going to definitely have a good look at that. What I think special > > > about s390 is that F_ACCESS_PLATFORM is hurting us because all IO needs > > > to go through ZONE_DMA (this is a problem of the implementation that > > >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread David Hildenbrand
On 10.06.20 15:19, Viktor Mihajlovski wrote: > > > On 6/10/20 12:24 PM, David Hildenbrand wrote: >> On 10.06.20 12:07, David Gibson wrote: >>> On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: On 10.06.20 06:31, David Gibson wrote: > On Tue, Jun 09, 2020 at 12:44:39PM

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Halil Pasic
On Wed, 10 Jun 2020 14:29:29 +1000 David Gibson wrote: > On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > > On Tue, 9 Jun 2020 17:47:47 +0200 > > Claudio Imbrenda wrote: > > > > > On Tue, 9 Jun 2020 11:41:30 +0200 > > > Halil Pasic wrote: > > > > > > [...] > > > > > > > I

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Halil Pasic
On Wed, 10 Jun 2020 12:24:14 +0200 David Hildenbrand wrote: > On 10.06.20 12:07, David Gibson wrote: > > On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: > >> On 10.06.20 06:31, David Gibson wrote: > >>> On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Halil Pasic
On Tue, 9 Jun 2020 18:05:59 +0200 Cornelia Huck wrote: > Which devices are compatible in the end? It seems the only ones that > are known to be working are virtio-ccw devices with IOMMU_PLATFORM on. > virtio-pci devices and non-virtio ccw (vfio-ccw, 3270) seem to be out, > as far as I understand

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Viktor Mihajlovski
On 6/10/20 12:24 PM, David Hildenbrand wrote: On 10.06.20 12:07, David Gibson wrote: On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: On 10.06.20 06:31, David Gibson wrote: On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: On Tue, Jun 09, 2020 at

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread Halil Pasic
On Tue, 9 Jun 2020 12:44:39 -0400 "Michael S. Tsirkin" wrote: > On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > > On Tue, 9 Jun 2020 17:47:47 +0200 > > Claudio Imbrenda wrote: > > > > > On Tue, 9 Jun 2020 11:41:30 +0200 > > > Halil Pasic wrote: > > > > > > [...] > > > > > > >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread David Hildenbrand
On 10.06.20 12:07, David Gibson wrote: > On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: >> On 10.06.20 06:31, David Gibson wrote: >>> On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > On

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread David Gibson
On Wed, Jun 10, 2020 at 09:22:45AM +0200, David Hildenbrand wrote: > On 10.06.20 06:31, David Gibson wrote: > > On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: > >> On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > >>> On Tue, 9 Jun 2020 17:47:47 +0200 > >>>

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-10 Thread David Hildenbrand
On 10.06.20 06:31, David Gibson wrote: > On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: >> On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: >>> On Tue, 9 Jun 2020 17:47:47 +0200 >>> Claudio Imbrenda wrote: >>> On Tue, 9 Jun 2020 11:41:30 +0200 Halil

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread David Gibson
On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > On Tue, 9 Jun 2020 17:47:47 +0200 > Claudio Imbrenda wrote: > > > On Tue, 9 Jun 2020 11:41:30 +0200 > > Halil Pasic wrote: > > > > [...] > > > > > I don't know. Janosch could answer that, but he is on vacation. Adding > > >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread David Gibson
On Tue, Jun 09, 2020 at 08:44:02AM +0200, Cornelia Huck wrote: > On Mon, 8 Jun 2020 19:00:45 +0200 > Halil Pasic wrote: > > > > > I'm also not 100% sure about migration... would it make sense to > > > discuss all of this in the context of the cross-arch patchset? It seems > > > power has

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread David Gibson
On Tue, Jun 09, 2020 at 12:44:39PM -0400, Michael S. Tsirkin wrote: > On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > > On Tue, 9 Jun 2020 17:47:47 +0200 > > Claudio Imbrenda wrote: > > > > > On Tue, 9 Jun 2020 11:41:30 +0200 > > > Halil Pasic wrote: > > > > > > [...] > > > > >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Halil Pasic
On Tue, 9 Jun 2020 18:05:59 +0200 Cornelia Huck wrote: > > > > do we really have that many incompatible devices? > > Which devices are compatible in the end? It seems the only ones that > are known to be working are virtio-ccw devices with IOMMU_PLATFORM on. > virtio-pci devices and

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Michael S. Tsirkin
On Tue, Jun 09, 2020 at 05:47:47PM +0200, Claudio Imbrenda wrote: > On Tue, 9 Jun 2020 11:41:30 +0200 > Halil Pasic wrote: > > [...] > > > I don't know. Janosch could answer that, but he is on vacation. Adding > > Claudio maybe he can answer. My understanding is, that while it might > > be

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Michael S. Tsirkin
On Tue, Jun 09, 2020 at 06:28:39PM +0200, Halil Pasic wrote: > On Tue, 9 Jun 2020 17:47:47 +0200 > Claudio Imbrenda wrote: > > > On Tue, 9 Jun 2020 11:41:30 +0200 > > Halil Pasic wrote: > > > > [...] > > > > > I don't know. Janosch could answer that, but he is on vacation. Adding > > >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Halil Pasic
On Tue, 9 Jun 2020 17:47:47 +0200 Claudio Imbrenda wrote: > On Tue, 9 Jun 2020 11:41:30 +0200 > Halil Pasic wrote: > > [...] > > > I don't know. Janosch could answer that, but he is on vacation. Adding > > Claudio maybe he can answer. My understanding is, that while it might > > be possible,

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Cornelia Huck
On Tue, 9 Jun 2020 17:47:47 +0200 Claudio Imbrenda wrote: > On Tue, 9 Jun 2020 11:41:30 +0200 > Halil Pasic wrote: > > [...] > > > I don't know. Janosch could answer that, but he is on vacation. Adding > > Claudio maybe he can answer. My understanding is, that while it might > > be possible,

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Claudio Imbrenda
On Tue, 9 Jun 2020 11:41:30 +0200 Halil Pasic wrote: [...] > I don't know. Janosch could answer that, but he is on vacation. Adding > Claudio maybe he can answer. My understanding is, that while it might > be possible, it is ugly at best. The ability to do a transition is > indicated by a CPU

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Pierre Morel
On 2020-06-09 11:41, Halil Pasic wrote: On Tue, 9 Jun 2020 08:44:02 +0200 Cornelia Huck wrote: On Mon, 8 Jun 2020 19:00:45 +0200 Halil Pasic wrote: ...snip... I mean, can a virtio devices without IOMMU_PLATFORM act as a transition blocker (i.e. an attempt by a guest to move to pv

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Halil Pasic
On Tue, 9 Jun 2020 08:44:02 +0200 Cornelia Huck wrote: > On Mon, 8 Jun 2020 19:00:45 +0200 > Halil Pasic wrote: > > > > > I'm also not 100% sure about migration... would it make sense to > > > discuss all of this in the context of the cross-arch patchset? It seems > > > power has similar

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-09 Thread Cornelia Huck
On Mon, 8 Jun 2020 19:00:45 +0200 Halil Pasic wrote: > > I'm also not 100% sure about migration... would it make sense to > > discuss all of this in the context of the cross-arch patchset? It seems > > power has similar issues. > > > > I'm going to definitely have a good look at that. What

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-08 Thread Halil Pasic
[..] > > Let me list some pros and cons (compared to the previous patch): > > > > PRO: > > * Thanks to on/off/auto we don't override what the user specified. From > > user interface perspective preferable. I usually hate software that > > thinks its than me and can do the opposite I tell it. >

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-08 Thread Michael S. Tsirkin
On Sat, Jun 06, 2020 at 01:32:17AM +0200, Halil Pasic wrote: > On Wed, 20 May 2020 12:23:24 -0400 > "Michael S. Tsirkin" wrote: > > > On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > > > The virtio specification tells that the device is to present > > > VIRTIO_F_ACCESS_PLATFORM

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-08 Thread Cornelia Huck
On Sat, 6 Jun 2020 01:32:17 +0200 Halil Pasic wrote: > On Wed, 20 May 2020 12:23:24 -0400 > "Michael S. Tsirkin" wrote: > > > On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > > > The virtio specification tells that the device is to present > > > VIRTIO_F_ACCESS_PLATFORM (a.k.a.

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-06-05 Thread Halil Pasic
On Wed, 20 May 2020 12:23:24 -0400 "Michael S. Tsirkin" wrote: > On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > > The virtio specification tells that the device is to present > > VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the > > device "can only access

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-28 Thread Halil Pasic
On Thu, 28 May 2020 16:42:49 +0200 Janosch Frank wrote: > On 5/28/20 1:21 PM, Cornelia Huck wrote: > >> I think we have "allow protected" already expressed via cpu models. I'm > >> also not sure how libvirt would react to the idea of a new machine > >> property for this. You did mean "allow

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-28 Thread Halil Pasic
On Thu, 28 May 2020 13:21:12 +0200 Cornelia Huck wrote: > On Fri, 22 May 2020 23:04:51 +0200 > Halil Pasic wrote: > > > On Wed, 20 May 2020 12:23:24 -0400 > > "Michael S. Tsirkin" wrote: [..] > > > So, how about this: switch iommu to on/off/auto. > > > > Many thanks for the reveiw, and

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-28 Thread Janosch Frank
On 5/28/20 1:21 PM, Cornelia Huck wrote: > On Fri, 22 May 2020 23:04:51 +0200 > Halil Pasic wrote: > >> On Wed, 20 May 2020 12:23:24 -0400 >> "Michael S. Tsirkin" wrote: >> >>> On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: The virtio specification tells that the device is

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-28 Thread Cornelia Huck
On Fri, 22 May 2020 23:04:51 +0200 Halil Pasic wrote: > On Wed, 20 May 2020 12:23:24 -0400 > "Michael S. Tsirkin" wrote: > > > On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > > > The virtio specification tells that the device is to present > > > VIRTIO_F_ACCESS_PLATFORM

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-22 Thread Halil Pasic
On Wed, 20 May 2020 12:23:24 -0400 "Michael S. Tsirkin" wrote: > On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > > The virtio specification tells that the device is to present > > VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the > > device "can only access

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-20 Thread Michael S. Tsirkin
On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote: > The virtio specification tells that the device is to present > VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the > device "can only access certain memory addresses with said access > specified and/or granted by the

Re: [PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-20 Thread Halil Pasic
On Fri, 15 May 2020 00:11:55 +0200 Halil Pasic wrote: > The virtio specification tells that the device is to present > VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the > device "can only access certain memory addresses with said access > specified and/or granted by the

[PATCH v2 1/1] virtio-ccw: auto-manage VIRTIO_F_IOMMU_PLATFORM if PV

2020-05-14 Thread Halil Pasic
The virtio specification tells that the device is to present VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the device "can only access certain memory addresses with said access specified and/or granted by the platform". This is the case for a protected VMs, as the device can