search for: coroutine_fn

Displaying 7 results from an estimated 7 matches for "coroutine_fn".

2019 Mar 23
4
nbdkit & qemu 2.12: qemu-img: Protocol error: simple reply when structured reply chunk was expected
nbdkit (upstream 5a7a394c699) currently fails with qemu 2.12.0: $ ./nbdkit memory size=64M --run 'qemu-img convert $nbd /var/tmp/out' nbdkit: memory.2: error: invalid request: unknown command (7) ignored qemu-img: Protocol error: simple reply when structured reply chunk was expected This was a bug in qemu which was fixed upstream quite a long time ago by the commit I've
2023 Mar 24
1
[PATCH 1/1] nbd/server: push pending frames after sending reply
...f-by: Florian Westphal <fw at strlen.de> > --- > nbd/server.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/nbd/server.c b/nbd/server.c > index a4750e41880a..848836d41405 100644 > --- a/nbd/server.c > +++ b/nbd/server.c > @@ -2667,6 +2667,8 @@ static coroutine_fn void nbd_trip(void *opaque) > goto disconnect; > } > > + qio_channel_set_cork(client->ioc, true); > + > if (ret < 0) { > /* It wasn't -EIO, so, according to nbd_co_receive_request() > * semantics, we should return the erro...
2019 Jun 21
0
[libnbd PATCH v2 3/5] states: Add nbd_pread_structured API
...IBNBD_READ_ERROR difficult. I used the following hack on top of qemu.git commit d1bf88e5 to trigger an offset error for local testing: | diff --git i/nbd/server.c w/nbd/server.c | index 10faedcfc55d..804dced0bc8d 100644 | --- i/nbd/server.c | +++ w/nbd/server.c | @@ -1838,12 +1838,30 @@ static int coroutine_fn nbd_co_send_sparse_read(NBDClient *client, | | trace_nbd_co_send_structured_read_hole(handle, offset + progress, | pnum); | - set_be_chunk(&chunk.h, final ? NBD_REPLY_FLAG_DONE : 0, | + set_be_chunk(&chun...
2019 Jun 18
0
[libnbd PATCH 6/8] states: Add nbd_pread_callback API
...IBNBD_READ_ERROR difficult. I used the following hack on top of qemu.git commit d1bf88e5 to trigger an offset error for local testing: | diff --git i/nbd/server.c w/nbd/server.c | index 10faedcfc55d..804dced0bc8d 100644 | --- i/nbd/server.c | +++ w/nbd/server.c | @@ -1838,12 +1838,30 @@ static int coroutine_fn nbd_co_send_sparse_read(NBDClient *client, | | trace_nbd_co_send_structured_read_hole(handle, offset + progress, | pnum); | - set_be_chunk(&chunk.h, final ? NBD_REPLY_FLAG_DONE : 0, | + set_be_chunk(&chun...
2019 Aug 23
22
cross-project patches: Add NBD Fast Zero support
This is a cover letter to a series of patches being proposed in tandem to four different projects: - nbd: Document a new NBD_CMD_FLAG_FAST_ZERO command flag - qemu: Implement the flag for both clients and server - libnbd: Implement the flag for clients - nbdkit: Implement the flag for servers, including the nbd passthrough client If you want to test the patches together, I've pushed a
2019 Jun 21
9
[libnbd PATCH v2 0/5] nbd_pread_structured
Since v1: - rebase to applied patches - split out support for Int in callbacks - sort of test that callbacks work in OCaml (see comment in patch 5) - rename API to nbd_pread_structured - expose error as explicit parameter to callback Eric Blake (5): generator: Allow Int in callbacks states: Wire in a read callback states: Add nbd_pread_structured API states: Add tests for
2019 Jun 18
17
[libnbd PATCH 0/8] Add nbd_pread_callback
I've mentioned this topic before (in fact, the idea of adding NBD_CMD_FLAG_DF was first mentioned at [1]), but finally finished enough of an implementation to feel confident in posting it. I'd still like to add something under examples/ that uses the new API to implement strict checking of a server's structured replies read implementation (ensure that a server never sends data after