From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 489BCFA3745 for ; Tue, 1 Nov 2022 09:40:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230404AbiKAJkI (ORCPT ); Tue, 1 Nov 2022 05:40:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47224 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230395AbiKAJjn (ORCPT ); Tue, 1 Nov 2022 05:39:43 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AF4FE19C0B; Tue, 1 Nov 2022 02:39:00 -0700 (PDT) Received: from kwepemi500016.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4N1lMH5m6MzHvT0; Tue, 1 Nov 2022 17:38:35 +0800 (CST) Received: from [10.174.178.129] (10.174.178.129) by kwepemi500016.china.huawei.com (7.221.188.220) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 1 Nov 2022 17:38:53 +0800 Subject: Re: [PATCH v2 2/3] block: Correct comment for scale_cookie_change To: , , CC: , , References: <20221018111240.22612-1-shikemeng@huawei.com> <20221018111240.22612-3-shikemeng@huawei.com> From: Kemeng Shi Message-ID: Date: Tue, 1 Nov 2022 17:38:34 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0 MIME-Version: 1.0 In-Reply-To: <20221018111240.22612-3-shikemeng@huawei.com> Content-Type: text/plain; charset="gbk" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.178.129] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemi500016.china.huawei.com (7.221.188.220) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Friendly ping. on 10/18/2022 7:12 PM, Kemeng Shi wrote: > Default queue depth of iolatency_grp is unlimited, so we scale down > quickly(once by half) in scale_cookie_change. Remove the "subtract > 1/16th" part which is not the truth and add the actual way we > scale down. > > Signed-off-by: Kemeng Shi > --- > block/blk-iolatency.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/block/blk-iolatency.c b/block/blk-iolatency.c > index b24d7b788ba3..2c574f98c8d1 100644 > --- a/block/blk-iolatency.c > +++ b/block/blk-iolatency.c > @@ -364,9 +364,11 @@ static void scale_cookie_change(struct blk_iolatency *blkiolat, > } > > /* > - * Change the queue depth of the iolatency_grp. We add/subtract 1/16th of the > + * Change the queue depth of the iolatency_grp. We add 1/16th of the > * queue depth at a time so we don't get wild swings and hopefully dial in to > - * fairer distribution of the overall queue depth. > + * fairer distribution of the overall queue depth. We halve the queue depth > + * at a time so we can scale down queue depth quickly from default unlimited > + * to target. > */ > static void scale_change(struct iolatency_grp *iolat, bool up) > { > -- Best wishes Kemeng Shi