[PATCH] VSOCK: define VSOCK_SS_LISTEN once only

2015-10-29 Thread Stefan Hajnoczi
way it is clear that the constant is vsock-specific. The big text reflow in af_vsock.c was necessary to keep to the maximum line length. Text is unchanged except for s/SS_LISTEN/VSOCK_SS_LISTEN/. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 3 +++ net/vmw_vsock/af_vsock.c

Re: vhost-blk and qemu

2015-11-23 Thread Stefan Hajnoczi
On Tue, Nov 17, 2015 at 9:23 PM, Mohan G via Virtualization wrote: > I am looking to experiment the vhost-blk stack. Can some one point me to the > latest code version and the corresponding qemu version location. > I am on centos 7 (3.10 ) kernel. I am hoping using the vhost-blk.ko and > correspon

[PATCH v2 1/5] VSOCK: Introduce vsock_find_unbound_socket and vsock_bind_dgram_generic

2015-12-01 Thread Stefan Hajnoczi
From: Asias He Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 2 ++ net/vmw_vsock/af_vsock.c | 70 2 files changed, 72 insertions(+) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index

[PATCH v2 0/5] Add virtio transport for AF_VSOCK

2015-12-01 Thread Stefan Hajnoczi
v2: * Rebased onto Linux v4.4-rc2 * vhost: Refuse to assign reserved CIDs * vhost: Refuse guest CID if already in use * vhost: Only accept correctly addressed packets (no spoofing!) * vhost: Support flexible rx/tx descriptor layout * vhost: Add missing total_tx_buf decrement * virtio_transpo

[PATCH v2 2/5] VSOCK: Introduce virtio-vsock-common.ko

2015-12-01 Thread Stefan Hajnoczi
From: Asias He This module contains the common code and header files for the following virtio-vsock and virtio-vhost kernel modules. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v2: * Fix peer_buf_alloc inheritance on child socket * Notify other side of SOCK_STREAM disconnect

[PATCH v2 5/5] VSOCK: Add Makefile and Kconfig

2015-12-01 Thread Stefan Hajnoczi
From: Asias He Enable virtio-vsock and vhost-vsock. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- drivers/vhost/Kconfig | 4 drivers/vhost/Kconfig.vsock | 7 +++ drivers/vhost/Makefile | 4 net/vmw_vsock/Kconfig | 18 ++ net

[PATCH v2 4/5] VSOCK: Introduce vhost-vsock.ko

2015-12-01 Thread Stefan Hajnoczi
From: Asias He VM sockets vhost transport implementation. This module runs in host kernel. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v2: * Add missing total_tx_buf decrement * Support flexible rx/tx descriptor layout * Refuse to assign reserved CIDs * Refuse guest CID if

[PATCH v2 3/5] VSOCK: Introduce virtio-vsock.ko

2015-12-01 Thread Stefan Hajnoczi
From: Asias He VM sockets virtio transport implementation. This module runs in guest kernel. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v2: * Fix total_tx_buf accounting * Add virtio_transport global mutex to prevent races --- net/vmw_vsock/virtio_transport.c | 466

Re: [PATCH] VSOCK: fix returnvar.cocci warnings

2015-12-06 Thread Stefan Hajnoczi
T_VSOCK_DEFAULT_HOST_CID; > - return cid; > + return VHOST_VSOCK_DEFAULT_HOST_CID; > } > > static struct vhost_vsock *vhost_vsock_get(u32 guest_cid) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___

[PATCH 0/6] VSOCK: revert virtio-vsock until device spec is finalized

2015-12-08 Thread Stefan Hajnoczi
at that point the interfaces will be stable. Stefan Hajnoczi (6): Revert "VSOCK: fix returnvar.cocci warnings" Revert "VSOCK: Add Makefile and Kconfig" Revert "VSOCK: Introduce vhost-vsock.ko" Revert "VSOCK: Introduce virtio-vsock.ko" Revert

[PATCH 1/6] Revert "VSOCK: fix returnvar.cocci warnings"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 0d76d6e8b2507983a2cae4c09880798079007421. Keep virtio-vsock out-of-tree until the virtio-vsock device specification is finalized. Signed-off-by: Stefan Hajnoczi --- drivers/vhost/vsock.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/vhost

[PATCH 2/6] Revert "VSOCK: Add Makefile and Kconfig"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 8a2a2029893b4c35d1aba2932111a1a164b9c948. Keep virtio-vsock out-of-tree until the device specification is finalized. Signed-off-by: Stefan Hajnoczi --- drivers/vhost/Kconfig | 4 drivers/vhost/Kconfig.vsock | 7 --- drivers/vhost/Makefile | 4

[PATCH 3/6] Revert "VSOCK: Introduce vhost-vsock.ko"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 98bb892821c1ad3781b8c7daec2fc8a8de3390c9. Keep virtio-vsock out-of-tree until the device specification is finalized. Signed-off-by: Stefan Hajnoczi --- drivers/vhost/vsock.c | 631 -- drivers/vhost/vsock.h | 4 - 2 files

