Re: [PATCH] virtio-blk: Use kobj_to_dev() instead of container_of()

2020-08-21 Thread Stefan Hajnoczi
On Fri, Aug 21, 2020 at 09:19:15AM +0800, Tian Tao wrote: > Use kobj_to_dev() instead of container_of() > > Signed-off-by: Tian Tao > --- > drivers/block/virtio_blk.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.as

Re: [PATCH 02/10] block: virtio-blk: check logical block size

2020-07-28 Thread Stefan Hajnoczi
ile changed, 13 insertions(+), 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: Interesting qemu/virt-manager bug about the "rotational" attribute on virtio-blk disks

2020-07-23 Thread Stefan Hajnoczi
On Thu, Jul 16, 2020 at 11:33:44AM +0200, Stefano Garzarella wrote: > +Cc Michael, Stefan, virtualization@lists.linux-foundation.org > > On Thu, Jul 16, 2020 at 09:06:14AM +0100, Richard W.M. Jones wrote: > > > > https://bugzilla.redhat.com/show_bug.cgi?id=1857515 > > > > A virtio-blk disk

Re: [PATCH] vhost/scsi: fix up req type endian-ness

2020-07-13 Thread Stefan Hajnoczi
rnel.org > Signed-off-by: Michael S. Tsirkin > --- > drivers/vhost/scsi.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization

Re: [PATCH] vsock/virtio: annotate 'the_virtio_vsock' RCU pointer

2020-07-13 Thread Stefan Hajnoczi
eref] > __rcu * > net/vmw_vsock/virtio_transport.c:631:9:struct virtio_vsock * > > Fixes: 0deab087b16a ("vsock/virtio: use RCU to avoid use-after-free on > the_virtio_vsock") > Reported-by: Michael S. Tsirkin > Signed-off-by: Stefano Garzarella > --- >

Re: [RFC 0/3] virtio: NUMA-aware memory allocation

2020-06-30 Thread Stefan Hajnoczi
On Mon, Jun 29, 2020 at 11:28:41AM -0400, Michael S. Tsirkin wrote: > On Mon, Jun 29, 2020 at 10:26:46AM +0100, Stefan Hajnoczi wrote: > > On Sun, Jun 28, 2020 at 02:34:37PM +0800, Jason Wang wrote: > > > > > > On 2020/6/25 下午9:57, Stefan Hajnoczi wrote: > >

Re: [RFC 0/3] virtio: NUMA-aware memory allocation

2020-06-29 Thread Stefan Hajnoczi
On Sun, Jun 28, 2020 at 02:34:37PM +0800, Jason Wang wrote: > > On 2020/6/25 下午9:57, Stefan Hajnoczi wrote: > > These patches are not ready to be merged because I was unable to measure a > > performance improvement. I'm publishing them so they are archived in case > > so

[RFC 3/3] virtio-blk: use NUMA-aware memory allocation in probe

2020-06-25 Thread Stefan Hajnoczi
data that is not accessed from performance-critical code paths. Signed-off-by: Stefan Hajnoczi --- drivers/block/virtio_blk.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c index 9d21bf0f155e..40845e9ad3b1

[RFC 1/3] virtio-pci: use NUMA-aware memory allocation in probe

2020-06-25 Thread Stefan Hajnoczi
to worry about data that is not accessed from performance-critical code paths. Signed-off-by: Stefan Hajnoczi --- drivers/virtio/virtio_pci_common.c | 16 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/drivers/virtio/virtio_pci_common.c b/drivers/virtio

[RFC 0/3] virtio: NUMA-aware memory allocation

2020-06-25 Thread Stefan Hajnoczi
that virtqueues and driver state is allocated in vNUMA node 1 where the virtio-blk-pci device is located. The fio 4KB randread benchmark results do not show a significant improvement: Name IOPS Error virtio-blk42373.79 =C2=B1 0.54% virtio-blk-numa 42517.07 =C2=B1 0.79% Stefan

[RFC 2/3] virtio_ring: use NUMA-aware memory allocation in probe

2020-06-25 Thread Stefan Hajnoczi
n Cc: Mel Gorman Signed-off-by: Stefan Hajnoczi --- I have included the alloc_pages_exact_nid() __meminit removal in this patch to provide context for reviewers. --- include/linux/gfp.h | 2 +- drivers/virtio/virtio_ring.c | 26 +- mm/page_alloc.c

Re: [RFC v9 09/11] vhost/scsi: switch to buf APIs

2020-06-22 Thread Stefan Hajnoczi
on virtio_scsi_ctrl_tmf_resp\n"); > } The curly brackets are not necessary, but the patch still looks fine: Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [RFC v9 10/11] vhost/vsock: switch to the buf API

2020-06-22 Thread Stefan Hajnoczi
> 1 file changed, 18 insertions(+), 12 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH V2] drivers/block: Use kobj_to_dev() API

2020-06-22 Thread Stefan Hajnoczi
On Sat, Jun 20, 2020 at 09:53:43AM +0800, Wang Qing wrote: > Use kobj_to_dev() API instead of container_of(). > > Signed-off-by: Wang Qing > --- > drivers/block/virtio_blk.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.as

