Displaying 3 results from an estimated 3 matches for "notify_fn".
Did you mean:
inotify_fd
2019 Jun 29
0
[libnbd PATCH 5/6] api: Add new nbd_aio_FOO_notify functions
..._unlocked_aio_pread_notify (h, buf, count, offset, NULL, NULL,
+ flags);
+}
+
+int64_t
+nbd_unlocked_aio_pread_notify (struct nbd_handle *h, void *buf,
+ size_t count, uint64_t offset,
+ void *opaque, notify_fn notify, uint32_t flags)
+{
+ struct command_cb cb = { .opaque = opaque, .notify = notify, };
+
/* We could silently accept flag DF, but it really only makes sense
* with callbacks, because otherwise there is no observable change
* except that the server may fail where it would otherwise...
2019 Jun 29
0
[libnbd PATCH 4/6] states: Prepare for aio notify callback
...int (*extent_fn) (void *data, const char *metacontext, uint64_t offset,
uint32_t *entries, size_t nr_entries, int *error);
typedef int (*read_fn) (void *data, const void *buf, size_t count,
uint64_t offset, int *error, int status);
+typedef int (*notify_fn) (void *data, int64_t handle, int *error);
struct command_cb {
void *opaque;
@@ -246,6 +247,7 @@ struct command_cb {
extent_fn extent;
read_fn read;
} fn;
+ notify_fn notify;
};
struct command_in_flight {
diff --git a/tests/server-death.c b/tests/server-death.c
index d490753.....
2019 Jun 29
19
[libnbd PATCH 0/6] new APIs: aio_in_flight, aio_FOO_notify
I still need to wire in the use of *_notify functions into nbdkit to
prove whether it makes the code any faster or easier to maintain, but
at least the added example shows one good use case for the new API.
Eric Blake (6):
api: Add nbd_aio_in_flight
generator: Allow DEAD state actions to run
generator: Allow Int64 in callbacks
states: Prepare for aio notify callback
api: Add new