[PATCH 6/6] Revert "VSOCK: Introduce vsock_find_unbound_socket and vsock_bind_dgram_generic"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 357ab2234d57f6c74386f64ded42dff8e3c0500b. Keep virtio-vsock out-of-tree until the device specification is finalized. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 2 -- net/vmw_vsock/af_vsock.c | 70 2 files

[PATCH 4/6] Revert "VSOCK: Introduce virtio-vsock.ko"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 32e61b06b6946ba137723c5b1de2a1fdb2e0e0a5. Keep virtio-vsock out-of-tree until the device specification is finalized. Signed-off-by: Stefan Hajnoczi --- net/vmw_vsock/virtio_transport.c | 466 --- 1 file changed, 466 deletions(-) delete

[PATCH 5/6] Revert "VSOCK: Introduce virtio-vsock-common.ko"

2015-12-08 Thread Stefan Hajnoczi
This reverts commit 80a19e338d458abb5a700df3fd00795c51361f06. Keep virtio-vsock out-of-tree until the device specification is finalized. Signed-off-by: Stefan Hajnoczi --- include/linux/virtio_vsock.h| 209 - include/uapi/linux/virtio_ids.h |1 - include/uapi/linux

Re: [PATCH v2 0/5] Add virtio transport for AF_VSOCK

2015-12-08 Thread Stefan Hajnoczi
On Fri, Dec 04, 2015 at 09:45:04AM +0200, Michael S. Tsirkin wrote: > On Wed, Dec 02, 2015 at 02:43:58PM +0800, Stefan Hajnoczi wrote: > > 1. The 3-way handshake isn't necessary over a reliable transport > > (virtqueue). > >Spoofing packets is also impossible so the

Re: [PATCH 0/6] VSOCK: revert virtio-vsock until device spec is finalized

2015-12-08 Thread Stefan Hajnoczi
On Tue, Dec 08, 2015 at 11:26:55AM -0500, David Miller wrote: > From: Stefan Hajnoczi > Date: Tue, 8 Dec 2015 19:57:30 +0800 > > > Please revert for now. > > Please don't revert it piece by piece like this. > > Instead, send me one big revert commit that und

[PATCH v2] Revert "Merge branch 'vsock-virtio'"

2015-12-08 Thread Stefan Hajnoczi
this code when the hardware interface (and possibly the userspace interface) could still change. Signed-off-by: Stefan Hajnoczi --- v2: * Revert merge commit and coccinelle fixup in a single patch drivers/vhost/Kconfig |4 - drivers/vhost/Kconfig.vsock |7

[PATCH v3 1/4] VSOCK: Introduce virtio-vsock-common.ko

2015-12-09 Thread Stefan Hajnoczi
From: Asias He This module contains the common code and header files for the following virtio-vsock and virtio-vhost kernel modules. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v3: * Remove unnecessary 3-way handshake, just do REQUEST/RESPONSE instead of REQUEST/RESPONSE

[PATCH v3 2/4] VSOCK: Introduce virtio-vsock.ko

2015-12-09 Thread Stefan Hajnoczi
From: Asias He VM sockets virtio transport implementation. This module runs in guest kernel. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v2: * Fix total_tx_buf accounting * Add virtio_transport global mutex to prevent races --- net/vmw_vsock/virtio_transport.c | 466

[PATCH v3 0/4] Add virtio transport for AF_VSOCK

2015-12-09 Thread Stefan Hajnoczi
Note: the virtio-vsock device specification is currently under review but not yet finalized. Please review this code but don't merge until I send an update when the spec is finalized. Thanks! v3: * Remove unnecessary 3-way handshake, just do REQUEST/RESPONSE instead of REQUEST/RESPONSE/ACK

[PATCH v3 3/4] VSOCK: Introduce vhost-vsock.ko

2015-12-09 Thread Stefan Hajnoczi
From: Asias He VM sockets vhost transport implementation. This module runs in host kernel. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v3: * Remove unneeded variable used to store return value (Fengguang Wu and Julia Lawall ) v2: * Add missing total_tx_buf decrement

[PATCH v3 4/4] VSOCK: Add Makefile and Kconfig

2015-12-09 Thread Stefan Hajnoczi
From: Asias He Enable virtio-vsock and vhost-vsock. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v3: * Don't put vhost vsock driver into staging * Add missing Kconfig dependencies (Arnd Bergmann ) --- drivers/vhost/Kconfig | 10 ++ drivers/vhost/Makefile

Re: [PATCH v3 1/4] VSOCK: Introduce virtio-vsock-common.ko

