uncate shared file");
}
} else if ((fd = shm_open(s->shmobj, O_CREAT|O_RDWR,
S_IRWXU|S_IRWXG|S_IRWXO)) < 0) {
-fprintf(stderr, "ivshmem: could not open shared file\n");
-exit(-1);
+error_report("could not open shared file");
+exit(1);
}
if (check_shm_size(s, fd) == -1) {
-exit(-1);
+exit(1);
}
create_shared_memory_BAR(s, fd);
Looks good to me (a comment on a dependency on Andreas patchset would
have been good).
Acked-by: David Marchand
--
David Marchand
ation that break things
(user mixing and matching incompatible software).
Ok, so how about keeping with this simple mechanism at the moment ?
If this versionning system is too limited in the future, I think we will
need a global rework on the protocol, anyway.
--
David Marchand
rties".
Fix this, by setting avail_connections to 1 in qemu_chr_open_eventfd().
Signed-off-by: David Marchand
---
qemu-char.c |7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
No change since initial patch: http://patchwork.ozlabs.org/patch/316785/
I just rebased this patch
rties".
Fix this, by setting avail_connections to 1 in qemu_chr_open_eventfd().
Signed-off-by: David Marchand
---
qemu-char.c |8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
Changes since v1
- fix coding style issue (missing braces)
--
David Marchand
diff --git a/qemu-cha
inside the guest.
Actually, you can avoid this memory copy using frameworks like DPDK.
Unless someone steps up and maintains ivshmem, I think it should be
deprecated and dropped from QEMU.
Then I can maintain ivshmem for QEMU.
If this is ok, I will send a patch for MAINTAINERS file.
--
David
to send a fix and I will review it.
Please also see the bug fixes in the following unapplied patch:
"[PATCH] ivshmem: fix potential OOB r/w access (#2)" by Sebastian Krahmer
https://lists.gnu.org/archive/html/qemu-devel/2014-04/msg03538.html
Thanks for the pointer. I'll check it.
--
David Marchand
s using regular networking APIs.
If you have access to source code, this should not be a problem.
--
David Marchand
ut ivshmem server, yes I will look at it.
I will see what I can propose or if importing nahanni implementation
as-is is the best solution.
Anyway, first, documentation.
--
David Marchand
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Signed-off-by: David Marchand
---
docs/specs/ivshmem_device_spec.txt | 41 ++--
1
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/Makefile | 26 ++
contrib/ivshmem-client
put them in contrib/ directory as the qemu-doc.texi was already telling the
server was supposed to be there.
--
David Marchand
David Marchand (2):
docs: update ivshmem device spec
contrib: add ivshmem client and server
contrib/ivshmem-client/Makefile | 26 ++
contrib/ivshmem-client
On 08/08/2014 04:51 PM, Stefan Hajnoczi wrote:
On Fri, Aug 08, 2014 at 10:55:17AM +0200, David Marchand wrote:
Looks good, a few minor comments:
diff --git a/contrib/ivshmem-client/Makefile b/contrib/ivshmem-client/Makefile
new file mode 100644
index 000..eee97c6
--- /dev/null
+++ b
const struct ivshmem_client_peer
*peer)
+{
+unsigned vector;
+int ret = 0;
+
+for (vector = 0; vector < peer->vectors_count; vector++) {
+if (ivshmem_client_notify(client, peer, vector) < 0) {
+ret = -1;
The ret's value will be covered when multi clients failed. Do we need
store the failed status for server?.
It indicates that we could not notify *all* clients.
Thanks Gonglei.
--
David Marchand
Hello Stefan,
On 08/08/2014 05:02 PM, Stefan Hajnoczi wrote:
On Fri, Aug 08, 2014 at 10:55:18AM +0200, David Marchand wrote:
+For each client (QEMU processes) that connects to the server:
+- the server assigns an ID for this client and sends this ID to him as the
first
+ message,
+- the
On 08/28/2014 11:49 AM, Stefan Hajnoczi wrote:
On Tue, Aug 26, 2014 at 01:04:30PM +0200, Paolo Bonzini wrote:
Il 26/08/2014 08:47, David Marchand ha scritto:
Using a version message supposes we want to keep ivshmem-server and QEMU
separated (for example, in two distribution packages) while we
orry, no
ASCII art here).
By the way, there are still some functionnalities that need description (use of
ioeventfd, the lack of irqfd support) and some parts of the ivshmem code clearly
need cleanup. I will try to address this in future patches when these first
patches are ok.
--
David
Fix coding style for structures.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 47 ++-
contrib/ivshmem-client/ivshmem-client.h | 76 +++
contrib/ivshmem-client/main.c | 21 -
contrib/ivshmem-server
Switch to qemu/queue.h strutures.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 17
contrib/ivshmem-client/ivshmem-client.h |7 ---
contrib/ivshmem-server/ivshmem-server.c | 33 ---
contrib/ivshmem-server
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some parts of the documentation and re-organise it.
Signed-off-by: David Marchand
Reviewed-by: Claudio Fontana
Signed-off-by: David Marchand
---
Makefile|8
configure |3 +++
contrib/ivshmem-client/Makefile | 29 -
contrib/ivshmem-server/Makefile | 29 -
4 files changed, 11
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: Olivier Matz
Signed-off-by: David Marchand
---
contrib/ivshmem-client/Makefile
Signed-off-by: David Marchand
---
contrib/ivshmem-server/ivshmem-server.c |3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/contrib/ivshmem-server/ivshmem-server.c
b/contrib/ivshmem-server/ivshmem-server.c
index 0afa6e8..e0d4d1d 100644
--- a/contrib/ivshmem-server/ivshmem
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c |9 ++---
contrib/ivshmem-server/ivshmem-server.c | 12 ++--
2 files changed, 4 insertions(+), 17 deletions(-)
diff --git a/contrib/ivshmem-client/ivshmem-client.c
b/contrib/ivshmem-client/ivshmem
Reuse parsers from QEMU, C99 boolean.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 12 +
contrib/ivshmem-client/ivshmem-client.h |4 +-
contrib/ivshmem-client/main.c | 12 +
contrib/ivshmem-server/ivshmem-server.c | 14 +-
contrib
More fixes following Gonglei comments:
- add a missing \n in a debug message.
- add an explicit initialisation of sock_fd.
- fix a check on vector index.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c |5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff
Signed-off-by: David Marchand
---
contrib/ivshmem-client/main.c |6 +++---
contrib/ivshmem-server/main.c |8
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/contrib/ivshmem-client/main.c b/contrib/ivshmem-client/main.c
index f8a7b66..a8e1586 100644
--- a/contrib
Signed-off-by: David Marchand
---
contrib/ivshmem-server/ivshmem-server.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/contrib/ivshmem-server/ivshmem-server.c
b/contrib/ivshmem-server/ivshmem-server.c
index 15d468c..4732dab 100644
--- a/contrib/ivshmem-server/ivshmem
Following Gonglei comments, rework error handling using goto.
Signed-off-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 17 -
contrib/ivshmem-server/ivshmem-server.c | 19 ++-
2 files changed, 18 insertions(+), 18 deletions(-)
diff --git a
ivshmem server should use the same default values as hw/misc/ivshmem.
Update accordingly.
Signed-off-by: David Marchand
---
contrib/ivshmem-server/main.c |4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/contrib/ivshmem-server/main.c b/contrib/ivshmem-server/main.c
ff-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 14 +++---
contrib/ivshmem-client/ivshmem-client.h |1 +
contrib/ivshmem-server/ivshmem-server.c |7 +
contrib/ivshmem-server/ivshmem-server.h |1 +
docs/specs/ivshmem_device_spec.txt |9 ---
hw
Hello Eric,
On 09/02/2014 10:31 PM, Eric Blake wrote:
On 09/02/2014 09:25 AM, David Marchand wrote:
Here is a patchset containing an update on ivshmem specs documentation and
importing ivshmem server and client tools.
These tools have been written from scratch and are not related to what is
tfd, the lack of irqfd support) and some parts of the ivshmem code clearly
need cleanup. I will try to address this in future patches when these first
patches are ok.
--
David Marchand
David Marchand (3):
contrib: add ivshmem client and server
docs: update ivshmem device spec
ivshmem: add c
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some parts of the documentation and re-organise it.
Signed-off-by: David Marchand
Reviewed-by: Claudio Fontana
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: Olivier Matz
Signed-off-by: David Marchand
---
Makefile
ff-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 14 +++---
contrib/ivshmem-client/ivshmem-client.h |1 +
contrib/ivshmem-server/ivshmem-server.c |7 +
contrib/ivshmem-server/ivshmem-server.h |1 +
docs/specs/ivshmem_device_spec.txt |9 ---
hw
thing acceptable ?
Do you have a better idea ?
Thanks.
--
David Marchand
Hello Stefan,
On 09/05/2014 12:29 PM, Stefan Hajnoczi wrote:
On Thu, Sep 04, 2014 at 02:51:01PM +0200, David Marchand wrote:
diff --git a/contrib/ivshmem-client/ivshmem-client.c
b/contrib/ivshmem-client/ivshmem-client.c
index ad210c8..0c4e016 100644
--- a/contrib/ivshmem-client/ivshmem
ff-by: David Marchand
---
contrib/ivshmem-client/ivshmem-client.c | 13 ++---
contrib/ivshmem-client/ivshmem-client.h |1 +
contrib/ivshmem-server/ivshmem-server.c |9 +
contrib/ivshmem-server/ivshmem-server.h |1 +
docs/specs/ivshmem_device_spec.txt |9 ++--
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: Olivier Matz
Signed-off-by: David Marchand
---
Makefile
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some parts of the documentation and re-organise it.
Signed-off-by: David Marchand
Reviewed-by: Claudio Fontana
se first
patches are ok.
--
David Marchand
David Marchand (3):
contrib: add ivshmem client and server
docs: update ivshmem device spec
ivshmem: add check on protocol version in QEMU
Makefile|8 +
configure |3 +
contri
try to address this in future patches when these first
patches are ok.
--
David Marchand
David Marchand (2):
contrib: add ivshmem client and server
docs: update ivshmem device spec
contrib/ivshmem-client/Makefile | 26 ++
contrib/ivshmem-client/ivshmem-client.c
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some parts of the documentation and re-organise it.
Signed-off-by: David Marchand
---
docs/specs
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: Olivier Matz
Signed-off-by: David Marchand
---
contrib/ivshmem-client/Makefile
Hello Eric,
On 07/21/2014 04:21 PM, Eric Blake wrote:
On 07/20/2014 03:38 AM, David Marchand wrote:
+# Copyright 2014 6WIND S.A.
+# All rights reserved
This file has no other license, and is therefore incompatible with
GPLv2. You'll need to resubmit under an appropriately open li
le in the top-level directory.
[...]
Back from holidays, sorry for the late response.
I will send a v3 for these issues.
--
David Marchand
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some parts of the documentation and re-organise it.
Signed-off-by: David Marchand
---
docs/specs
t need description (use of
ioeventfd, the lack of irqfd support) and some parts of the ivshmem code clearly
need cleanup. I will try to address this in future patches when these first
patches are ok.
--
David Marchand
David Marchand (2):
contrib: add ivshmem client and server
docs: update ivshmem
When using ivshmem devices, notifications between guests can be sent as
interrupts using a ivshmem-server (typical use described in documentation).
The client is provided as a debug tool.
Signed-off-by: Olivier Matz
Signed-off-by: David Marchand
---
contrib/ivshmem-client/Makefile
Hello Claudio,
On 08/08/2014 11:04 AM, Claudio Fontana wrote:
On 08.08.2014 10:55, David Marchand wrote:
Add some notes on the parts needed to use ivshmem devices: more specifically,
explain the purpose of an ivshmem server and the basic concept to use the
ivshmem devices in guests.
Move some
started by only specifying -S /path/to/ivshmem_socket.
We made comments into the source code, so I am not sure what could be
added. What do you miss ?
--
David Marchand
On 02/21/2014 05:10 PM, David Marchand wrote:
On Mon, Feb 17, 2014 at 12:52 PM, David Marchand
mailto:david.march...@6wind.com>> wrote:
Since this change has no impact, can it be pulled in current git tree ?
ping
http://patchwork.ozlabs.org/patch/316785/
ping
--
David Marchand
Hello,
Can someone take a look at my previous email and tell me if my patch is
just wrong ?
Thank you.
--
David Marchand
On Tue, Feb 4, 2014 at 10:17 PM, David Marchand wrote:
> Hello,
>
> First of all, this is a pure RFC patch, I did not take too much time to
> dig into
> q
eventfd(eventfd);
include/sysemu/char.h:CharDriverState *qemu_chr_open_eventfd(int eventfd);
qemu-char.c:CharDriverState *qemu_chr_open_eventfd(int eventfd)
I suppose my change is not that impacting :-)
Regards,
--
David Marchand
Hello all,
On Fri, Feb 14, 2014 at 1:16 PM, David Marchand wrote:
>
> In HEAD, ivshmem seems to be the only place where qemu_chr_open_eventfd()
> is used :
> $ git grep qemu_chr_open_eventfd
> hw/misc/ivshmem.c:chr = qemu_chr_open_eventfd(eventfd);
> include/sysemu/char
On Mon, Feb 17, 2014 at 12:52 PM, David Marchand
wrote:
>
> Since this change has no impact, can it be pulled in current git tree ?
>
>
ping
http://patchwork.ozlabs.org/patch/316785/
--
David Marchand
ns to 1 in qemu_chr_open_eventfd().
Signed-off-by: David Marchand
---
qemu-char.c |7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/qemu-char.c b/qemu-char.c
index 30c5a6a..c0adb04 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -2492,7 +2492,12 @@ static gboolean tcp_chr_read(
"optional" section is a good idea
too.
I will work on this at my return.
Anyway, thanks for the review.
--
David Marchand
On 06/23/2014 04:18 PM, Claudio Fontana wrote:
Hi,
we were reading through this quickly today, and these are some of the questions
that
we think can ca
58 matches
Mail list logo