mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-26 12:12:13 +03:00
txg: generalise txg_wait_synced_sig() to txg_wait_synced_flags() (#17284)
txg_wait_synced_sig() is "wait for txg, unless a signal arrives". We expect that future development will require similar "wait unless X" behaviour. This generalises the API as txg_wait_synced_flags(), where the provided flags describe the events that should cause the call to return. Instead of a boolean, the return is now an error code, which the caller can use to know which event caused the call to return. The existing call to txg_wait_synced_sig() is now txg_wait_synced_flags(TXG_WAIT_SIGNAL). Sponsored-by: Klara, Inc. Sponsored-by: Wasabi Technology, Inc. Signed-off-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Allan Jude <allan@klarasystems.com> Reviewed-by: Alexander Motin <mav@FreeBSD.org>
This commit is contained in:
+2
-2
@@ -970,8 +970,8 @@ zcp_pool_error(zcp_run_info_t *ri, const char *poolname, int error)
|
||||
}
|
||||
|
||||
/*
|
||||
* This callback is called when txg_wait_synced_sig encountered a signal.
|
||||
* The txg_wait_synced_sig will continue to wait for the txg to complete
|
||||
* This callback is called when txg_wait_synced_flags encountered a signal.
|
||||
* The txg_wait_synced_flags will continue to wait for the txg to complete
|
||||
* after calling this callback.
|
||||
*/
|
||||
static void
|
||||
|
||||
Reference in New Issue
Block a user