search for: test_ocaml_plugin

Displaying 20 results from an estimated 21 matches for "test_ocaml_plugin".

2018 Nov 29
1
[nbdkit PATCH] ocaml: Make build VPATH aware
...hat you have to diff --git a/tests/Makefile.am b/tests/Makefile.am index 4e16fa9..94f3d43 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -517,7 +517,9 @@ test_ocaml_CFLAGS = \ test_ocaml_LDADD = libtest.la $(LIBGUESTFS_LIBS) check_SCRIPTS += test-ocaml-plugin.so -test-ocaml-plugin.so: test_ocaml_plugin.ml ../plugins/ocaml/libnbdkitocaml.la ../plugins/ocaml/NBDKit.cmi ../plugins/ocaml/NBDKit.cmx +test_ocaml_plugin.cmx: test_ocaml_plugin.ml + $(OCAMLOPT) $(OCAMLOPTFLAGS) -I ../plugins/ocaml -c $< -o $@ +test-ocaml-plugin.so: test_ocaml_plugin.cmx ../plugins/ocaml/libnbdkitocaml.la ../plugins/oca...
2018 Dec 13
2
[nbdkit PATCH] maint: Adjust cleaning rules
...LDADD = libtest.la $(LIBGUESTFS_LIBS) # split files plugin test. check_DATA += split1 split2 split3 -MAINTAINERCLEANFILES += split1 split2 split3 +CLEANFILES += split1 split2 split3 split1: file-data rm -f $@ $@-t dd if=$< of=$@-t bs=1 count=100 @@ -528,6 +530,10 @@ test-ocaml-plugin.so: test_ocaml_plugin.cmx ../plugins/ocaml/libnbdkitocaml.la . -output-obj -runtime-variant _pic -o $@ \ NBDKit.cmx $< \ -cclib -L../plugins/ocaml/.libs -cclib -lnbdkitocaml +CLEANFILES += \ + test_ocaml_plugin.cmx \ + test_ocaml_plugin.cmi \ + test-ocaml-plugin.so endif HAVE_OCAML @@ -585,7 +591,7 @@...
2019 Apr 23
0
[PATCH nbdkit v2 1/2] ocaml: Change pread method to avoid leaking heap memory.
...: 'a -> bytes -> int64 -> flags -> unit + pread : 'a -> int32 -> int64 -> flags -> string Credit: Eric Blake for finding the bug. --- plugins/ocaml/ocaml.c | 16 ++++++++++++---- plugins/ocaml/NBDKit.ml | 4 ++-- plugins/ocaml/NBDKit.mli | 2 +- tests/test_ocaml_plugin.ml | 8 +++++--- 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/plugins/ocaml/ocaml.c b/plugins/ocaml/ocaml.c index d854f48..39704e2 100644 --- a/plugins/ocaml/ocaml.c +++ b/plugins/ocaml/ocaml.c @@ -439,15 +439,16 @@ pread_wrapper (void *h, void *buf, uint32_t count, uint64_t of...
2019 Aug 15
2
[nbdkit PATCH] ocaml: Add support for dynamic .thread_model
...bdkit-ocaml-plugin.pod | 13 ++++++----- plugins/ocaml/ocaml.c | 33 +++++++++++++++++++++------ plugins/ocaml/NBDKit.ml | 28 ++++++++++++++--------- plugins/ocaml/NBDKit.mli | 19 ++++++++------- plugins/ocaml/example.ml | 9 +++++--- tests/test_ocaml_plugin.ml | 5 ++-- 6 files changed, 69 insertions(+), 38 deletions(-) diff --git a/plugins/ocaml/nbdkit-ocaml-plugin.pod b/plugins/ocaml/nbdkit-ocaml-plugin.pod index a66cf26e..4b349612 100644 --- a/plugins/ocaml/nbdkit-ocaml-plugin.pod +++ b/plugins/ocaml/nbdkit-ocaml-plugin.pod @@ -36,12 +...
2019 Apr 23
4
[PATCH nbdkit v2 0/2] Be careful not to leak server heap memory to the client.
Version 1 was here: https://www.redhat.com/archives/libguestfs/2019-April/msg00144.html Version 2 makes a couple of much larger changes: The OCaml patch changes the API of the pread method so it matches what other language bindings are already doing, ie. get the language plugin to return a newly allocated buffer, check it is long enough, copy out the data. The server patch implements a
2018 Dec 13
0
Re: [nbdkit PATCH] maint: Adjust cleaning rules
...le.am > +++ b/tests/Makefile.am > @@ -32,7 +32,8 @@ > > include $(top_srcdir)/common-rules.mk > > -MAINTAINERCLEANFILES = > +CLEANFILES = Because common-rules.mk defines CLEANFILES, this should be giving a warning. And also because of that ... > +CLEANFILES += \ > + test_ocaml_plugin.cmx \ > + test_ocaml_plugin.cmi \ > + test-ocaml-plugin.so ... this should not be necessary because the CLEANFILES rule in common-rules.mk cleans these files already. If that is fixed, ACK. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my pro...
2019 Apr 23
2
Re: [PATCH nbdkit v2 1/2] ocaml: Change pread method to avoid leaking heap memory.
...change (all older OCaml plugins will fail to build/run with the newer nbdkit), but we never promised compatibility for language bindings. > --- > plugins/ocaml/ocaml.c | 16 ++++++++++++---- > plugins/ocaml/NBDKit.ml | 4 ++-- > plugins/ocaml/NBDKit.mli | 2 +- > tests/test_ocaml_plugin.ml | 8 +++++--- > 4 files changed, 20 insertions(+), 10 deletions(-) I wondered if nbdkit-ocaml-plugin.pod also needed a change, but it calls out NBDKit.mli as the official interface and you patched that instead. LGTM. -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-9...
2020 Feb 25
6
[PATCH nbdkit 0/5] server: Add .get_ready callback.
I like this change. I think we were overloading the config_complete method before to do two different things (complete configuration; do any allocation/housekeeping necessary before we can start serving). The only questions in my mind are whether we want this before 1.18, and whether the name ("get_ready") is a good one. Rich.
2018 Jan 26
1
[PATCH nbdkit] tests: Rename and rework test-ipv4.sh so it tests IPv6
I wanted to change this test so it tries connections on both IPv4 & IPv6. Having it connect on both is the easy bit. Harder was making it not fail on machines that don't have IPv6 stack (or IPv4 in some rare cases). TBH I wasn't able to test this, but it seems like this should work. In the end we want to modify nbdkit so it can listen on only certain interfaces, but that's a
2018 Mar 06
0
[PATCH nbdkit 2/2] tests: Rename and rework test-ipv4.sh so it tests IPv6 connections too.
...ged, 40 insertions(+), 17 deletions(-) diff --git a/tests/Makefile.am b/tests/Makefile.am index 89ceb9d..9be57e6 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -50,7 +50,7 @@ EXTRA_DIST = \ test-foreground.sh \ test-help.sh \ test-help-plugin.sh \ - test-ipv4.sh \ + test-ip.sh \ test_ocaml_plugin.ml \ test-ocaml.c \ test-parallel-file.sh \ @@ -104,7 +104,7 @@ TESTS += \ test-captive.sh \ test-random-sock.sh \ test-tls.sh \ - test-ipv4.sh \ + test-ip.sh \ test-socket-activation \ test-foreground.sh diff --git a/tests/test-ipv4.sh b/tests/test-ip.sh similarity index 64% rename...
2019 Apr 25
0
[nbdkit PATCH v2 5/5] nbd: Test .extents
...it a/tests/Makefile.am b/tests/Makefile.am index 08bdf85..4b7aa22 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -79,6 +79,7 @@ EXTRA_DIST = \ test.lua \ test-memory-largest.sh \ test-memory-largest-for-qemu.sh \ + test-nbd-extents.sh \ test-nozero.sh \ test-null-extents.sh \ test_ocaml_plugin.ml \ @@ -530,6 +531,8 @@ TESTS += \ # nbd plugin test. LIBGUESTFS_TESTS += test-nbd +TESTS += \ + test-nbd-extents.sh test_nbd_SOURCES = test-nbd.c test.h test_nbd_CFLAGS = $(WARNINGS_CFLAGS) $(LIBGUESTFS_CFLAGS) diff --git a/tests/test-nbd-extents.sh b/tests/test-nbd-extents.sh new file mode...
2018 Jan 27
1
[PATCH nbdkit v2] tests: Rename and rework test-ipv4.sh so it tests
This is my second go at reworking the ‘test-ipv4.sh’ test. Instead of merely connecting to the server using socat, use ‘qemu-img info’ so that the test is slightly more realistic. Also clean up old PID and log files before starting the test. Previous version was posted here: https://www.redhat.com/archives/libguestfs/2018-January/msg00253.html Rich.
2018 Mar 06
4
[PATCH nbdkit 0/2] tests: Minor reworking of tests.
Small reworking of tests to remove $QEMU_IO, making that consistent with other test tools, and to test IPv6 connections.
2017 Nov 20
10
[nbdkit PATCH v2 0/8] Support parallel transactions within single connection
I've posted some of these patches or ideas before; but now I'm confident enough with the series that it should be ready to push; at any rate, I can now run test-socket-activation in a tight loop without triggering any crashes or hangs. With this in place, I'm going back to work on making the nbd forwarder wort with the parallel thread model. Eric Blake (8): sockets: Use
2019 Dec 12
9
[PATCH nbdkit 0/7] server: Allow datapath debug messages to be suppressed.
The immediate reason for this patch is to reduce the amount of debugging in virt-v2v with using the virt-v2v -v option (because this implies running nbdkit in verbose mode too). Most of the messages are datapath ones about pread/pwrite requests, and in fact as we've added more filters on top of nbdkit these messages have got more and more verbose. However they are not particularly
2019 Apr 25
6
[nbdkit PATCH v2 0/5] structured replies/.extents for nbd plugin
Updated based on other changes that have happened in the meantime: - rely more on cleanup.h (throughout) - split structured read for easier review (patch 2 and 3 were combined in v1) - rely on nbdkit not leaking a server's partial answer (patch 3) - add tests (patch 5) - other bug fixes I found while testing it - drop EOVERFLOW patch for now; it will be separate once upstream NBD protocol
2018 Jul 31
0
[PATCH nbdkit 3/4] Add map filter.
...-filter(1)>, L<nbdkit-random-plugin(1)>, diff --git a/tests/Makefile.am b/tests/Makefile.am index 4c602d7..2306506 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -58,6 +58,7 @@ EXTRA_DIST = \ test-ip.sh \ test-log.sh \ test.lua \ + test-map-empty.sh \ test-nozero.sh \ test_ocaml_plugin.ml \ test-ocaml.c \ @@ -547,6 +548,9 @@ TESTS += test-fua.sh # log filter test. TESTS += test-log.sh +# map filter test. +TESTS += test-map-empty.sh + # nozero filter test. TESTS += test-nozero.sh diff --git a/tests/test-map-empty.sh b/tests/test-map-empty.sh new file mode 100755 index 00...
2018 Jul 31
7
[PATCH nbdkit 0/4] Add truncate and map filters.
This patch series proposes two new filters. * truncate: This can truncate, extend, round up or round down the size of a plugin/device. A typical usage is to fix the qemu problem that it can only handle devices which are a multiple of 512-bytes: nbdkit --filter=truncate random size=500 round-up=512 This will serve a virtual device with size 512 bytes. Reading from the last 12 bytes will
2018 Mar 08
19
[nbdkit PATCH v3 00/15] Add FUA support to nbdkit
After more than a month since v2 [1], I've finally got my FUA support series polished. This is all of my outstanding patches, even though some of them were originally posted in separate threads from the original FUA post [2], [3] [1] https://www.redhat.com/archives/libguestfs/2018-January/msg00113.html [2] https://www.redhat.com/archives/libguestfs/2018-January/msg00219.html [3]
2019 Mar 28
32
[PATCH nbdkit v5 FINAL 00/19] Implement extents.
This has already been pushed upstream. I am simply posting these here so we have a reference in the mailing list in case we find bugs later (as I'm sure we will - it's a complex patch series). Great thanks to Eric Blake for tireless review on this one. It also seems to have identified a few minor bugs in qemu along the way. Rich.