From: Bart Van Assche <bvanassche@acm.org>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: Jens Axboe <axboe@kernel.dk>,
linux-block@vger.kernel.org, Christoph Hellwig <hch@lst.de>,
Damien Le Moal <dlemoal@kernel.org>,
Alasdair Kergon <agk@redhat.com>,
Mike Snitzer <snitzer@kernel.org>
Subject: Re: [PATCH v17 02/14] dm-linear: Report to the block layer that the write order is preserved
Date: Tue, 21 Jan 2025 13:38:51 -0800 [thread overview]
Message-ID: <785fd5c7-e0a2-47f7-a7b0-f10c24142dfa@acm.org> (raw)
In-Reply-To: <b0717657-8ecd-0fcf-4ca1-eb9f91ad01cf@redhat.com>
On 1/17/25 10:04 AM, Mikulas Patocka wrote:
> What if you have multiple linear targets in a table? Then, the write order
> would not be preserved.
If dm-linear is used on top of zoned storage, shouldn't each target
involve a whole number of zones? Doesn't this mean that dm-linear will
preserve the write order per zone?
> How is write pipelining supposed to work with suspend/resume? dm doesn't
> preserve the order of writes in case of suspend.
That's an interesting question. I expect that the following will happen
upon resume if zoned writes would have been reordered by dm-linear:
* The block device reports one or more unaligned write errors.
* For the zones for which an unaligned write error has been reported,
the flag BLK_ZONE_WPLUG_ERROR is set (see also patch 07/14 in this
series).
* Further zoned writes are postponed for the BLK_ZONE_WPLUG_ERROR zones
until all pending zoned writes have completed.
* Once all pending zoned writes have completed for a
BLK_ZONE_WPLUG_ERROR zone, these are resubmitted. This happens in LBA
order.
* The resubmitted writes will succeed unless the submitter (e.g. a
filesystem) left a gap between the zoned writes. If the submitter
does not follow the zoned block device specification, the zoned
writes will be retried until the number of retries has been exhausted.
Block devices are expected to set the number of retries to a small
positive number.
Thanks,
Bart.
next prev parent reply other threads:[~2025-01-21 21:38 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-15 22:46 [PATCH v17 00/14] Improve write performance for zoned UFS devices Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 01/14] block: Support block drivers that preserve the order of write requests Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 02/14] dm-linear: Report to the block layer that the write order is preserved Bart Van Assche
2025-01-17 18:04 ` Mikulas Patocka
2025-01-21 21:38 ` Bart Van Assche [this message]
2025-01-27 17:55 ` Mikulas Patocka
2025-01-15 22:46 ` [PATCH v17 03/14] block: Rework request allocation in blk_mq_submit_bio() Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 04/14] block: Support allocating from a specific software queue Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 05/14] blk-mq: Restore the zoned write order when requeuing Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 06/14] blk-zoned: Track the write pointer per zone Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 07/14] blk-zoned: Defer error handling Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 08/14] blk-zoned: Add an argument to blk_zone_plug_bio() Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 09/14] blk-zoned: Support pipelining of zoned writes Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 10/14] scsi: core: Retry unaligned " Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 11/14] scsi: sd: Increase retry count for " Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 12/14] scsi: scsi_debug: Add the preserves_write_order module parameter Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 13/14] scsi: scsi_debug: Support injecting unaligned write errors Bart Van Assche
2025-01-15 22:46 ` [PATCH v17 14/14] scsi: ufs: Inform the block layer about write ordering Bart Van Assche
2025-01-16 7:43 ` Can Guo
2025-01-16 15:58 ` Bao D. Nguyen
2025-01-23 0:52 ` Bart Van Assche
2025-01-17 22:47 ` [PATCH v17 00/14] Improve write performance for zoned UFS devices Damien Le Moal
2025-01-21 21:57 ` Bart Van Assche
2025-01-23 4:16 ` Damien Le Moal
2025-01-27 23:01 ` Bart Van Assche
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=785fd5c7-e0a2-47f7-a7b0-f10c24142dfa@acm.org \
--to=bvanassche@acm.org \
--cc=agk@redhat.com \
--cc=axboe@kernel.dk \
--cc=dlemoal@kernel.org \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
--cc=mpatocka@redhat.com \
--cc=snitzer@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox