Re: [PATCH 10/10] virtio/s390: make airq summary indicators DMA

2019-05-19 Thread Pierre Morel
On 26/04/2019 20:32, Halil Pasic wrote: Hypervisor needs to interact with the summary indicators, so these need to be DMA memory as well (at least for protected virtualization guests). Signed-off-by: Halil Pasic --- drivers/s390/virtio/virtio_ccw.c | 24 +--- 1 file

Re: [Qemu-devel] [PATCH v7 2/6] virtio-pmem: Add virtio pmem driver

2019-05-19 Thread Jakub Staroń via Virtualization
On 5/8/19 4:12 AM, Pankaj Gupta wrote: > >> >> On 4/25/19 10:00 PM, Pankaj Gupta wrote: >> >>> +void host_ack(struct virtqueue *vq) >>> +{ >>> + unsigned int len; >>> + unsigned long flags; >>> + struct virtio_pmem_request *req, *req_buf; >>> + struct virtio_pmem *vpmem = vq->vdev->priv;

Re: [PATCH 09/10] virtio/s390: use DMA memory for ccw I/O and classic notifiers

2019-05-19 Thread Pierre Morel
On 08/05/2019 16:46, Pierre Morel wrote: On 26/04/2019 20:32, Halil Pasic wrote: Before virtio-ccw could get away with not using DMA API for the pieces of memory it does ccw I/O with. With protected virtualization this has to change, since the hypervisor needs to read and sometimes also write

Re: [PATCH 09/10] virtio/s390: use DMA memory for ccw I/O and classic notifiers

2019-05-19 Thread Pierre Morel
On 26/04/2019 20:32, Halil Pasic wrote: Before virtio-ccw could get away with not using DMA API for the pieces of memory it does ccw I/O with. With protected virtualization this has to change, since the hypervisor needs to read and sometimes also write these pieces of memory. The hypervisor is

Re: [PATCH 08/10] virtio/s390: add indirection to indicators access

2019-05-19 Thread Pierre Morel
On 10/05/2019 13:54, Halil Pasic wrote: On Fri, 10 May 2019 09:43:08 +0200 Pierre Morel wrote: On 09/05/2019 20:26, Halil Pasic wrote: On Thu, 9 May 2019 14:01:01 +0200 Pierre Morel wrote: On 08/05/2019 16:31, Pierre Morel wrote: On 26/04/2019 20:32, Halil Pasic wrote: This will come in

Re: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization

2019-05-19 Thread Jason J. Herne
Subject: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization Date: Fri, 26 Apr 2019 20:32:39 +0200 From: Halil Pasic To: k...@vger.kernel.org, linux-s...@vger.kernel.org, Cornelia Huck , Martin Schwidefsky , Sebastian Ott CC: Halil Pasic ,

Re: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization

2019-05-19 Thread Claudio Imbrenda
On Thu, 9 May 2019 14:05:20 -0400 "Jason J. Herne" wrote: [...] > > +#define sme_me_mask    0ULL > > + > > +static inline bool sme_active(void) { return false; } > > +extern bool sev_active(void); > > + > > I noticed this patch always returns false for sme_active. Is it safe > to assume that

Re: [PATCH 08/10] virtio/s390: add indirection to indicators access

2019-05-19 Thread Pierre Morel
On 09/05/2019 20:26, Halil Pasic wrote: On Thu, 9 May 2019 14:01:01 +0200 Pierre Morel wrote: On 08/05/2019 16:31, Pierre Morel wrote: On 26/04/2019 20:32, Halil Pasic wrote: This will come in handy soon when we pull out the indicators from virtio_ccw_device to a memory area that is shared

Re: [PATCH 08/10] virtio/s390: add indirection to indicators access

2019-05-19 Thread Pierre Morel
On 08/05/2019 16:31, Pierre Morel wrote: On 26/04/2019 20:32, Halil Pasic wrote: This will come in handy soon when we pull out the indicators from virtio_ccw_device to a memory area that is shared with the hypervisor (in particular for protected virtualization guests). Signed-off-by: Halil

Re: [PATCH 01/10] virtio/s390: use vring_create_virtqueue

2019-05-19 Thread Michael Mueller
On 13.05.19 11:52, Cornelia Huck wrote: On Sun, 12 May 2019 12:47:39 -0400 "Michael S. Tsirkin" wrote: On Fri, May 10, 2019 at 04:07:44PM +0200, Cornelia Huck wrote: On Tue, 7 May 2019 15:58:12 +0200 Christian Borntraeger wrote: On 05.05.19 13:15, Cornelia Huck wrote: On Sat, 4 May

[PATCH RESEND] vsock/virtio: Initialize core virtio vsock before registering the driver

2019-05-19 Thread Jorge E. Moreira via Virtualization
Avoid a race in which static variables in net/vmw_vsock/af_vsock.c are accessed (while handling interrupts) before they are initialized. [4.201410] BUG: unable to handle kernel paging request at ffe8 [4.207829] IP: vsock_addr_equals_addr+0x3/0x20 [4.211379] PGD 28210067

Re: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization

2019-05-19 Thread Michael Mueller
On 10.05.19 00:34, Halil Pasic wrote: On Wed, 8 May 2019 15:15:40 +0200 Claudio Imbrenda wrote: On Fri, 26 Apr 2019 20:32:39 +0200 Halil Pasic wrote: On s390, protected virtualization guests have to use bounced I/O buffers. That requires some plumbing. Let us make sure, any device that

Re: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization

2019-05-19 Thread Michael Mueller
On 29.04.19 16:05, Christian Borntraeger wrote: On 29.04.19 15:59, Halil Pasic wrote: On Fri, 26 Apr 2019 12:27:11 -0700 Christoph Hellwig wrote: On Fri, Apr 26, 2019 at 08:32:39PM +0200, Halil Pasic wrote: +EXPORT_SYMBOL_GPL(set_memory_encrypted);

Re: [PATCH 06/10] s390/cio: add basic protected virtualization support

2019-05-19 Thread Jason J. Herne
On 5/13/19 5:41 AM, Cornelia Huck wrote: On Fri, 26 Apr 2019 20:32:41 +0200 Halil Pasic wrote: As virtio-ccw devices are channel devices, we need to use the dma area for any communication with the hypervisor. This patch addresses the most basic stuff (mostly what is required for virtio-ccw),

Re: [PATCH 10/10] virtio/s390: make airq summary indicators DMA

2019-05-19 Thread Michael Mueller
On 08.05.19 17:11, Pierre Morel wrote: On 26/04/2019 20:32, Halil Pasic wrote: Hypervisor needs to interact with the summary indicators, so these need to be DMA memory as well (at least for protected virtualization guests). Signed-off-by: Halil Pasic ---   drivers/s390/virtio/virtio_ccw.c |

Re: [PATCH 10/10] virtio/s390: make airq summary indicators DMA

2019-05-19 Thread Michael Mueller
On 13.05.19 14:20, Cornelia Huck wrote: On Fri, 26 Apr 2019 20:32:45 +0200 Halil Pasic wrote: Hypervisor needs to interact with the summary indicators, so these need to be DMA memory as well (at least for protected virtualization guests). Signed-off-by: Halil Pasic ---

Re: [PATCH 08/10] virtio/s390: add indirection to indicators access

2019-05-19 Thread Pierre Morel
On 13/05/2019 12:15, Cornelia Huck wrote: On Fri, 10 May 2019 17:36:05 +0200 Pierre Morel wrote: On 10/05/2019 13:54, Halil Pasic wrote: On Fri, 10 May 2019 09:43:08 +0200 Pierre Morel wrote: On 09/05/2019 20:26, Halil Pasic wrote: On Thu, 9 May 2019 14:01:01 +0200 Pierre Morel

Re: [PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver

2019-05-19 Thread Jorge Moreira Broche via Virtualization
> On Wed, May 01, 2019 at 03:08:31PM -0400, Stefan Hajnoczi wrote: > > On Tue, Apr 30, 2019 at 05:30:01PM -0700, Jorge E. Moreira wrote: > > > Avoid a race in which static variables in net/vmw_vsock/af_vsock.c are > > > accessed (while handling interrupts) before they are initialized. > > > > > >

Re: [Qemu-devel] [PATCH v7 2/6] virtio-pmem: Add virtio pmem driver

2019-05-19 Thread Jakub Staroń via Virtualization
On 4/25/19 10:00 PM, Pankaj Gupta wrote: > +void host_ack(struct virtqueue *vq) > +{ > + unsigned int len; > + unsigned long flags; > + struct virtio_pmem_request *req, *req_buf; > + struct virtio_pmem *vpmem = vq->vdev->priv; > + > + spin_lock_irqsave(>pmem_lock, flags); > +

Re: [PATCH 06/10] s390/cio: add basic protected virtualization support

2019-05-19 Thread Pierre Morel
On 26/04/2019 20:32, Halil Pasic wrote: As virtio-ccw devices are channel devices, we need to use the dma area for any communication with the hypervisor. This patch addresses the most basic stuff (mostly what is required for virtio-ccw), and does take care of QDIO or any devices. An

Re: Xorg hangs in kernelspace with qxl

2019-05-19 Thread Jaak Ristioja
On 02.05.19 08:26, Gerd Hoffmann wrote: > On Wed, May 01, 2019 at 12:47:48AM +0300, Jaak Ristioja wrote: >> Hello! >> >> I'm experiencing the following task hangs at least 2-3 times a day when >> using a Kubuntu desktop in KVM via a SPICE client. This has occurred >> with the stock kernels in

Re: [PATCH 08/10] virtio/s390: add indirection to indicators access

2019-05-19 Thread Pierre Morel
On 26/04/2019 20:32, Halil Pasic wrote: This will come in handy soon when we pull out the indicators from virtio_ccw_device to a memory area that is shared with the hypervisor (in particular for protected virtualization guests). Signed-off-by: Halil Pasic --- drivers/s390/virtio/virtio_ccw.c

Re: [PATCH 04/10] s390/mm: force swiotlb for protected virtualization

2019-05-19 Thread Claudio Imbrenda
On Fri, 26 Apr 2019 20:32:39 +0200 Halil Pasic wrote: > On s390, protected virtualization guests have to use bounced I/O > buffers. That requires some plumbing. > > Let us make sure, any device that uses DMA API with direct ops > correctly is spared from the problems, that a hypervisor

Re: [Qemu-devel] [PATCH v7 4/6] dax: check synchronous mapping is supported

2019-05-19 Thread Jakub Staroń via Virtualization
From: Pankaj Gupta Date: Thu, Apr 25, 2019 at 10:00 PM > +static inline bool daxdev_mapping_supported(struct vm_area_struct *vma, > + struct dax_device *dax_dev) > +{ > + return !(vma->flags & VM_SYNC); > +} Shouldn't it be rather `return !(vma->vm_flags &

[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver

2019-05-19 Thread Jorge E. Moreira via Virtualization
Avoid a race in which static variables in net/vmw_vsock/af_vsock.c are accessed (while handling interrupts) before they are initialized. [4.201410] BUG: unable to handle kernel paging request at ffe8 [4.207829] IP: vsock_addr_equals_addr+0x3/0x20 [4.211379] PGD 28210067

RE: [PATCH v3 09/26] compat_ioctl: move drivers to compat_ptr_ioctl

2019-05-19 Thread Winkler, Tomas
> > On Tue, Apr 16, 2019 at 10:19:47PM +0200, Arnd Bergmann wrote: > > Each of these drivers has a copy of the same trivial helper function > > to convert the pointer argument and then call the native ioctl handler. > > > > We now have a generic implementation of that, so use it. > > > >

[PATCH] virtio_console: remove vq buf while unpluging port

2019-05-19 Thread zhenwei pi
A bug can be easily reproduced: Host# cat guest-agent.xml Host# virsh attach-device instance guest-agent.xml Host# virsh detach-device instance guest-agent.xml Host# virsh attach-device instance guest-agent.xml and guest report: virtio-ports vport0p1: Error allocating inbufs The reason

[PATCH] virtio/virtio_ring: do some comment fixes

2019-05-19 Thread Jiang Biao
There are lots of mismatches between comments and codes, this patch do these comment fixes. Signed-off-by: Jiang Biao --- drivers/virtio/virtio_ring.c | 27 ++- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/drivers/virtio/virtio_ring.c

Re: [PATCH] Revert "drm/qxl: drop prime import/export callbacks"

2019-05-19 Thread Thomas Hellstrom
On 4/26/19 4:21 PM, Daniel Vetter wrote: On Fri, Apr 26, 2019 at 7:33 AM Gerd Hoffmann wrote: This reverts commit f4c34b1e2a37d5676180901fa6ff188bcb6371f8. Simliar to commit a0cecc23cfcb Revert "drm/virtio: drop prime import/export callbacks". We have to do the same with qxl, for the same

[PATCH] virtio_console: remove vq buf while unpluging port

2019-05-19 Thread zhenwei pi
A bug can be easily reproduced: Host# cat guest-agent.xml Host# virsh attach-device instance guest-agent.xml Host# virsh detach-device instance guest-agent.xml Host# virsh attach-device instance guest-agent.xml and guest report: virtio-ports vport0p1: Error allocating inbufs The reason

Xorg hangs in kernelspace with qxl

2019-05-19 Thread Jaak Ristioja
Hello! I'm experiencing the following task hangs at least 2-3 times a day when using a Kubuntu desktop in KVM via a SPICE client. This has occurred with the stock kernels in Kubuntu since Kubuntu 18.04. This makes the VM unusable as a graphical remote desktop and the hung task prevents Kubuntu

Re: [Qemu-devel] [PATCH v9 2/7] virtio-pmem: Add virtio pmem driver

2019-05-19 Thread Pankaj Gupta
> On 5/16/19 10:35 PM, Pankaj Gupta wrote: > > Can I take it your reviewed/acked-by? or tested-by tag? for the virtio > > patch :)I don't feel that I have enough expertise to give the reviewed-by > > tag, but you can > take my acked-by + tested-by. > > Acked-by: Jakub Staron > Tested-by: Jakub

Re: [Qemu-devel] [PATCH v9 2/7] virtio-pmem: Add virtio pmem driver

2019-05-19 Thread Pankaj Gupta
> > > > On 5/16/19 10:35 PM, Pankaj Gupta wrote: > > > Can I take it your reviewed/acked-by? or tested-by tag? for the virtio > > > patch :)I don't feel that I have enough expertise to give the reviewed-by > > > tag, but you can > > take my acked-by + tested-by. > > > > Acked-by: Jakub Staron