2015-12-10 Thread Stefan Hajnoczi
On Thu, Dec 10, 2015 at 10:17:07AM +, Alex Bennée wrote: > Stefan Hajnoczi writes: > > > From: Asias He > > > > This module contains the common code and header files for the following > > virtio-vsock and virtio-vhost kernel modules. > > General commen

Re: [PATCH v3 2/4] VSOCK: Introduce virtio-vsock.ko

2015-12-10 Thread Stefan Hajnoczi
On Thu, Dec 10, 2015 at 09:23:25PM +, Alex Bennée wrote: > Stefan Hajnoczi writes: > > > From: Asias He > > > > VM sockets virtio transport implementation. This module runs in guest > > kernel. > > checkpatch warns on a bunch of whitespace/tab i

Re: [PATCH v3 3/4] VSOCK: Introduce vhost-vsock.ko

2015-12-15 Thread Stefan Hajnoczi
On Fri, Dec 11, 2015 at 01:45:29PM +, Alex Bennée wrote: > > + if (head == vq->num) { > > + if (unlikely(vhost_enable_notify(&vsock->dev, vq))) { > > + vhost_disable_notify(&vsock->dev, vq); > > + continue; > > Why

Re: [PATCH v3 4/4] VSOCK: Add Makefile and Kconfig

2015-12-15 Thread Stefan Hajnoczi
On Fri, Dec 11, 2015 at 05:19:08PM +, Alex Bennée wrote: > > +config VHOST_VSOCK > > + tristate "vhost virtio-vsock driver" > > + depends on VSOCKETS && EVENTFD > > + select VIRTIO_VSOCKETS_COMMON > > + select VHOST > > + select VHOST_RING > > + default n > > + ---help--- > > +

[PATCH] virtio: make find_vqs() checkpatch.pl-friendly

2015-12-17 Thread Stefan Hajnoczi
a compiler error due to losing the second const. This patch adjusts the find_vqs() prototype and updates all virtio transports. This makes it possible for virtio_balloon.c, virtio_input.c, virtgpu_kms.c, and virtio_rpmsg_bus.c to use the checkpatch.pl-friendly type. Signed-off-by: Stefan Hajnoczi

[RFC v4 1/5] VSOCK: transport-specific vsock_transport functions

2015-12-22 Thread Stefan Hajnoczi
function pointers. The virtio transport will use this. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 3 +++ net/vmw_vsock/af_vsock.c | 9 + 2 files changed, 12 insertions(+) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index e9eb2d6..23f5525 100644 --- a

[RFC v4 0/5] Add virtio transport for AF_VSOCK

2015-12-22 Thread Stefan Hajnoczi
example above). Status -- This patch series implements the latest draft specification. Please review. Asias He (4): VSOCK: Introduce virtio_vsock_common.ko VSOCK: Introduce virtio_transport.ko VSOCK: Introduce vhost_vsock.ko VSOCK: Add Makefile and Kconfig Stefan Hajnoczi (1): VSO

[RFC v4 2/5] VSOCK: Introduce virtio_vsock_common.ko

2015-12-22 Thread Stefan Hajnoczi
From: Asias He This module contains the common code and header files for the following virtio_transporto and vhost_vsock kernel modules. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v4: * Add MAINTAINERS file entry * checkpatch.pl cleanups * linux_vsock.h: drop wrong copy

[RFC v4 3/5] VSOCK: Introduce virtio_transport.ko

2015-12-22 Thread Stefan Hajnoczi
From: Asias He VM sockets virtio transport implementation. This driver runs in the guest. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v4: * Add MAINTAINERS file entry * Drop short/long rx packets * checkpatch.pl cleanups * Clarify locking in struct virtio_vsock * Narrow

[RFC v4 4/5] VSOCK: Introduce vhost_vsock.ko

2015-12-22 Thread Stefan Hajnoczi
From: Asias He VM sockets vhost transport implementation. This driver runs on the host. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v4: * Add MAINTAINERS file entry * virtqueue used len is now sizeof(pkt->hdr) + pkt->len instead of just pkt->len * checkpatch.pl

[RFC v4 5/5] VSOCK: Add Makefile and Kconfig

2015-12-22 Thread Stefan Hajnoczi
From: Asias He Enable virtio-vsock and vhost-vsock. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v4: * Make checkpatch.pl happy with longer option description * Clarify dependency on virtio rather than QEMU as suggested by Alex Bennee v3: * Don't put vhost vsock d

Re: [RFC v4 0/5] Add virtio transport for AF_VSOCK

2016-01-28 Thread Stefan Hajnoczi
On Tue, Dec 22, 2015 at 05:07:33PM +0800, Stefan Hajnoczi wrote: > This series is based on v4.4-rc2 and the "virtio: make find_vqs() > checkpatch.pl-friendly" patch I recently submitted. > > v4: > * Addressed code review comments from Alex Bennee > * MAINTAINER

virtio-vsock live migration

2016-03-03 Thread Stefan Hajnoczi
Michael pointed out that the virtio-vsock draft specification does not address live migration and in fact currently precludes migration. Migration is fundamental so the device specification at least mustn't preclude it. Having brainstormed migration with Matthew Benjamin and Michael Tsirkin, I am

Re: virtio-vsock live migration

2016-03-15 Thread Stefan Hajnoczi
On Fri, Mar 11, 2016 at 01:56:05AM +0200, Michael S. Tsirkin wrote: > On Thu, Mar 03, 2016 at 03:37:37PM +0000, Stefan Hajnoczi wrote: > > Michael pointed out that the virtio-vsock draft specification does not > > address live migration and in fact currently precludes migration. >

Re: [virtio-dev] virtio-vsock live migration

2016-03-15 Thread Stefan Hajnoczi
On Mon, Mar 14, 2016 at 01:13:24PM +0200, Michael S. Tsirkin wrote: > On Thu, Mar 03, 2016 at 03:37:37PM +0000, Stefan Hajnoczi wrote: > > Michael pointed out that the virtio-vsock draft specification does not > > address live migration and in fact currently precludes migration. >

Re: [virtio-dev] virtio-vsock live migration

2016-03-19 Thread Stefan Hajnoczi
On Tue, Mar 15, 2016 at 06:12:55PM +0200, Michael S. Tsirkin wrote: > On Tue, Mar 15, 2016 at 03:15:29PM +0000, Stefan Hajnoczi wrote: > > On Mon, Mar 14, 2016 at 01:13:24PM +0200, Michael S. Tsirkin wrote: > > > On Thu, Mar 03, 2016 at 03:37:37PM +0000, Stefan Hajnoczi wrot

[RFC v5 1/5] VSOCK: transport-specific vsock_transport functions

2016-04-01 Thread Stefan Hajnoczi
function pointers. The virtio transport will use this. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 3 +++ net/vmw_vsock/af_vsock.c | 9 + 2 files changed, 12 insertions(+) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index e9eb2d6..23f5525 100644 --- a

[RFC v5 0/5] Add virtio transport for AF_VSOCK

2016-04-01 Thread Stefan Hajnoczi
mon.ko VSOCK: Introduce virtio_transport.ko VSOCK: Introduce vhost_vsock.ko VSOCK: Add Makefile and Kconfig Stefan Hajnoczi (1): VSOCK: transport-specific vsock_transport functions MAINTAINERS| 13 + drivers/vhost/Kconfig

[RFC v5 3/5] VSOCK: Introduce virtio_transport.ko

2016-04-01 Thread Stefan Hajnoczi
From: Asias He VM sockets virtio transport implementation. This driver runs in the guest. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v5: * Add transport reset event handling * Drop ctrl virtqueue v4: * Add MAINTAINERS file entry * Drop short/long rx packets

[RFC v5 2/5] VSOCK: Introduce virtio_vsock_common.ko

2016-04-01 Thread Stefan Hajnoczi
From: Asias He This module contains the common code and header files for the following virtio_transporto and vhost_vsock kernel modules. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v5: * Add event virtqueue, struct virtio_vsock_event, and transport reset event * Reorder

[RFC v5 4/5] VSOCK: Introduce vhost_vsock.ko

2016-04-01 Thread Stefan Hajnoczi
From: Asias He VM sockets vhost transport implementation. This driver runs on the host. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v5: * Only take rx/tx virtqueues, userspace handles the other virtqueues * Explicitly skip instances without a CID when transferring packets

[RFC v5 5/5] VSOCK: Add Makefile and Kconfig

2016-04-01 Thread Stefan Hajnoczi
From: Asias He Enable virtio-vsock and vhost-vsock. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v4: * Make checkpatch.pl happy with longer option description * Clarify dependency on virtio rather than QEMU as suggested by Alex Bennee v3: * Don't put vhost vsock d

Re: [virtio-dev] virtio-vsock live migration

2016-04-06 Thread Stefan Hajnoczi
On Wed, Mar 16, 2016 at 05:05:19PM +0200, Michael S. Tsirkin wrote: > > > > NFS and netperf are the first two protocols I looked > > > >at and both transmit address information across the connection... > > > > > > > > > Does netperf really attempt to get local IP > > > and then send that inl

Re: [RFC v5 0/5] Add virtio transport for AF_VSOCK

2016-04-11 Thread Stefan Hajnoczi
On Fri, Apr 08, 2016 at 04:35:05PM +0100, Ian Campbell wrote: > On Fri, 2016-04-01 at 15:23 +0100, Stefan Hajnoczi wrote: > > This series is based on Michael Tsirkin's vhost branch (v4.5-rc6). > > > > I'm about to process Claudio Imbrenda's locking fixes for

Re: [RFC v5 0/5] Add virtio transport for AF_VSOCK

2016-04-12 Thread Stefan Hajnoczi
On Mon, Apr 11, 2016 at 03:54:08PM +0300, Michael S. Tsirkin wrote: > On Mon, Apr 11, 2016 at 11:45:48AM +0100, Stefan Hajnoczi wrote: > > On Fri, Apr 08, 2016 at 04:35:05PM +0100, Ian Campbell wrote: > > > On Fri, 2016-04-01 at 15:23 +0100, Stefan Hajnoczi wrote: > > >

Re: [RFC v5 0/5] Add virtio transport for AF_VSOCK

2016-04-13 Thread Stefan Hajnoczi
On Tue, Apr 12, 2016 at 05:37:54PM +0100, Ian Campbell wrote: > Perhaps the guest end is turning shutdown(foo) directly into a vsock > message without or-ing in the current state? Yes, you are right: lock_sock(sk); sk->sk_shutdown |= mode; sk->sk_state_change(sk); release_sock(sk); if

Re: [PATCH V2 RFC] fixup! virtio: convert to use DMA api

2016-04-21 Thread Stefan Hajnoczi
On Thu, Apr 21, 2016 at 04:43:45PM +0300, Michael S. Tsirkin wrote: > This adds a flag to enable/disable bypassing the IOMMU by > virtio devices. > > This is on top of patch > http://article.gmane.org/gmane.comp.emulators.qemu/403467 > virtio: convert to use DMA api > > Tested with patchset > htt

Re: [PATCH V2 RFC] fixup! virtio: convert to use DMA api

2016-04-22 Thread Stefan Hajnoczi
On Thu, Apr 21, 2016 at 06:11:40PM +0300, Michael S. Tsirkin wrote: > On Thu, Apr 21, 2016 at 03:56:53PM +0100, Stefan Hajnoczi wrote: > > On Thu, Apr 21, 2016 at 04:43:45PM +0300, Michael S. Tsirkin wrote: > > > This adds a flag to enable/disable bypassing the IOMMU by &g

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-18 Thread Stefan Hajnoczi
On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > From: Namhyung Kim > > Add virtio pstore device to allow kernel log files saved on the host. > It will save the log files on the directory given by pstore device > option. > > $ qemu-system-x86_64 -device virtio-pstore,directory=d

Re: [PATCH] content: Reserve virtio device ID for pstore

2016-07-20 Thread Stefan Hajnoczi
| 2 ++ > 1 file changed, 2 insertions(+) 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 2/3] qemu: Implement virtio-pstore device