Re: [PATCH] drivers\block: Use kobj_to_dev() API

2020-06-19 Thread Stefan Hajnoczi
ivers/block/virtio_blk.c Please fix the '\' -> '/' in the commit message. Looks good otherwise: Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.

Re: [PATCH RFC v5 11/13] vhost/scsi: switch to buf APIs

2020-06-08 Thread Stefan Hajnoczi
ers/vhost/scsi.c | 73 ++-- > 1 file changed, 44 insertions(+), 29 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.li

Re: [PATCH RFC v5 12/13] vhost/vsock: switch to the buf API

2020-06-08 Thread Stefan Hajnoczi
On Sun, Jun 07, 2020 at 10:11:49AM -0400, Michael S. Tsirkin wrote: > A straight-forward conversion. > > Signed-off-by: Michael S. Tsirkin > --- > drivers/vhost/vsock.c | 30 ++ > 1 file changed, 18 insertions(+), 12 deletions(-) Reviewed-b

Re: [PATCH RFC 11/13] vhost/scsi: switch to buf APIs

2020-06-05 Thread Stefan Hajnoczi
t drivers might be happier (especially drivers for niche OSes that were only tested against QEMU's virtio-scsi). On the other hand, it's a guest-visible change that could break similar niche drivers that assume length is always 0. I'd leave i

Re: [PATCH RFC 12/13] vhost/vsock: switch to the buf API

2020-06-05 Thread Stefan Hajnoczi
On Tue, Jun 02, 2020 at 09:06:22AM -0400, Michael S. Tsirkin wrote: > A straight-forward conversion. > > Signed-off-by: Michael S. Tsirkin > --- > drivers/vhost/vsock.c | 30 ++ > 1 file changed, 18 insertions(+), 12 deletions(-) Reviewed-b

[PATCH v4] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-30 Thread Stefan Hajnoczi
all cases. Fixes: 48e4043d4529523cbc7fa8dd745bd8e2c45ce1d3 ("virtio: add virtio disk geometry feature") Reported-by: Lance Digby Signed-off-by: Stefan Hajnoczi --- v4: * Clarify vdev_mutex usage [Stefano and Michael] drivers/block/virtio_blk.c | 86 +++

Re: [PATCH v3] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-30 Thread Stefan Hajnoczi
On Thu, Apr 30, 2020 at 10:43:23AM +0200, Stefano Garzarella wrote: > On Wed, Apr 29, 2020 at 05:53:45PM +0100, Stefan Hajnoczi wrote: > > A userspace process holding a file descriptor to a virtio_blk device can > > still invoke block_device_operations after hot unplug. This lea

[PATCH v3] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-29 Thread Stefan Hajnoczi
all cases. Fixes: 48e4043d4529523cbc7fa8dd745bd8e2c45ce1d3 ("virtio: add virtio disk geometry feature") Reported-by: Lance Digby Signed-off-by: Stefan Hajnoczi --- drivers/block/virtio_blk.c | 87 ++ 1 file changed, 79 insertions(+), 8 delet

Re: [PATCH v2] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-28 Thread Stefan Hajnoczi
On Tue, Apr 28, 2020 at 11:25:07AM -0400, Michael S. Tsirkin wrote: > On Tue, Apr 28, 2020 at 03:30:09PM +0100, Stefan Hajnoczi wrote: > > A userspace process holding a file descriptor to a virtio_blk device can > > still invoke block_device_operations after hot unplug. For example

[PATCH v2] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-28 Thread Stefan Hajnoczi
ported-by: Lance Digby Signed-off-by: Stefan Hajnoczi --- If someone has a simpler solution please let me know. I looked at various approaches including reusing device_lock(>vdev.dev) but they were more complex and extending the lifetime of virtio_device after remove() has been called seems que

Re: [PATCH] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-24 Thread Stefan Hajnoczi
On Thu, Apr 23, 2020 at 07:13:38AM -0700, Christoph Hellwig wrote: > On Thu, Apr 23, 2020 at 01:37:17PM +0100, Stefan Hajnoczi wrote: > > A virtio_blk block device can still be referenced after hot unplug by > > userspace processes that hold the file descriptor. In this case >

[PATCH] virtio-blk: handle block_device_operations callbacks after hot unplug

2020-04-23 Thread Stefan Hajnoczi
block device reference exists. Originally-by: Lance Digby Signed-off-by: Stefan Hajnoczi --- drivers/block/virtio_blk.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c index 93468b7c6701..b50cdf37a6f7 100644 --- a/drivers/block/virtio

Re: [PATCH net] vsock/virtio: postpone packet delivery to monitoring devices

2020-04-22 Thread Stefan Hajnoczi
On Tue, Apr 21, 2020 at 06:17:24PM +0200, Stefano Garzarella wrote: > On Tue, Apr 21, 2020 at 04:42:46PM +0100, Stefan Hajnoczi wrote: > > On Tue, Apr 21, 2020 at 11:25:27AM +0200, Stefano Garzarella wrote: > > > We delivering packets to monitoring devices, before to check if &

Re: [PATCH net] vsock/virtio: postpone packet delivery to monitoring devices

2020-04-21 Thread Stefan Hajnoczi
On Tue, Apr 21, 2020 at 11:25:27AM +0200, Stefano Garzarella wrote: > We delivering packets to monitoring devices, before to check if > the virtqueue has enough space. "We [are] delivering packets" and "before to check" -> "before checking". Perhaps it can be rewritten as: Packets are

Re: [PATCH v8 09/19] virtio: stop using legacy struct vring in kernel

2020-04-07 Thread Stefan Hajnoczi
drivers/block/virtio_blk.c | 1 + > include/linux/virtio.h | 1 - > include/linux/virtio_ring.h | 10 ++ > include/linux/vringh.h | 1 + > include/uapi/linux/virtio_ring.h | 26 -- > 5 files changed, 28 insertions(+), 11 delet

Re: [PATCH 0/2] doc: zh_CN: facilitate translation for filesystems

2020-03-15 Thread Stefan Hajnoczi
tation/translations/zh_CN/filesystems/index.rst > create mode 100644 Documentation/translations/zh_CN/filesystems/virtiofs.rst > > -- > 2.17.1 > I am not a Chinese speaker but thank you for translation the documentation! Acked-by: Stefan Hajnoczi signature.asc Description: PGP s

Re: [virtio-dev] VIRTIO adoption in other hypervisors

2020-02-28 Thread Stefan Hajnoczi
On Fri, Feb 28, 2020 at 10:16:21AM +, Alex Bennée wrote: > I'm currently trying to get my head around virtio and was wondering how > widespread adoption of virtio is amongst the various hypervisors and > emulators out there. > > Obviously I'm familiar with QEMU both via KVM and even when just

Re: [PATCH net] vsock: fix potential deadlock in transport->release()

2020-02-27 Thread Stefan Hajnoczi
ff-by: Stefano Garzarella > --- > net/vmw_vsock/af_vsock.c| 20 > net/vmw_vsock/hyperv_transport.c| 3 --- > net/vmw_vsock/virtio_transport_common.c | 2 -- > 3 files changed, 12 insertions(+), 13 deletions(-) Reviewed-by: Stefan Hajnoc

Re: [PATCH 0/2] virtio-blk: improve handling of DMA mapping failures

2020-02-19 Thread Stefan Hajnoczi
ue error to BLK_STS > > drivers/block/virtio_blk.c | 17 - > 1 file changed, 12 insertions(+), 5 deletions(-) > > > base-commit: 39bed42de2e7d74686a2d5a45638d6a5d7e7d473 > -- > 2.17.1 > Review

Re: [PATCH net-next 0/3] vsock: support network namespace

2020-01-21 Thread Stefan Hajnoczi
What should vsock_dev_do_ioctl() IOCTL_VM_SOCKETS_GET_LOCAL_CID return? The answer is probably dependent on the caller's network namespace. Ultimately we may need per-namespace transports. Imagine assigning a G2H transport to a specific network namespace. vsock_stream_connect() needs to be

Re: [PATCH net-next 1/3] vsock: add network namespace support

2020-01-21 Thread Stefan Hajnoczi
On Tue, Jan 21, 2020 at 09:31:42AM -0500, Michael S. Tsirkin wrote: > On Tue, Jan 21, 2020 at 01:59:07PM +0000, Stefan Hajnoczi wrote: > > On Tue, Jan 21, 2020 at 10:07:06AM +0100, Stefano Garzarella wrote: > > > On Mon, Jan 20, 2020 at 11:02 PM Michael S. Tsirkin > >

Re: [PATCH net-next 1/3] vsock: add network namespace support

2020-01-21 Thread Stefan Hajnoczi
On Tue, Jan 21, 2020 at 06:14:48AM -0500, Michael S. Tsirkin wrote: > On Tue, Jan 21, 2020 at 10:07:06AM +0100, Stefano Garzarella wrote: > > On Mon, Jan 20, 2020 at 11:02 PM Michael S. Tsirkin wrote: > > > On Mon, Jan 20, 2020 at 05:53:39PM +0100, Stefano Garzarella wrote: > > > > On Mon, Jan

Re: [PATCH net-next 1/3] vsock: add network namespace support

2020-01-21 Thread Stefan Hajnoczi
On Tue, Jan 21, 2020 at 10:07:06AM +0100, Stefano Garzarella wrote: > On Mon, Jan 20, 2020 at 11:02 PM Michael S. Tsirkin wrote: > > On Mon, Jan 20, 2020 at 05:53:39PM +0100, Stefano Garzarella wrote: > > > On Mon, Jan 20, 2020 at 5:04 PM Michael S. Tsirkin > > > wrote: > > > > On Mon, Jan 20,

Re: [PATCH v3 13/22] compat_ioctl: scsi: move ioctl handling into drivers

2020-01-02 Thread Stefan Hajnoczi
c | 57 ++-- > drivers/scsi/st.c | 51 -- > fs/compat_ioctl.c | 132 + > 7 files changed, 142 insertions(+), 204 deletions(-) virtio_blk.c changes: Acked-

Re: [PATCH net-next v3 00/11] VSOCK: add vsock_test test suite

2019-12-19 Thread Stefan Hajnoczi
w Patch 10 prints a list of options in the help > - new Patch 11 tests MSG_PEEK flags of recv(2) > > v2: https://patchwork.ozlabs.org/cover/1140538/ > v1: https://patchwork.ozlabs.org/cover/847998/ > > Stefan Hajnoczi (7): > VSOCK: fix header include in vsock_diag_test >

Re: [PATCH] virtio-blk: remove VIRTIO_BLK_F_SCSI support

2019-12-13 Thread Stefan Hajnoczi
--- > drivers/block/virtio_blk.c| 115 +- > 3 files changed, 1 insertion(+), 125 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtuali

Re: [RFC PATCH 0/3] vsock: support network namespace

2019-12-03 Thread Stefan Hajnoczi
On Thu, Nov 28, 2019 at 06:15:16PM +0100, Stefano Garzarella wrote: > Hi, > now that we have multi-transport upstream, I started to take a look to > support network namespace (netns) in vsock. > > As we partially discussed in the multi-transport proposal [1], it could > be nice to support network

Re: [PATCH net-next 4/6] vsock: add vsock_loopback transport

2019-11-22 Thread Stefan Hajnoczi
On Thu, Nov 21, 2019 at 04:25:17PM +0100, Stefano Garzarella wrote: > On Thu, Nov 21, 2019 at 10:59:48AM +0100, Stefano Garzarella wrote: > > On Thu, Nov 21, 2019 at 09:34:58AM +0000, Stefan Hajnoczi wrote: > > > On Tue, Nov 19, 2019 at 12:01:19PM +0100, Stefano Garzarella wrot

Re: [PATCH net-next 5/6] vsock: use local transport when it is loaded

2019-11-21 Thread Stefan Hajnoczi
On Tue, Nov 19, 2019 at 12:01:20PM +0100, Stefano Garzarella wrote: > @@ -420,9 +436,10 @@ int vsock_assign_transport(struct vsock_sock *vsk, > struct vsock_sock *psk) > new_transport = transport_dgram; > break; > case SOCK_STREAM: > - if (remote_cid

Re: [PATCH net-next 0/6] vsock: add local transport support

2019-11-21 Thread Stefan Hajnoczi
et/vmw_vsock/virtio_transport_common.c | 3 - > net/vmw_vsock/vmci_transport.c | 2 +- > net/vmw_vsock/vsock_loopback.c | 217 > 10 files changed, 283 insertions(+), 73 deletions(-) > c

Re: [PATCH net-next 4/6] vsock: add vsock_loopback transport

2019-11-21 Thread Stefan Hajnoczi
On Tue, Nov 19, 2019 at 12:01:19PM +0100, Stefano Garzarella wrote: Ideas for long-term changes below. Reviewed-by: Stefan Hajnoczi > diff --git a/MAINTAINERS b/MAINTAINERS > index 760049454a23..c2a3dc3113ba 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -17239,6 +17239

Re: [PATCH 3/3] virtiofs: Use completions while waiting for queue to be drained

2019-11-13 Thread Stefan Hajnoczi
On Wed, Oct 30, 2019 at 11:07:19AM -0400, Vivek Goyal wrote: > While we wait for queue to finish draining, use completions instead of > uslee_range(). This is better way of waiting for event. s/uslee_range()/usleep_range()/ signature.asc Description: PGP signature

Re: [PATCH 0/3] virtiofs: Small Cleanups for 5.5

2019-11-13 Thread Stefan Hajnoczi
++-- > 1 file changed, 103 insertions(+), 101 deletions(-) > > -- > 2.20.1 > There are typos in the commit descriptions but the code looks fine: Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature

Re: [PATCH 2/3] virtiofs: Do not send forget request "struct list_head" element

2019-11-13 Thread Stefan Hajnoczi
On Wed, Oct 30, 2019 at 11:07:18AM -0400, Vivek Goyal wrote: > We are sending whole of virtio_fs_foreget struct to the other end over s/foreget/forget/ signature.asc Description: PGP signature ___ Virtualization mailing list

Re: [PATCH -next] virtiofs: Fix old-style declaration

2019-11-12 Thread Stefan Hajnoczi
-- > fs/fuse/virtio_fs.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH v2] virtiofs: Use static const, not const static

2019-11-12 Thread Stefan Hajnoczi
:1029:1: warning: ‘static’ is not at beginning of > declaration [-Wold-style-declaration] > const static struct fuse_iqueue_ops virtio_fs_fiq_ops = { > > Reported-by: Hulk Robot > Signed-off-by: zhengbin > --- > v1->v2: modify comment > fs/fuse/virtio_fs.c | 6 +++--- > 1

Re: [PATCH] virtiofs: Use static const, not const static

2019-11-11 Thread Stefan Hajnoczi
On Mon, Nov 11, 2019 at 05:26:41PM +0800, zhengbin wrote: > Move the static keyword to the front of declarations. Please mention why this change is necessary in the commit description. > > Reported-by: Hulk Robot > Signed-off-by: zhengbin > --- > fs/fuse/virtio_fs.c | 6 +++--- > 1 file

Re: [PATCH net-next 08/14] vsock: add vsock_create_connected() called by transports

2019-10-27 Thread Stefan Hajnoczi
te_connected() callable from transports to create > a new socket when a connection request is received. > We also unexported the __vsock_create(). > > Suggested-by: Stefan Hajnoczi > Signed-off-by: Stefano Garzarella > --- > include/net/af_vsock.h | 5

Re: [PATCH net-next 07/14] vsock: handle buffer_size sockopts in the core

2019-10-27 Thread Stefan Hajnoczi
-- > net/vmw_vsock/virtio_transport.c| 8 +-- > net/vmw_vsock/virtio_transport_common.c | 79 --- > net/vmw_vsock/vmci_transport.c | 86 +++-- > net/vmw_vsock/vmci_transport.h | 3 - > 9 files changed, 65 insertions(+),

Re: [PATCH net-next 12/14] vsock/vmci: register vmci_transport only when VMCI guest/host are active

2019-10-27 Thread Stefan Hajnoczi
On Wed, Oct 23, 2019 at 11:55:52AM +0200, Stefano Garzarella wrote: > +static int __init vmci_transport_init(void) > +{ > + int features = VSOCK_TRANSPORT_F_DGRAM; Where is this variable used? signature.asc Description: PGP signature ___

Re: [PATCH net-next 00/14] vsock: add multi-transports support

2019-10-27 Thread Stefan Hajnoczi
On Wed, Oct 23, 2019 at 11:55:40AM +0200, Stefano Garzarella wrote: > This series adds the multi-transports support to vsock, following > this proposal: https://www.spinics.net/lists/netdev/msg575792.html > > With the multi-transports support, we can use VSOCK with nested VMs > (using also

Re: [PATCH -next] virtiofs: remove unused variable 'fc'

2019-10-23 Thread Stefan Hajnoczi
t; > Signed-off-by: YueHaibing > --- > fs/fuse/virtio_fs.c | 2 -- > 1 file changed, 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.or

Re: [PATCH] virtiofs: Remove set but not used variable 'fc'

2019-10-23 Thread Stefan Hajnoczi
not virtio-fs-dev or linux.git/master. Same as "[PATCH -next] virtiofs: remove unused variable 'fc'" (<20191023062130.23068-1-yuehaib...@huawei.com>). Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virt

Re: [PATCH V3 0/7] mdev based hardware virtio offloading support

2019-10-17 Thread Stefan Hajnoczi
On Thu, Oct 17, 2019 at 09:42:53AM +0800, Jason Wang wrote: > > On 2019/10/15 下午10:37, Stefan Hajnoczi wrote: > > On Tue, Oct 15, 2019 at 11:37:17AM +0800, Jason Wang wrote: > > > On 2019/10/15 上午1:49, Stefan Hajnoczi wrote: > > > > On Fri, Oct 11, 2019 at 0

Re: [PATCH] vsock/virtio: remove unused 'work' field from 'struct virtio_vsock_pkt'

2019-10-16 Thread Stefan Hajnoczi
the per-packet 'struct virtio_vsock_pkt' > > Suggested-by: Michael S. Tsirkin > Signed-off-by: Stefano Garzarella > --- > include/linux/virtio_vsock.h | 1 - > 1 file changed, 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature __

Re: [PATCH V3 0/7] mdev based hardware virtio offloading support

2019-10-15 Thread Stefan Hajnoczi
On Tue, Oct 15, 2019 at 11:37:17AM +0800, Jason Wang wrote: > > On 2019/10/15 上午1:49, Stefan Hajnoczi wrote: > > On Fri, Oct 11, 2019 at 04:15:50PM +0800, Jason Wang wrote: > > > There are hardware that can do virtio datapath offloading while having > > > its own

Re: [PATCH net 0/2] vsock: don't allow half-closed socket in the host transports

2019-10-15 Thread Stefan Hajnoczi
On Sat, Oct 12, 2019 at 06:38:46PM -0400, Michael S. Tsirkin wrote: > On Fri, Oct 11, 2019 at 04:34:57PM +0200, Stefano Garzarella wrote: > > On Fri, Oct 11, 2019 at 10:19:13AM -0400, Michael S. Tsirkin wrote: > > > On Fri, Oct 11, 2019 at 03:07:56PM +0200, Stefano Garzarella wrote: > > > > We are

Re: [PATCH V3 0/7] mdev based hardware virtio offloading support

2019-10-14 Thread Stefan Hajnoczi
On Fri, Oct 11, 2019 at 04:15:50PM +0800, Jason Wang wrote: > There are hardware that can do virtio datapath offloading while having > its own control path. This path tries to implement a mdev based > unified API to support using kernel virtio driver to drive those > devices. This is done by

Re: [PATCH V3 6/7] virtio: introduce a mdev based transport

2019-10-14 Thread Stefan Hajnoczi
On Fri, Oct 11, 2019 at 04:15:56PM +0800, Jason Wang wrote: > +struct virtio_mdev_device { > + struct virtio_device vdev; > + struct mdev_device *mdev; > + unsigned long version; > + > + struct virtqueue **vqs; > + /* The lock to protect virtqueue list */ > + spinlock_t

Re: [PATCH V3 5/7] mdev: introduce virtio device and its device ops

2019-10-14 Thread Stefan Hajnoczi
On Fri, Oct 11, 2019 at 04:15:55PM +0800, Jason Wang wrote: > + * @set_vq_cb: Set the interrut calback function for s/interrut/interrupt/ s/calback/callback/ signature.asc Description: PGP signature ___ Virtualization mailing

Re: [PATCH v4 1/5] vsock/virtio: limit the memory used per-socket

2019-10-14 Thread Stefan Hajnoczi
he vring with new 4 KB free buffers > > > > > to avoid starvation of other sockets. > > > > > > > > > > This patch mitigates this issue copying the payload of small > > > > > packets (< 128 bytes) into the buffer of last packet queued, in &

Re: [RFC PATCH 07/13] vsock: handle buffer_size sockopts in the core

2019-10-11 Thread Stefan Hajnoczi
On Thu, Oct 10, 2019 at 11:32:54AM +0200, Stefano Garzarella wrote: > On Wed, Oct 09, 2019 at 01:30:26PM +0100, Stefan Hajnoczi wrote: > > On Fri, Sep 27, 2019 at 01:26:57PM +0200, Stefano Garzarella wrote: > > Another issue is that this patch drops the VIRTIO_VSOCK_MAX_BUF

Re: [PATCH v2 07/11] VSOCK: add AF_VSOCK test cases

2019-10-09 Thread Stefan Hajnoczi
On Wed, Oct 09, 2019 at 12:03:53PM +0200, Stefano Garzarella wrote: > Hi Stefan, > I'm thinking about dividing this test into single applications, one > for each test, do you think it makes sense? > Or is it just a useless complication? I don't mind either way but personally I would leave it as a

Re: [RFC PATCH 00/13] vsock: add multi-transports support

2019-10-09 Thread Stefan Hajnoczi
On Fri, Sep 27, 2019 at 01:26:50PM +0200, Stefano Garzarella wrote: > Hi all, > this series adds the multi-transports support to vsock, following > this proposal: > https://www.spinics.net/lists/netdev/msg575792.html Nice series! I have left a few comments but overall it looks promising. Stefan

Re: [RFC PATCH 13/13] vsock: fix bind() behaviour taking care of CID

2019-10-09 Thread Stefan Hajnoczi
with different CID, and > it prevents a connection to a wrong socket bound to the same > port, but with different CID. > > Signed-off-by: Stefano Garzarella > --- > net/vmw_vsock/af_vsock.c | 10 -- > 1 file changed, 8 insertions(+), 2 deletions(-) Reviewed-

Re: [RFC PATCH 12/13] vsock: prevent transport modules unloading

2019-10-09 Thread Stefan Hajnoczi
ssign_transport(struct vsock_sock *vsk, > struct vsock_sock *psk) > return -ESOCKTNOSUPPORT; > } > > - if (!vsk->transport) > + /* We increase the module refcnt to prevent the tranport unloading s/tranport/transport/ Otherwise: Reviewed-by: Stefan H

Re: [RFC PATCH 11/13] vsock: add 'transport_hg' to handle g2h\h2g transports

2019-10-09 Thread Stefan Hajnoczi
On Fri, Sep 27, 2019 at 01:27:01PM +0200, Stefano Garzarella wrote: > VMCI transport provides both g2h and h2g behaviors in a single > transport. > We are able to set (or not) the g2h behavior, detecting if we > are in a VMware guest (or not), but the h2g feature is always set. > This prevents to

Re: [RFC PATCH 10/13] vsock: add multi-transports support

2019-10-09 Thread Stefan Hajnoczi
On Fri, Sep 27, 2019 at 01:27:00PM +0200, Stefano Garzarella wrote: > RFC: > - I'd like to move MODULE_ALIAS_NETPROTO(PF_VSOCK) to af_vsock.c. > @Jorgen could this break the VMware products? What will cause the vmw_vsock_vmci_transport.ko module to be loaded after you remove

Re: [RFC PATCH 09/13] hv_sock: set VMADDR_CID_HOST in the hvs_remote_addr_init()

2019-10-09 Thread Stefan Hajnoczi
d, 2 insertions(+), 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [RFC PATCH 08/13] vsock: move vsock_insert_unbound() in the vsock_create()

2019-10-09 Thread Stefan Hajnoczi
directly. They always pass NULL as the parent socket, so we could have a more specific function that transports call without a parent sock argument. This would eliminate any concern over moving vsock_insert_unbound() out of this function. In any case, I've checked the code and this patch is corre

Re: [RFC PATCH 07/13] vsock: handle buffer_size sockopts in the core

2019-10-09 Thread Stefan Hajnoczi
On Fri, Sep 27, 2019 at 01:26:57PM +0200, Stefano Garzarella wrote: > @@ -140,18 +145,11 @@ struct vsock_transport { > struct vsock_transport_send_notify_data *); > int (*notify_send_post_enqueue)(struct vsock_sock *, ssize_t, > struct

Re: [RFC PATCH 06/13] vsock: add 'struct vsock_sock *' param to vsock_core_get_transport()

2019-10-09 Thread Stefan Hajnoczi
transport uses this >* function and only while registered. >*/ > - return transport_single; This comment is about protecting transport_single. It no longer applies when using vsk->transport. Please drop it. Otherwise: Reviewed-by: Stefan Hajnoczi signature.asc

Re: [RFC PATCH 05/13] vsock/virtio: add transport parameter to the virtio_transport_reset_no_sock()

2019-10-09 Thread Stefan Hajnoczi
h| 3 +- > net/vmw_vsock/virtio_transport.c| 160 > net/vmw_vsock/virtio_transport_common.c | 12 +- > 4 files changed, 135 insertions(+), 134 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature _

Re: [RFC PATCH 04/13] vsock: add 'transport' member in the struct vsock_sock

2019-10-09 Thread Stefan Hajnoczi
1 + > net/vmw_vsock/af_vsock.c | 56 +++- > 2 files changed, 39 insertions(+), 18 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://

Re: [RFC PATCH 01/13] vsock/vmci: remove unused VSOCK_DEFAULT_CONNECT_TIMEOUT

2019-10-09 Thread Stefan Hajnoczi
T_CONNECT_TIMEOUT is used and defined in > net/vmw_vsock/af_vsock.c > > Signed-off-by: Stefano Garzarella > --- > net/vmw_vsock/vmci_transport.c | 5 - > 1 file changed, 5 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___

Re: [RFC PATCH 03/13] vsock: remove include/linux/vm_sockets.h file

2019-10-09 Thread Stefan Hajnoczi
- > include/net/af_vsock.h| 2 +- > include/net/vsock_addr.h | 2 +- > net/vmw_vsock/vmci_transport_notify.h | 1 - > 4 files changed, 2 insertions(+), 16 deletions(-) > delete mode 100644 include/linux/vm_sockets.h Reviewed-by: Stefan

Re: [RFC PATCH 02/13] vsock: remove vm_sockets_get_local_cid()

2019-10-09 Thread Stefan Hajnoczi
off-by: Stefano Garzarella > --- > include/linux/vm_sockets.h | 2 -- > net/vmw_vsock/af_vsock.c| 10 -- > net/vmw_vsock/virtio_transport_common.c | 2 +- > 3 files changed, 1 insertion(+), 13 deletions(-) Reviewed-by: Stefan Hajnoczi

Re: [PATCH v5 0/4] virtio-fs: shared file system for virtual machines

2019-09-12 Thread Stefan Hajnoczi
On Thu, Sep 12, 2019 at 10:14:11AM +0200, Miklos Szeredi wrote: > On Wed, Sep 11, 2019 at 5:54 PM Stefan Hajnoczi wrote: > > > > On Tue, Sep 10, 2019 at 05:12:02PM +0200, Miklos Szeredi wrote: > > > I've folded the series from Vivek and fixed a couple of TODO comments &

Re: [PATCH v5 0/4] virtio-fs: shared file system for virtual machines

2019-09-11 Thread Stefan Hajnoczi
On Tue, Sep 10, 2019 at 05:12:02PM +0200, Miklos Szeredi wrote: > I've folded the series from Vivek and fixed a couple of TODO comments > myself. AFAICS two issues remain that need to be resolved in the short > term, one way or the other: freeze/restore and full virtqueue. I have researched

Re: [PATCH v5 0/4] virtio-fs: shared file system for virtual machines

2019-09-11 Thread Stefan Hajnoczi
On Tue, Sep 10, 2019 at 05:12:02PM +0200, Miklos Szeredi wrote: > Git tree for this version is available here: > > git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git#virtiofs-v5 > > Only post patches that actually add virtiofs (virtiofs-v5-base..virtiofs-v5). > > I've folded the

Re: [Virtio-fs] [PATCH 00/18] virtiofs: Fix various races and cleanups round 1

2019-09-09 Thread Stefan Hajnoczi
On Sun, Sep 08, 2019 at 07:53:55PM +0800, piaojun wrote: > > > On 2019/9/6 19:52, Miklos Szeredi wrote: > > On Fri, Sep 6, 2019 at 12:36 PM Stefan Hajnoczi wrote: > >> > >> On Fri, Sep 06, 2019 at 10:15:14AM +0200, Miklos Szeredi wrote: > >>> On T

Re: [PATCH 16/18] virtiofs: Use virtio_fs_mutex for races w.r.t ->remove and mount path

2019-09-09 Thread Stefan Hajnoczi
On Fri, Sep 06, 2019 at 09:51:31AM -0400, Vivek Goyal wrote: > On Fri, Sep 06, 2019 at 01:05:34PM +0100, Stefan Hajnoczi wrote: > > On Thu, Sep 05, 2019 at 03:48:57PM -0400, Vivek Goyal wrote: > > > It is possible that a mount is in progress and device is being removed at > &

Re: [PATCH 15/18] virtiofs: Make virtio_fs object refcounted

2019-09-09 Thread Stefan Hajnoczi
On Fri, Sep 06, 2019 at 09:50:32AM -0400, Vivek Goyal wrote: > On Fri, Sep 06, 2019 at 01:03:09PM +0100, Stefan Hajnoczi wrote: > > On Thu, Sep 05, 2019 at 03:48:56PM -0400, Vivek Goyal wrote: > > > This object is used both by fuse_connection as well virt device. So make

Re: [PATCH 08/18] virtiofs: Drain all pending requests during ->remove time

2019-09-09 Thread Stefan Hajnoczi
On Fri, Sep 06, 2019 at 10:18:49AM -0400, Michael S. Tsirkin wrote: > On Fri, Sep 06, 2019 at 10:17:05AM -0400, Vivek Goyal wrote: > > On Fri, Sep 06, 2019 at 11:52:10AM +0100, Stefan Hajnoczi wrote: > > > On Thu, Sep 05, 2019 at 03:48:49PM -0400, Vivek Goyal wrote: &g

Re: [PATCH 18/18] virtiofs: Remove TODO item from virtio_fs_free_devs()

2019-09-06 Thread Stefan Hajnoczi
nal locking yet. > > Signed-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 2 -- > 1 file changed, 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lis

Re: [PATCH 17/18] virtiofs: Remove TODO to quiesce/end_requests

2019-09-06 Thread Stefan Hajnoczi
gned-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 2 -- > 1 file changed, 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org

Re: [PATCH 16/18] virtiofs: Use virtio_fs_mutex for races w.r.t ->remove and mount path

2019-09-06 Thread Stefan Hajnoczi
nces. This is fine for now. Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH 15/18] virtiofs: Make virtio_fs object refcounted

2019-09-06 Thread Stefan Hajnoczi
On Thu, Sep 05, 2019 at 03:48:56PM -0400, Vivek Goyal wrote: > This object is used both by fuse_connection as well virt device. So make > this object reference counted and that makes it easy to define life cycle > of the object. > > Now deivce can be removed while filesystem is still mounted.

Re: [PATCH 14/18] virtiofs: Add a fuse_iqueue operation to put() reference

2019-09-06 Thread Stefan Hajnoczi
On Thu, Sep 05, 2019 at 03:48:55PM -0400, Vivek Goyal wrote: > diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h > index 85e2dcad68c1..04e2c000d63f 100644 > --- a/fs/fuse/fuse_i.h > +++ b/fs/fuse/fuse_i.h > @@ -479,6 +479,11 @@ struct fuse_iqueue_ops { >*/ > void

Re: [PATCH 13/18] virtiofs: Do not access virtqueue in request submission path

2019-09-06 Thread Stefan Hajnoczi
pointer deference. > > Signed-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailin

Re: [PATCH 12/18] virtiofs: Use virtio_fs_free_devs() in error path

2019-09-06 Thread Stefan Hajnoczi
On Thu, Sep 05, 2019 at 03:48:53PM -0400, Vivek Goyal wrote: > We already have an helper to cleanup fuse devices. Use that instead of > duplicating the code. > > Signed-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-)

Re: [PATCH 11/18] virtiofs: stop and drain queues after sending DESTROY

2019-09-06 Thread Stefan Hajnoczi
me > just to be sure and then free up the devices. > > Given drain queues will call flush_work() on various workers, remove this > logic from virtio_free_devs(). > > Signed-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 11 --- > 1 file changed, 8 insertions(+),

Re: [PATCH 10/18] virtiofs: Do not use device managed mem for virtio_fs and virtio_fs_vq

2019-09-06 Thread Stefan Hajnoczi
st reference to object is dropped. > > Signed-off-by: Vivek Goyal > --- > fs/fuse/virtio_fs.c | 13 - > 1 file changed, 8 insertions(+), 5 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtua

Re: [PATCH 09/18] virtiofs: Add an helper to start all the queues

2019-09-06 Thread Stefan Hajnoczi
eletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH 08/18] virtiofs: Drain all pending requests during ->remove time

2019-09-06 Thread Stefan Hajnoczi
On Thu, Sep 05, 2019 at 03:48:49PM -0400, Vivek Goyal wrote: > +static void virtio_fs_drain_queue(struct virtio_fs_vq *fsvq) > +{ > + WARN_ON(fsvq->in_flight < 0); > + > + /* Wait for in flight requests to finish.*/ > + while (1) { > + spin_lock(>lock); > + if

Re: [PATCH 07/18] virtiofs: Stop virtiofs queues when device is being removed

2019-09-06 Thread Stefan Hajnoczi
fuse/virtio_fs.c | 14 ++ > 1 file changed, 14 insertions(+) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundat

  1   2   3   4   5   >