From: Christoph Hellwig <hch@lst.de>
To: Bart Van Assche <bvanassche@acm.org>
Cc: Jens Axboe <axboe@kernel.dk>,
linux-block@vger.kernel.org, Christoph Hellwig <hch@lst.de>,
Damien Le Moal <dlemoal@kernel.org>,
Ming Lei <ming.lei@redhat.com>,
Daniel Gomez <da.gomez@kernel.org>,
Luis Chamberlain <mcgrof@kernel.org>
Subject: Re: [PATCH v2 2/5] block: Fix the max_user_sectors lower bound
Date: Thu, 26 Mar 2026 15:23:55 +0100 [thread overview]
Message-ID: <20260326142355.GB16940@lst.de> (raw)
In-Reply-To: <20260325213719.2850619-3-bvanassche@acm.org>
On Wed, Mar 25, 2026 at 02:37:12PM -0700, Bart Van Assche wrote:
> The lowest value that can be supported for lim->max_user_sectors is the
> logical block size. This patch prepares for reducing BLK_MIN_SEGMENT_SIZE
> to a value that may be less than the logical block size.
>
> Cc: Ming Lei <ming.lei@redhat.com>
> Fixes: 889c57066cee ("block: make segment size limit workable for > 4K PAGE_SIZE")
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> ---
> block/blk-settings.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/block/blk-settings.c b/block/blk-settings.c
> index 87724d30be4f..13f5457f9f4e 100644
> --- a/block/blk-settings.c
> +++ b/block/blk-settings.c
> @@ -403,7 +403,7 @@ int blk_validate_limits(struct queue_limits *lim)
> max_hw_sectors = min_not_zero(lim->max_hw_sectors,
> lim->max_dev_sectors);
> if (lim->max_user_sectors) {
> - if (lim->max_user_sectors < BLK_MIN_SEGMENT_SIZE / SECTOR_SIZE)
> + if (lim->max_user_sectors < lim->logical_block_size / SECTOR_SIZE)
Overly long line.
next prev parent reply other threads:[~2026-03-26 14:23 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-25 21:37 [PATCH v2 0/5] Enable testing small DMA segment sizes Bart Van Assche
2026-03-25 21:37 ` [PATCH v2 1/5] block: Fix a source code comment Bart Van Assche
2026-03-26 14:23 ` Christoph Hellwig
2026-03-26 14:48 ` Ming Lei
2026-03-25 21:37 ` [PATCH v2 2/5] block: Fix the max_user_sectors lower bound Bart Van Assche
2026-03-26 14:23 ` Christoph Hellwig [this message]
2026-03-26 14:46 ` Ming Lei
2026-03-25 21:37 ` [PATCH v2 3/5] block: Remove a DMA segment boundary mask check Bart Van Assche
2026-03-26 14:51 ` Ming Lei
2026-03-26 15:51 ` Bart Van Assche
2026-03-27 0:52 ` Ming Lei
2026-03-27 1:55 ` Bart Van Assche
2026-03-25 21:37 ` [PATCH v2 4/5] block: Reduce the minimum value for the maximum DMA segment size Bart Van Assche
2026-03-25 21:37 ` [PATCH v2 5/5] null_blk: Support configuring " 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=20260326142355.GB16940@lst.de \
--to=hch@lst.de \
--cc=axboe@kernel.dk \
--cc=bvanassche@acm.org \
--cc=da.gomez@kernel.org \
--cc=dlemoal@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=mcgrof@kernel.org \
--cc=ming.lei@redhat.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