From: Bart Van Assche <bvanassche@acm.org>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-block@vger.kernel.org, Christoph Hellwig <hch@lst.de>,
Damien Le Moal <dlemoal@kernel.org>,
Bart Van Assche <bvanassche@acm.org>
Subject: [PATCH v2 3/4] blk-zoned: Improve the queue reference count strategy documentation
Date: Tue, 17 Dec 2024 13:03:09 -0800 [thread overview]
Message-ID: <20241217210310.645966-4-bvanassche@acm.org> (raw)
In-Reply-To: <20241217210310.645966-1-bvanassche@acm.org>
For the blk_queue_exit() calls, document where the corresponding code can
be found that increases q->q_usage_counter.
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
block/blk-zoned.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/block/blk-zoned.c b/block/blk-zoned.c
index 954724a2e3c6..7876a6458022 100644
--- a/block/blk-zoned.c
+++ b/block/blk-zoned.c
@@ -582,6 +582,7 @@ static inline void blk_zone_wplug_bio_io_error(struct blk_zone_wplug *zwplug,
bio_clear_flag(bio, BIO_ZONE_WRITE_PLUGGING);
bio_io_error(bio);
disk_put_zone_wplug(zwplug);
+ /* Drop the reference taken by disk_zone_wplug_add_bio(() */
blk_queue_exit(q);
}
@@ -893,10 +894,7 @@ void blk_zone_write_plug_init_request(struct request *req)
break;
}
- /*
- * Drop the extra reference on the queue usage we got when
- * plugging the BIO and advance the write pointer offset.
- */
+ /* Drop the reference taken by disk_zone_wplug_add_bio(). */
blk_queue_exit(q);
zwplug->wp_offset += bio_sectors(bio);
next prev parent reply other threads:[~2024-12-17 21:03 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-17 21:03 [PATCH v2 0/4] Minor improvements for the zoned block storage code Bart Van Assche
2024-12-17 21:03 ` [PATCH v2 1/4] blk-zoned: Minimize #include directives Bart Van Assche
2024-12-17 21:03 ` [PATCH v2 2/4] blk-zoned: Document locking assumptions Bart Van Assche
2024-12-17 21:03 ` Bart Van Assche [this message]
2024-12-17 21:03 ` [PATCH v2 4/4] blk-zoned: Split queue_zone_wplugs_show() Bart Van Assche
2024-12-20 18:18 ` [PATCH v2 0/4] Minor improvements for the zoned block storage code Bart Van Assche
2024-12-21 16:47 ` Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241217210310.645966-4-bvanassche@acm.org \
--to=bvanassche@acm.org \
--cc=axboe@kernel.dk \
--cc=dlemoal@kernel.org \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.