search for: is_processing_group

Displaying 6 results from an estimated 6 matches for "is_processing_group".

2019 Jun 05
0
[PATCH libnbd 1/4] lib: Move nbd_aio_is_* function impls to separate source file.
...nbd_handle *h) -{ - enum state_group group = nbd_internal_state_group (h->state); - - return is_connecting_group (group); -} - -/* NB: is_locked = false, may_set_error = false. */ -int -nbd_unlocked_aio_is_ready (struct nbd_handle *h) -{ - return h->state == STATE_READY; -} - -static int -is_processing_group (enum state_group group) -{ - switch (group) { - case GROUP_TOP: - return 0; - case GROUP_ISSUE_COMMAND: - case GROUP_REPLY: - return 1; - default: - return is_processing_group (nbd_internal_state_group_parent (group)); - } -} - -/* NB: is_locked = false, may_set_error = false. */ -i...
2019 May 30
3
[PATCH libnbd 0/2] Avoid lock and error overhead on some calls.
This works. I'm in the middle of testing whether there is any noticable benefit. Rich.
2019 Jun 05
9
[PATCH libnbd 0/4] lib: Atomically update h->state.
I need to think about this patch series a bit more, but it does at least pass the tests. Rich.
2019 Jun 05
0
[PATCH libnbd 2/4] lib: Split nbd_aio_is_* functions into internal.
...necting_group (group); } -/* NB: is_locked = false, may_set_error = false. */ -int -nbd_unlocked_aio_is_ready (struct nbd_handle *h) +bool +nbd_internal_is_state_ready (enum state state) { - return h->state == STATE_READY; + return state == STATE_READY; } static int @@ -81,25 +80,64 @@ is_processing_group (enum state_group group) } } -/* NB: is_locked = false, may_set_error = false. */ -int -nbd_unlocked_aio_is_processing (struct nbd_handle *h) +bool +nbd_internal_is_state_processing (enum state state) { - enum state_group group = nbd_internal_state_group (h->state); + enum state_group g...
2019 May 22
8
[PATCH libnbd v2 0/6] Test connection states.
Patch 1/6 was posted before and I didn't change it: https://www.redhat.com/archives/libguestfs/2019-May/thread.html#00134 That doesn't necessarily mean I shouldn't change it, I'm posting it again because the other patches depend on it. The main change in this series is we add three new API functions: nbd_aio_is_created - connection has just been created
2019 May 23
2
[PATCH libnbd] api: Get rid of nbd_connection.
This isn't quite finished because not all of the tests or examples have been updated, but it demonstrates an idea: Should we forget about the concept of having multiple connections managed under a single handle? In this patch there is a single ‘struct nbd_handle *’ which manages a single state machine and connection (and therefore no nbd_connection). To connect to a multi-conn server you must