Received: by 2002:ab2:6203:0:b0:1f5:f2ab:c469 with SMTP id o3csp2015618lqt; Sun, 21 Apr 2024 20:48:04 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVBgX4Jbu+jsvHKnh0HvKm8tb+FBWRea6PuMTlKoSP4wu2eRsVTghhalfOSM/itsStDMgA23NAow4UVu5Z+uReTTik6J01DH4rc3xpvSA== X-Google-Smtp-Source: AGHT+IEUbtU7QkWLLwoPhMWpJ85OnaEk+Y2sQjMwkgThDINwkjquQxpnk8ksC9Zuy/ulYR9RNVmW X-Received: by 2002:a05:620a:3916:b0:790:5e3c:6d64 with SMTP id qr22-20020a05620a391600b007905e3c6d64mr8946011qkn.11.1713757684736; Sun, 21 Apr 2024 20:48:04 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713757684; cv=pass; d=google.com; s=arc-20160816; b=AyN/Pup1lcVbWWB4LBlJK5xe0qmHKp66mrNwCpY5Uq8HNmP+K8hmdmpbkkziUmZHjV KnWHeJop+j0D2QgZFfZ2mDFaXPnueXnvbLuCH1GIn/LNm2z1iaMpFyrzHeY7/o6zfF8e Re6aJF+VLh9qtH4ZS5bQ/DUXVYeL4bgVzCHpsWmj8+iXEQ3THdmLAeMD5Xf2avxUh2Hz yuM3T+4VnvIGqruNZy0j6HoUUNF7yfm9jKpS16Qh/AC5zsYVM0d+tIozNRvlOo61j4fv VIyKdKSSZaZSoi6viQ76K6kcBPSApra7IFtkuxwt8+g83nS2OdZsTb0wYtVcQ7Y36vvt u+lQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:user-agent:date:message-id:from :references:cc:to:subject; bh=CPSEQasDsW9gUgh8Yu8d9KfYwYUpZgFEpXqIXRcinNA=; fh=7ZJBCYKEX8td3ZMaGOR9b8xLdcOJ6MyJClMN7rj9Q2o=; b=sTz/6gD8he1NypQ45AqbewOWBDIrhvJUKXQrmXCIB+aFRNe6B6rCgOUt0k0om2xI00 i4DC/sjzP116leZX91Dvrd0ZLvAUdsLeRmbxybmmzyYtrqhMA/aD5fV8UilW+L2rQh7C 3BEfbVjBSClHM7MIWU4+pQekv+ON2HCreKx8HrKFrf/BJrr8qk8E4t4MVYZ8FBy+1PE3 7EJ05GdjHErnXEiP6VyIkUrPn07R94NhURTD9wU3SfaYOoXSEfDST+JSFdoNjEjn/Nbt 5awRHiMc33VUcwqxr9Vo9yU/1ICaNSuVN5i0YC8jZhnTz38sW6OW3FUm3nMs9kJVCEzB otQg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huaweicloud.com); spf=pass (google.com: domain of linux-kernel+bounces-152709-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-152709-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id k22-20020a05620a07f600b0078f0fdba93csi8620965qkk.177.2024.04.21.20.48.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Apr 2024 20:48:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-152709-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huaweicloud.com); spf=pass (google.com: domain of linux-kernel+bounces-152709-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-152709-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 781021C2088F for ; Mon, 22 Apr 2024 03:48:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6FBB510957; Mon, 22 Apr 2024 03:47:56 +0000 (UTC) Received: from dggsgout12.his.huawei.com (unknown [45.249.212.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1EEA7819; Mon, 22 Apr 2024 03:47:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.56 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713757675; cv=none; b=m+li5cOijLiNBY10Ae70qj8s8tH8ukCGfWY0N7qTThZ2mPsd5tCtsNkOewggPI4bETQGiXJ3/K+5bU9cl2wfDeahhcbSbKpUKShJVIHX+L2hd+p5OHm2Re4T7Fq8xBcSqAXfvMuJ1WHNNwyu4VS+aRQdHcJHLKbEAaaOTGIL60E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713757675; c=relaxed/simple; bh=dKCOsWmsgjfFo6IO8R3M57gvMEH3lYVCacgWynXwjn8=; h=Subject:To:Cc:References:From:Message-ID:Date:MIME-Version: In-Reply-To:Content-Type; b=XHUnpvW3DLWAPwc6UDImbDywZrUf2R9eI9Y/Bil5gd7E8oxo8gRjtEXmq+IdUvPKSS63aVuo2jFFw6ROUqRVCmVRYulcUIITKp/nEmSNR1HL7NmiapKtpsGtBK44K+aq7X5ozYgOF9gxpcx7a54jlJqnRvOWwDMYGioQvof6LRU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com; spf=pass smtp.mailfrom=huaweicloud.com; arc=none smtp.client-ip=45.249.212.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huaweicloud.com Received: from mail.maildlp.com (unknown [172.19.163.216]) by dggsgout12.his.huawei.com (SkyGuard) with ESMTP id 4VNB602sM9z4f3khV; Mon, 22 Apr 2024 11:47:36 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id CC0A71A0D93; Mon, 22 Apr 2024 11:47:43 +0800 (CST) Received: from [10.174.176.73] (unknown [10.174.176.73]) by APP1 (Coremail) with SMTP id cCh0CgCXaBHe3SVm89mEKg--.58781S3; Mon, 22 Apr 2024 11:47:43 +0800 (CST) Subject: Re: [PATCH] blk-throttle: fix repeat limit on bio with BIO_BPS_THROTTLED To: =?UTF-8?B?5ZGo5rOw5a6H?= , Yu Kuai , "tj@kernel.org" Cc: "josef@toxicpanda.com" , "axboe@kernel.dk" , "cgroups@vger.kernel.org" , "linux-block@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "yukuai (C)" References: <20240419120747.38031-1-zhoutaiyu@kuaishou.com> From: Yu Kuai Message-ID: Date: Mon, 22 Apr 2024 11:47:41 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-CM-TRANSID:cCh0CgCXaBHe3SVm89mEKg--.58781S3 X-Coremail-Antispam: 1UD129KBjvdXoWrZw4xZr13tw4xXry5Gry3Jwb_yoW3ZrX_uF s8Ar1xKrn5Jw4xtr9xKr1Y93ykK3sxuw1qq3ykZF1kX34v9F4kGFW7KFZ7AF1fZanYqws7 Ar4UtayFgay7WjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUb4kFF20E14v26r4j6ryUM7CY07I20VC2zVCF04k26cxKx2IYs7xG 6rWj6s0DM7CIcVAFz4kK6r1j6r18M28lY4IEw2IIxxk0rwA2F7IY1VAKz4vEj48ve4kI8w A2z4x0Y4vE2Ix0cI8IcVAFwI0_tr0E3s1l84ACjcxK6xIIjxv20xvEc7CjxVAFwI0_Gr1j 6F4UJwA2z4x0Y4vEx4A2jsIE14v26rxl6s0DM28EF7xvwVC2z280aVCY1x0267AKxVW0oV Cq3wAS0I0E0xvYzxvE52x082IY62kv0487Mc02F40EFcxC0VAKzVAqx4xG6I80ewAv7VC0 I7IYx2IY67AKxVWUJVWUGwAv7VC2z280aVAFwI0_Jr0_Gr1lOx8S6xCaFVCjc4AY6r1j6r 4UM4x0Y48IcVAKI48JM4x0x7Aq67IIx4CEVc8vx2IErcIFxwCYjI0SjxkI62AI1cAE67vI Y487MxAIw28IcxkI7VAKI48JMxC20s026xCaFVCjc4AY6r1j6r4UMI8I3I0E5I8CrVAFwI 0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AKxVWUtVW8ZwCIc40Y 0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI8IcVCY1x0267AKxV WUJVW8JwCI42IY6xAIw20EY4v20xvaj40_WFyUJVCq3wCI42IY6I8E87Iv67AKxVWUJVW8 JwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjfUoOJ5UU UUU X-CM-SenderInfo: 51xn3trlr6x35dzhxuhorxvhhfrp/ Hi! 在 2024/04/22 11:33, 周泰宇 写道: > What I want to do here was to set an easy to reach value to BPS_LIMIT (10M/s in this example) and an unable to reach value to IOPS_LIMIT (100000 in this example). > > > Under this setting, the iostat shows that the bps is far less than 10M/s and sometimes is far larger than 10M/s. Yes, I know this behaviour, and this is because blk-throttle works before IO split, and io stats is accounting bps for rq-based disk after IO split, if you using Q2C for bps you'll see that bps is stable as limit. Hi, Tejun! Do you think this *phenomenon* need to be fixed? If so, I don't see a easy way other than throttle bio after *IO split*. Perhaps ohter than bio merge case, this can be another motivation to move blk-throttle to rq_qos_throttle(). Thanks, Kuai