public inbox for fio@vger.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <dlemoal@kernel.org>
To: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>,
	fio@vger.kernel.org, Jens Axboe <axboe@kernel.dk>,
	Vincent Fu <vincentfu@gmail.com>
Subject: Re: [PATCH v2 1/8] zbd: fix zone selection of random writes
Date: Fri, 27 Feb 2026 13:48:29 +0900	[thread overview]
Message-ID: <cfbd8963-228a-42ee-8cfa-f2cbd01a9991@kernel.org> (raw)
In-Reply-To: <20260216075936.3318729-2-shinichiro.kawasaki@wdc.com>

On 2/16/26 16:59, Shin'ichiro Kawasaki wrote:
> In zonemode=zbd, random write workloads targeting zoned block devices
> with max write zones limits such as max_open_zones can not do write
> operations to randomly chosen offset because of the zoned block device
> constraint of writing at write pointers. To adjust the offsets to valid
> positions, fio calls the function zbd_convert_to_write_zone(). This
> function checks the current write target zones as the next offset
> candidates but may fail depending on the conditions of those zones.
> In such cases, the function waits for zone condition changes before
> retrying.
> 
> However, the retry logic begins with the zone where the previous attempt
> ended, and selects the zones that were previously write target.
> Consequently, the same zones are repeatedly chosen for writing,
> resulting in writes concentrating on certain zones despite the workload
> specifying random write.
> 
> To ensure proper zone selection for random writes, modify
> zbd_convert_to_write_zone() to retry the zone selection based on the
> original offset provided to the function. The local variable 'zb' keeps
> the reference to the zone corresponding to the original offset. Use 'zb'
> at the retry attempt start.
> 
> Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>

Looks good to me.

Reviewed-by: Damien Le Moal <dlemoal@kernel.org>

-- 
Damien Le Moal
Western Digital Research

  reply	other threads:[~2026-02-27  4:48 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-16  7:59 [PATCH v2 0/8] zbd: fix problems of random write with unaligned block size Shin'ichiro Kawasaki
2026-02-16  7:59 ` [PATCH v2 1/8] zbd: fix zone selection of random writes Shin'ichiro Kawasaki
2026-02-27  4:48   ` Damien Le Moal [this message]
2026-02-16  7:59 ` [PATCH v2 2/8] zbd: fix write zone accounting Shin'ichiro Kawasaki
2026-02-27  4:53   ` Damien Le Moal
2026-02-27 12:08     ` Shinichiro Kawasaki
2026-02-16  7:59 ` [PATCH v2 3/8] zbd: introduce write_zone_remainder option Shin'ichiro Kawasaki
2026-02-27  4:59   ` Damien Le Moal
2026-02-16  7:59 ` [PATCH v2 4/8] doc: explain the option write_zone_remainder Shin'ichiro Kawasaki
2026-02-27  5:06   ` Damien Le Moal
2026-02-16  7:59 ` [PATCH v2 5/8] t/zbd: add -m option to enable write_zone_remainder option Shin'ichiro Kawasaki
2026-02-16  7:59 ` [PATCH v2 6/8] t/zbd: avoid test case 14 failure with " Shin'ichiro Kawasaki
2026-02-16  7:59 ` [PATCH v2 7/8] t/zbd: avoid test case 33 " Shin'ichiro Kawasaki
2026-02-16  7:59 ` [PATCH v2 8/8] t/zbd: avoid test case 71 " Shin'ichiro Kawasaki
2026-02-16  9:10 ` [PATCH v2 0/8] zbd: fix problems of random write with unaligned block size fiotestbot

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=cfbd8963-228a-42ee-8cfa-f2cbd01a9991@kernel.org \
    --to=dlemoal@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=fio@vger.kernel.org \
    --cc=shinichiro.kawasaki@wdc.com \
    --cc=vincentfu@gmail.com \
    /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