2016-07-20 Thread Stefan Hajnoczi
On Mon, Jul 18, 2016 at 11:21:18PM +0900, Namhyung Kim wrote: > On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > > > From: Namhyung Kim > > > > > > Add virtio pstore device to

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-20 Thread Stefan Hajnoczi
On Wed, Jul 20, 2016 at 12:48:39AM +0900, Namhyung Kim wrote: > Hello, > > On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > > > +static void virtio_pstore_handle_io(VirtIODev

Re: [PATCH 6/7] qemu: Implement virtio-pstore device

2016-07-28 Thread Stefan Hajnoczi
On Thu, Jul 28, 2016 at 02:39:53PM +0900, Namhyung Kim wrote: > On Thu, Jul 28, 2016 at 03:02:54AM +0300, Michael S. Tsirkin wrote: > > On Thu, Jul 28, 2016 at 12:08:30AM +0900, Namhyung Kim wrote: > > > +static ssize_t virtio_pstore_do_write(VirtIOPstore *s, struct iovec > > > *out_sg, > > > +

[RFC v6 0/6] Add virtio transport for AF_VSOCK

2016-07-28 Thread Stefan Hajnoczi
e above). See http://qemu-project.org/Features/VirtioVsock for more info. Asias He (4): VSOCK: Introduce virtio_vsock_common.ko VSOCK: Introduce virtio_transport.ko VSOCK: Introduce vhost_vsock.ko VSOCK: Add Makefile and Kconfig Stefan Hajnoczi (2): VSOCK: transport-specific vsock_transport fu

[RFC v6 1/6] VSOCK: transport-specific vsock_transport functions

2016-07-28 Thread Stefan Hajnoczi
function pointers. The virtio transport will use this. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 3 +++ net/vmw_vsock/af_vsock.c | 9 + 2 files changed, 12 insertions(+) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index e9eb2d6..23f5525 100644 --- a

[RFC v6 3/6] VSOCK: Introduce virtio_vsock_common.ko

2016-07-28 Thread Stefan Hajnoczi
From: Asias He This module contains the common code and header files for the following virtio_transporto and vhost_vsock kernel modules. Signed-off-by: Asias He Signed-off-by: Claudio Imbrenda Signed-off-by: Stefan Hajnoczi --- v6: * Add graceful shutdown to avoid port reuse while peer is

[RFC v6 2/6] VSOCK: defer sock removal to transports

2016-07-28 Thread Stefan Hajnoczi
. Signed-off-by: Stefan Hajnoczi --- include/net/af_vsock.h | 1 + net/vmw_vsock/af_vsock.c | 16 ++-- net/vmw_vsock/vmci_transport.c | 2 ++ 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index 23f5525

[RFC v6 4/6] VSOCK: Introduce virtio_transport.ko

2016-07-28 Thread Stefan Hajnoczi
From: Asias He VM sockets virtio transport implementation. This driver runs in the guest. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v6: * Start/stop rx depending on reply packet accounting to bound memory allocation if the host is not processing rx packets * 64-bit CID

[RFC v6 6/6] VSOCK: Add Makefile and Kconfig

2016-07-28 Thread Stefan Hajnoczi
From: Asias He Enable virtio-vsock and vhost-vsock. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v6: * Rename to virtio-vsock kernel modules to vmw_vsock_virtio_transport* instead of just virtio_transport to make the name clearer [Ian Campbell] v4: * Make checkpatch.pl

[RFC v6 5/6] VSOCK: Introduce vhost_vsock.ko

2016-07-28 Thread Stefan Hajnoczi
From: Asias He VM sockets vhost transport implementation. This driver runs on the host. Signed-off-by: Asias He Signed-off-by: Stefan Hajnoczi --- v6: * Fall back to non-contiguous pages if vsock struct is too large (idea stolen from vhost_net) * 64-bit CIDs in packet header and ioctl

Re: [PATCH v3] virtio_blk: Fix a slient kernel panic

2016-07-29 Thread Stefan Hajnoczi
off-by: Minfei Huang > --- > v2: > - Remove useless initialisation to NULL > v1: > - Refactor the patch to make code more readable > --- > drivers/block/virtio_blk.c | 26 -- > 1 file changed, 8 insertions(+), 18 deletions(-) Reviewed-by: Stefan Hajn

[PATCH for-4.8] virtio-vsock: fix include guard typo

2016-08-05 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi --- include/uapi/linux/virtio_vsock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/uapi/linux/virtio_vsock.h b/include/uapi/linux/virtio_vsock.h index 6b011c1..1d57ed3 100644 --- a/include/uapi/linux/virtio_vsock.h +++ b/include/uapi

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-09-22 Thread Stefan Hajnoczi
On Sun, Sep 04, 2016 at 11:38:58PM +0900, Namhyung Kim wrote: > The virtio pstore driver provides interface to the pstore subsystem so > that the guest kernel's log/dump message can be saved on the host > machine. Users can access the log file directly on the host, or on the > guest at the next bo

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-09-22 Thread Stefan Hajnoczi
On Sun, Sep 04, 2016 at 11:38:59PM +0900, Namhyung Kim wrote: > +static void virtio_pstore_handle_io(VirtIODevice *vdev, VirtQueue *vq) > +{ > +VirtIOPstore *s = VIRTIO_PSTORE(vdev); > +VirtQueueElement *elem; > +struct virtio_pstore_req req; > +struct virtio_pstore_res res; > +

Re: [PATCH 4/4] virtio_blk: Rename a jump label in virtblk_get_id()

2016-10-03 Thread Stefan Hajnoczi
On Tue, Sep 13, 2016 at 1:15 PM, SF Markus Elfring wrote: > From: Markus Elfring > Date: Tue, 13 Sep 2016 13:50:56 +0200 > > Adjust a jump label according to the current Linux coding style convention. I think you mean "goto label". "Jump label" has a different meaning, see . > Signed-off-by: M

Re: [PATCH 3/4] virtio_blk: Delete an unnecessary initialisation in init_vq()

2016-10-03 Thread Stefan Hajnoczi
c > +++ b/drivers/block/virtio_blk.c > @@ -376,7 +376,7 @@ static void virtblk_config_changed(struct virtio_device > *vdev) > > static int init_vq(struct virtio_blk *vblk) > { > - int err = 0; > + int err; > int i; > v

Re: [PATCH 1/4] virtio_blk: Use kmalloc_array() in init_vq()

2016-10-03 Thread Stefan Hajnoczi
esponding function "kmalloc_array". > > This issue was detected by using the Coccinelle software. > > Signed-off-by: Markus Elfring > --- > drivers/block/virtio_blk.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) Reviewed-by: Stefan Hajnoczi _

Re: virtio_blk: Clarification for communication difficulties?

2016-10-03 Thread Stefan Hajnoczi
On Wed, Sep 14, 2016 at 10:09 AM, SF Markus Elfring wrote: >> FWIW, he already gained a place on my ignore list for pestering me >> offline about his patches and not stopping even when told to do so. > > How did I "pester" you "offline"? > > >> So while I won't object if you choose to apply select

Re: [PATCH] vhost/vsock: Remove unused but set variable

2016-11-15 Thread Stefan Hajnoczi
> Signed-off-by: Tobias Klauser > --- > drivers/vhost/vsock.c | 3 --- > 1 file changed, 3 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualiza

Re: [PATCH] vhost/scsi: Remove unused but set variable

2016-11-15 Thread Stefan Hajnoczi
sed > > Signed-off-by: Tobias Klauser > --- > drivers/vhost/scsi.c | 2 -- > 1 file changed, 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature ___ Virtualization mailing list Virtualiza

Re: [Qemu-devel] Re: [PATCH] virtio-spec: document block CMD and FLUSH

2010-05-03 Thread Stefan Hajnoczi
A userspace barrier API would be very useful instead of doing fsync when only ordering is required. I'd like to follow that discussion too. Stefan On 4 May 2010 05:39, "Rusty Russell" wrote: On Fri, 19 Feb 2010 08:52:20 am Michael S. Tsirkin wrote: > I took a stub at documenting CMD and FLU...

[PATCH RFC] virtio_blk: Use blk-iopoll for host->guest notify

2010-05-17 Thread Stefan Hajnoczi
between guest and host virtio-blk emulation. The blk-iopoll infrastructure is enabled system-wide by default: kernel.blk_iopoll = 1 It can be disabled to always use interrupt-driven mode (useful for comparison): kernel.blk_iopoll = 0 Signed-off-by: Stefan Hajnoczi --- No performance figures

Re: [PATCH RFC] virtio_blk: Use blk-iopoll for host->guest notify

2010-05-18 Thread Stefan Hajnoczi
On Fri, May 14, 2010 at 05:30:56PM -0500, Brian Jackson wrote: > Any preliminary numbers? latency, throughput, cpu use? What about comparing > different "weights"? I am running benchmarks and will report results when they are in. Stefan ___ Virtualizat

[RFC] virtio: Support releasing lock during kick

2010-06-23 Thread Stefan Hajnoczi
not be correct for virtio block to release the lock before calling virtqueue_kick()). Signed-off-by: Stefan Hajnoczi --- I am not yet 100% happy with this patch which aims to reduce guest CPU consumption related to vblk->lock contention. Although this patch reduces wait/hold times it does

Re: [RFC] virtio: Support releasing lock during kick

2010-06-23 Thread Stefan Hajnoczi
On Wed, Jun 23, 2010 at 11:12 PM, Anthony Liguori wrote: > Shouldn't it be possible to just drop the lock before invoking > virtqueue_kick() and reacquire it afterwards?  There's nothing in that > virtqueue_kick() path that the lock is protecting AFAICT. No, that would lead to a race condition be

Re: [RFC] virtio: Support releasing lock during kick

2010-06-24 Thread Stefan Hajnoczi
On Fri, Jun 25, 2010 at 4:09 AM, Rusty Russell wrote: > On Thu, 24 Jun 2010 03:00:30 pm Stefan Hajnoczi wrote: >> On Wed, Jun 23, 2010 at 11:12 PM, Anthony Liguori >> wrote: >> > Shouldn't it be possible to just drop the lock before invoking >> > virtqu

Re: [RFC] virtio: Support releasing lock during kick

2010-06-25 Thread Stefan Hajnoczi
On Fri, Jun 25, 2010 at 01:43:17PM +0300, Michael S. Tsirkin wrote: > On Fri, Jun 25, 2010 at 12:39:21PM +0930, Rusty Russell wrote: > > On Thu, 24 Jun 2010 03:00:30 pm Stefan Hajnoczi wrote: > > > On Wed, Jun 23, 2010 at 11:12 PM, Anthony Liguori > > > wrote: > >

Re: [RFC] virtio: Support releasing lock during kick

2010-06-25 Thread Stefan Hajnoczi
On Fri, Jun 25, 2010 at 06:32:20PM +0300, Michael S. Tsirkin wrote: > On Fri, Jun 25, 2010 at 04:31:44PM +0100, Stefan Hajnoczi wrote: > > On Fri, Jun 25, 2010 at 01:43:17PM +0300, Michael S. Tsirkin wrote: > > > On Fri, Jun 25, 2010 at 12:39:21PM +0930, Rusty Russell wrote: >

Re: [RFC] virtio: Support releasing lock during kick

2010-06-29 Thread Stefan Hajnoczi
On Mon, Jun 28, 2010 at 4:55 PM, Marcelo Tosatti wrote: > On Wed, Jun 23, 2010 at 10:24:02PM +0100, Stefan Hajnoczi wrote: >> The virtio block device holds a lock during I/O request processing. >> Kicking the virtqueue while the lock is held results in long lock hold >>

Re: VHOST_NET_SET_BACKEND

2010-10-06 Thread Stefan Hajnoczi
On Wed, Oct 6, 2010 at 7:43 AM, devi thapa wrote: >       I dont know how to put this question, but bear with me.   My > query is how to invoke the ioctl request "VHOST_NET_SET_BACKEND"  or > how to set the backend, and when ? Look at the QEMU side vhost-net code: http://git.qemu.org/qemu.git/tre

Re: vhost_net_ioctl

2010-10-06 Thread Stefan Hajnoczi
On Wed, Oct 6, 2010 at 11:16 AM, devi thapa wrote: >           What's the role or value of the third argument in the > vhost_net_ioctl function in /drivers/vhost/net.c . Read the code. There is the kernel vhost code and the QEMU vhost userspace code to look at. By studying both sides you can fi

Re: vhost_net_ioctl

2010-10-06 Thread Stefan Hajnoczi
On Wed, Oct 6, 2010 at 12:34 PM, devi thapa wrote: > I am actually going only through net.c  and in this module they > haven't specified anywhere, where this value is coming from. In order to understand net.c it will be necessary to read other code too. Make sure you have an environment that mak

Re: transport between guest and host

2010-11-25 Thread Stefan Hajnoczi
On Thu, Nov 25, 2010 at 11:37 AM, devi thapa wrote: >          I have 2 queries. > 1.  Is virtio-serial or virtio-console data transfer kernel level and > efficient than vhostnet networking. > 2.  Is 9p efficient for communicating between guests and a host > using a virtio based transport.  Is thi

Re: transport between guest and host

2010-11-25 Thread Stefan Hajnoczi
On Thu, Nov 25, 2010 at 4:43 PM, devi thapa wrote: >      I want to transport modules from host and insert in guest and > transport the result back to host. Linux kernel modules? If you describe the problem you're trying to solve in more detail you'll get more helpful feedback. Stefan _

Re: [Qemu-devel] SCSI Command support over VirtIO Block device

2010-12-12 Thread Stefan Hajnoczi
On Dec 13, 2010 5:14 AM, "अनुज" wrote: > > Hi > > I am trying to implement VirtIO support for a proprietary OS. And It > would be great if I am able to process SCSI commands over VirtIO Block > device. > > I tried to execute INQUIRY command but the status returned is UNSUPPORTED. > If anyone provi

Re: virtio-blk.c handling of i/o which is not a 512 multiple

2011-03-30 Thread Stefan Hajnoczi
On Wed, Mar 30, 2011 at 9:15 AM, Conor Murphy wrote: > I'm trying to write a virtio-blk driver for Solaris. I've gotten it to the > point > where Solaris can see the device and create a ZFS file system on it. > > However when I try and create a UFS filesystem on the device, the VM crashed > with

Re: [PATCH] virtio: decrement dev_index when device is unregistered

2011-04-04 Thread Stefan Hajnoczi
On Tue, Apr 5, 2011 at 5:49 AM, Takuma Umeya wrote: > When virtio device is removed, dev_index does not get decremented. > The next device hotplug event results in consuming the next pci to > the one that is suppose to be available. > > Signed-off-by: Takuma Umeya > > diff --git a/drivers/virtio/

Re: [PATCH] virtio: decrement dev_index when device is unregistered

2011-04-12 Thread Stefan Hajnoczi
On Mon, Apr 11, 2011 at 10:11 AM, Takuma Umeya wrote: > - Original Message - >> On Tue, Apr 5, 2011 at 5:49 AM, Takuma Umeya >> wrote: >> > When virtio device is removed, dev_index does not get decremented. >> > The next device hotplug event results in consuming the next pci to >> > the o

Re: [PATCH 07/18] virtio ring: inline function to check for events

2011-05-05 Thread Stefan Hajnoczi
On Wed, May 4, 2011 at 9:51 PM, Michael S. Tsirkin wrote: > With the new used_event and avail_event and features, both > host and guest need similar logic to check whether events are > enabled, so it helps to put the common code in the header. > > Note that Xen has similar logic for notification h

Re: virtio scsi host draft specification, v3

2011-06-10 Thread Stefan Hajnoczi
On Fri, Jun 10, 2011 at 12:33 PM, Rusty Russell wrote: > On Thu, 09 Jun 2011 08:59:27 +0200, Paolo Bonzini wrote: >> On 06/09/2011 01:28 AM, Rusty Russell wrote: >> >> >  after some preliminary discussion on the QEMU mailing list, I present a >> >> >  draft specification for a virtio-based SCSI h

Re: virtio scsi host draft specification, v3

2011-06-14 Thread Stefan Hajnoczi
On Tue, Jun 14, 2011 at 9:39 AM, Hannes Reinecke wrote: > On 06/10/2011 04:35 PM, Paolo Bonzini wrote: >>> >>> If requests are placed on arbitrary queues you'll inevitably run on >>> locking issues to ensure strict request ordering. >>> I would add here: >>> >>> If a device uses more than one queu

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 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 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: [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 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 ser

<    1   2   3   4   5   6   7   8   9   >