From: Bart Van Assche <bvanassche@acm.org>
To: "牛志国 (Zhiguo Niu)" <Zhiguo.Niu@unisoc.com>,
"Jens Axboe" <axboe@kernel.dk>
Cc: "linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
"Christoph Hellwig" <hch@lst.de>,
"stable@vger.kernel.org" <stable@vger.kernel.org>,
"Damien Le Moal" <dlemoal@kernel.org>,
"Harshit Mogalapalli" <harshit.m.mogalapalli@oracle.com>,
"金红宇 (Hongyu Jin)" <hongyu.jin@unisoc.com>
Subject: Re: 答复: [PATCH] Revert "block/mq-deadline: use correct way to throttling write requests"
Date: Thu, 14 Mar 2024 10:08:10 -0700 [thread overview]
Message-ID: <cf7e6d94-63fd-4ef5-bbdb-9c3877d8560a@acm.org> (raw)
In-Reply-To: <cf8127b0fa594169a71f3257326e5bec@BJMBX02.spreadtrum.com>
On 3/13/24 18:03, 牛志国 (Zhiguo Niu) wrote:
> Just as mentioned in original patch, "dd->async_depth = max(1UL, 3 * q->nr_requests / 4);", this limitation methods look likes won't have a limit effect, because tag allocated is based on sbitmap, not based the whole nr_requests.
> Right?
> Thanks!
>
> For write requests, when we assign a tags from sched_tags,
> data->shallow_depth will be passed to sbitmap_find_bit,
> see the following code:
>
> nr = sbitmap_find_bit_in_word(&sb->map[index],
> min_t (unsigned int,
> __map_depth(sb, index),
> depth),
> alloc_hint, wrap);
>
> The smaller of data->shallow_depth and __map_depth(sb, index)
> will be used as the maximum range when allocating bits.
>
> For a mmc device (one hw queue, deadline I/O scheduler):
> q->nr_requests = sched_tags = 128, so according to the previous
> calculation method, dd->async_depth = data->shallow_depth = 96,
> and the platform is 64bits with 8 cpus, sched_tags.bitmap_tags.sb.shift=5,
> sb.maps[]=32/32/32/32, 32 is smaller than 96, whether it is a read or
> a write I/O, tags can be allocated to the maximum range each time,
> which has not throttling effect.
Whether or not the code in my patch effectively performs throttling,
we need this revert to be merged. The patch that is being reverted
("block/mq-deadline: use correct way to throttling write requests")
ended up in Greg KH's stable branches. Hence, the first step is to
revert that patch and tag it with "Cc: stable" such that the revert
lands in the stable branches.
Thanks,
Bart.
next prev parent reply other threads:[~2024-03-14 17:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-13 21:42 [PATCH] Revert "block/mq-deadline: use correct way to throttling write requests" Bart Van Assche
2024-03-13 21:56 ` Jens Axboe
2024-03-14 1:03 ` 答复: " 牛志国 (Zhiguo Niu)
2024-03-14 17:08 ` Bart Van Assche [this message]
2024-03-14 19:31 ` Jens Axboe
2024-03-14 7:58 ` Harshit Mogalapalli
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=cf7e6d94-63fd-4ef5-bbdb-9c3877d8560a@acm.org \
--to=bvanassche@acm.org \
--cc=Zhiguo.Niu@unisoc.com \
--cc=axboe@kernel.dk \
--cc=dlemoal@kernel.org \
--cc=harshit.m.mogalapalli@oracle.com \
--cc=hch@lst.de \
--cc=hongyu.jin@unisoc.com \
--cc=linux-block@vger.kernel.org \
--cc=stable@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox