Re: [PATCH v2 3/3] migration/colo: Tidy up bql_unlock() around bdrv_activate_all()
16.05.2024 06:45, Li Zhijian wrote: Make the code more tight. Suggested-by: Michael Tokarev Reviewed-by: Peter Xu Reviewed-by: Zhang Chen Signed-off-by: Li Zhijian Signed-off-by: Michael Tokarev /mjt --- V2: Collected reviewed-by tags This change/comment suggested by "Michael Tokarev " came a bit late at that time, let's update it together in these minor set this time. --- migration/colo.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/migration/colo.c b/migration/colo.c index 991806c06a..1b6d9da1c8 100644 --- a/migration/colo.c +++ b/migration/colo.c @@ -838,12 +838,11 @@ static void *colo_process_incoming_thread(void *opaque) /* Make sure all file formats throw away their mutable metadata */ bql_lock(); bdrv_activate_all(&local_err); +bql_unlock(); if (local_err) { -bql_unlock(); error_report_err(local_err); return NULL; } -bql_unlock(); failover_init_state();
[PATCH v2 3/3] migration/colo: Tidy up bql_unlock() around bdrv_activate_all()
Make the code more tight. Suggested-by: Michael Tokarev Reviewed-by: Peter Xu Reviewed-by: Zhang Chen Signed-off-by: Li Zhijian --- V2: Collected reviewed-by tags This change/comment suggested by "Michael Tokarev " came a bit late at that time, let's update it together in these minor set this time. --- migration/colo.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/migration/colo.c b/migration/colo.c index 991806c06a..1b6d9da1c8 100644 --- a/migration/colo.c +++ b/migration/colo.c @@ -838,12 +838,11 @@ static void *colo_process_incoming_thread(void *opaque) /* Make sure all file formats throw away their mutable metadata */ bql_lock(); bdrv_activate_all(&local_err); +bql_unlock(); if (local_err) { -bql_unlock(); error_report_err(local_err); return NULL; } -bql_unlock(); failover_init_state(); -- 2.31.1