Re: [PATCH v2 1/5] VSOCK: support fill mergeable rx buffer in guest

2018-12-14 Thread David Miller
From: jiangyiwen Date: Wed, 12 Dec 2018 17:28:16 +0800 > +static int fill_mergeable_rx_buff(struct virtio_vsock *vsock, > + struct virtqueue *vq) > +{ > + struct page_frag *alloc_frag = >alloc_frag; > + struct scatterlist sg; > + /* Currently we don't use ewma len, use

Re: [PATCH v2 2/5] VSOCK: support fill data to mergeable rx buffer in host

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 05:29:31PM +0800, jiangyiwen wrote: > When vhost support VIRTIO_VSOCK_F_MRG_RXBUF feature, > it will merge big packet into rx vq. > > Signed-off-by: Yiwen Jiang I feel this approach jumps into making interface changes for optimizations too quickly. For example, what

Re: [PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 05:31:39PM +0800, jiangyiwen wrote: > Guest receive mergeable rx buffer, it can merge > scatter rx buffer into a big buffer and then copy > to user space. > > In addition, it also use iovec to replace buf in struct > virtio_vsock_pkt, keep tx and rx consistency. The only >

Re: [virtio-dev] Re: [PATCH v5 5/7] iommu: Add virtio-iommu driver

2018-12-14 Thread Auger Eric
Hi, On 12/12/18 3:56 PM, Michael S. Tsirkin wrote: > On Fri, Dec 07, 2018 at 06:52:31PM +, Jean-Philippe Brucker wrote: >> Sorry for the delay, I wanted to do a little more performance analysis >> before continuing. >> >> On 27/11/2018 18:10, Michael S. Tsirkin wrote: >>> On Tue, Nov 27, 2018

Re: [PATCH v2 0/5] VSOCK: support mergeable rx buffer in vhost-vsock

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 05:25:50PM +0800, jiangyiwen wrote: > Now vsock only support send/receive small packet, it can't achieve > high performance. As previous discussed with Jason Wang, I revisit the > idea of vhost-net about mergeable rx buffer and implement the mergeable > rx buffer in

Re: [virtio-dev] Re: [PATCH v5 5/7] iommu: Add virtio-iommu driver

2018-12-14 Thread Michael S. Tsirkin
On Fri, Dec 07, 2018 at 06:52:31PM +, Jean-Philippe Brucker wrote: > Sorry for the delay, I wanted to do a little more performance analysis > before continuing. > > On 27/11/2018 18:10, Michael S. Tsirkin wrote: > > On Tue, Nov 27, 2018 at 05:55:20PM +, Jean-Philippe Brucker wrote: >

Re: [PATCH v6 0/7] Add virtio-iommu driver

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 11:35:45AM +0100, Joerg Roedel wrote: > Hi, > > to make progress on this, we should first agree on the protocol used > between guest and host. I have a few points to discuss on the protocol > first. > > On Tue, Dec 11, 2018 at 06:20:57PM +, Jean-Philippe Brucker

Re: [PATCH net V2 1/4] vhost: make sure used idx is seen before log in vhost_add_used_n()

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 06:08:16PM +0800, Jason Wang wrote: > We miss a write barrier that guarantees used idx is updated and seen > before log. This will let userspace sync and copy used ring before > used idx is update. Fix this by adding a barrier before log_write(). > > Fixes: 8dd014adfea6f

Re: [PATCH net V2 4/4] vhost: log dirty page correctly

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 06:08:19PM +0800, Jason Wang wrote: > Vhost dirty page logging API is designed to sync through GPA. But we > try to log GIOVA when device IOTLB is enabled. This is wrong and may > lead to missing data after migration. > > To solve this issue, when logging with device IOTLB

Re: [PATCH net V2 3/4] Revert "net: vhost: lock the vqs one by one"

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 06:08:18PM +0800, Jason Wang wrote: > This reverts commit 78139c94dc8c96a478e67dab3bee84dc6eccb5fd. We don't > protect device IOTLB with vq mutex, which will lead e.g use after free > for device IOTLB entries. And since we've switched to use > mutex_trylock() in previous

Re: [PATCH net V2 2/4] vhost_net: switch to use mutex_trylock() in vhost_net_busy_poll()

2018-12-14 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 06:08:17PM +0800, Jason Wang wrote: > We used to hold the mutex of paired virtqueue in > vhost_net_busy_poll(). But this will results an inconsistent lock > order which may cause deadlock if we try to bring back the protection > of device IOTLB with vq mutex that requires

[PATCH v2 17/18] drm/qxl: use generic fbdev emulation

2018-12-14 Thread Gerd Hoffmann
Switch qxl over to the new generic fbdev emulation. Signed-off-by: Gerd Hoffmann --- drivers/gpu/drm/qxl/qxl_display.c | 7 --- drivers/gpu/drm/qxl/qxl_drv.c | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/qxl/qxl_display.c

[PATCH v2 15/18] drm/qxl: use qxl_num_crtc directly

2018-12-14 Thread Gerd Hoffmann
qdev->monitors_config->max_allowed is effectively set by the qxl.num_heads module parameter, stored in the qxl_num_crtc variable. Lets get rid of the indirection and use the variable qxl_num_crtc directly. The kernel doesn't need to dereference pointers each time it needs the value, and when

[PATCH v2 01/18] drm/qxl: drop ttm_mem_reg arg from qxl_hw_surface_alloc()

2018-12-14 Thread Gerd Hoffmann
Not used, is always NULL. Signed-off-by: Gerd Hoffmann --- drivers/gpu/drm/qxl/qxl_drv.h| 3 +-- drivers/gpu/drm/qxl/qxl_cmd.c| 14 ++ drivers/gpu/drm/qxl/qxl_object.c | 2 +- 3 files changed, 4 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/qxl/qxl_drv.h