Skip to contentSkip to conversation

include/block.h: remove outdated comment in bdrv_drained_begin

PATCH Superseded Emanuele Giuseppe Esposito 2 participants 2 messages Aug 16, 2021 – Aug 17, 2021

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 include/block.h: remove outdated comment in bdrv_drained_begin

There are a couple of errors in bdrv_drained_begin header comment:
- block_job_pause does not exist anymore, it has been replaced with job_pause in b15de82867
- job_pause is automatically invoked as a .drained_begin callback (child_job_drained_begin) by the child_job BdrvChildClass struct in blockjob.c. So no additional pause should be required.

---
 include/block/block.h | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
include/block/block.h +1 -3
index 3477290f9a..1b0d05b545 100644
@@ -749,9 +749,7 @@ bool bdrv_drain_poll(BlockDriverState *bs, bool recursive,
  * bdrv_drained_begin:
  *
  * Begin a quiesced section for exclusive access to the BDS, by disabling
- * external request sources including NBD server and device model. Note that
- * this doesn't block timers or coroutines from submitting more requests, which
- * means block_job_pause is still necessary.
+ * external request sources including NBD server and device model.
  *
  * This function can be recursive.
  */
Signature · 1 line
2.31.1
#1 lore raw
Quoted 17 lines · Emanuele Giuseppe Esposito

There are a couple of errors in bdrv_drained_begin header comment:
- block_job_pause does not exist anymore, it has been replaced with job_pause in b15de82867
- job_pause is automatically invoked as a .drained_begin callback (child_job_drained_begin) by the child_job BdrvChildClass struct in blockjob.c. So no additional pause should be required.

---
 include/block/block.h | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
include/block/block.h +0 -0
index 3477290f9a..1b0d05b545 100644

include/block/block.h bool bdrv_drain_poll(BlockDriverState *bs, bool recursive, · line 752

Quoted 7 lines
include/block/block.h +1 -3
@@ -749,9 +749,7 @@ bool bdrv_drain_poll(BlockDriverState *bs, bool recursive,
  * bdrv_drained_begin:
  *
  * Begin a quiesced section for exclusive access to the BDS, by disabling
- * external request sources including NBD server and device model. Note that
- * this doesn't block timers or coroutines from submitting more requests, which
- * means block_job_pause is still necessary.
+ * external request sources including NBD server and device model.

Block jobs are worth mentioning:
"NBD server, block jobs, and device model"?