From patchwork Wed Oct 9 15:17:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tang Yizhou X-Patchwork-Id: 13828549 Received: from mail-pg1-f179.google.com (mail-pg1-f179.google.com [209.85.215.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 23F57197A8F for ; Wed, 9 Oct 2024 14:41:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.179 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728484901; cv=none; b=c7zN0NbvyeUBnI+KxMohVxdc1EFHGkPi5atmb9w+uUBhDtXKKiznjipF+4GMLcqQApF00r2rIQ6xG8ycAiZpJnBlskMokeywJJmyeqJg3BfKkJVCl00hJNe9B/efR7DCfKxr+pEvVWkn3DZNeomYiehYHYFL2WXmF8um39eKh+Y= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728484901; c=relaxed/simple; bh=ZkMXaGXK3vOYJa0SvIWW1dfqffTI0W6YThAuMAv9htE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=mN401ZQfgS7PiAmc/skKpF2fCwJXj9tPWbJLiX/OdaGvGbwOQo4QJIHgLJPyFx78UoKzDga4URzC9i1+bqU0f4XKIleOtKnANI2NILePQ+E1IkJQaUYS0UVth+q6fBBOtYIGsg5vr2rdqwj4u/5bHjQlgrl0SW3t1vJVzw0EmG0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=shopee.com; spf=pass smtp.mailfrom=shopee.com; dkim=pass (2048-bit key) header.d=shopee.com header.i=@shopee.com header.b=Y6orSiGL; arc=none smtp.client-ip=209.85.215.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=shopee.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=shopee.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=shopee.com header.i=@shopee.com header.b="Y6orSiGL" Received: by mail-pg1-f179.google.com with SMTP id 41be03b00d2f7-7ea1b850d5cso1280929a12.1 for ; Wed, 09 Oct 2024 07:41:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shopee.com; s=shopee.com; t=1728484899; x=1729089699; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=VIiaKwpes0nmcRx/K3u+SN5+YvMoD90XzWrUKk6r3qs=; b=Y6orSiGLd/BlwnPnhKtKJcmg06qSANR5CGxijQTMHgMMMCHkniGq/DQTBTpGc3oBFg VOYmh48+RvkhOEAlXCs1hkvAnvCO1KJaOrCQIPGwX5AIH0VM+XOcOe8vjkvgxcqbCF/a aKTMt4/6/yu/FHOY+UeOBQ/erdBERoStcZwYhAs5RDo6UiIu5bL408P+aQVi1v5I2u8N sbzD6osvAD/GgcU4yZMrJlijfDiQDoJH8ag6z8unSMKhkqSzWPIWEw6+MkpjV7cpEpyG CcD8fTevU8xBXl6Ue38HVhCN7u0b2uTWg8Ecvr5+YxIJZ2hhC2LhUBaZ9z6WAErD4TRM PdTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728484899; x=1729089699; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=VIiaKwpes0nmcRx/K3u+SN5+YvMoD90XzWrUKk6r3qs=; b=vgqVUIt6g7E/8lbj+BkPVu+kLiRU2EQ9ZhTljkM55ZcyceDEzLc7I+EyPmgN2EjHkj 4v2LJjaykK7f261mLvlJ1mQnuwn42vQVtzpMkLjN4MGprZrT/2yOw6dVEVO1ieHohKWa 0Agz/xIlIiSD5fXZPMjP6aS4HY11RD2jE9qumZu0ziN65iFjwcuHTSdXlCa/56DxSqY0 IQ/zWA+3/VbSojzbsfiZGQekuftW5cDzeFcMBOxS1VRglKqldds4a1b6rA5MBlO0NAEK ud2ufBUU5RmYE5lmD6B8VDTIibExcagjUUzpCXB2VNe1l/JblRC8sp/BiunqX6k2C/tA 27ow== X-Forwarded-Encrypted: i=1; AJvYcCW5lHGgOORg+YJ/lidXBVKljI/gBJV5UhojIQEQd4sD1TDo0gwJ1ink75XEvNP2BY6ZypEIb1zIDjyDYtAq@vger.kernel.org X-Gm-Message-State: AOJu0YwtGnsuDOxgQY4VAFZg+c18E80EUoRnfvEteXVo7roVOLWBBmeR pXISBmonOCk/+FmNP9fNvSQfushkWUhczXy5Cev7AVBJk62qevcxBLqpJCwL03I= X-Google-Smtp-Source: AGHT+IEaZ/prco7C4oF5lCWqhRZLR0ygJ+Go+pa+KiOBjSGAm0bDYgzb9+GyjYftuCC7qtA8vT67yw== X-Received: by 2002:a05:6a20:c791:b0:1d2:e94d:45a6 with SMTP id adf61e73a8af0-1d8a3bfec45mr5025125637.14.1728484899516; Wed, 09 Oct 2024 07:41:39 -0700 (PDT) Received: from localhost.localdomain ([143.92.64.20]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71df0ccdb64sm7852764b3a.48.2024.10.09.07.41.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Oct 2024 07:41:39 -0700 (PDT) From: Tang Yizhou X-Google-Original-From: Tang Yizhou To: jack@suse.cz, hch@infradead.org, akpm@linux-foundation.org Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Tang Yizhou Subject: [PATCH v3 1/2] mm/page-writeback.c: Update comment for BANDWIDTH_INTERVAL Date: Wed, 9 Oct 2024 23:17:27 +0800 Message-Id: <20241009151728.300477-2-yizhou.tang@shopee.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20241009151728.300477-1-yizhou.tang@shopee.com> References: <20241009151728.300477-1-yizhou.tang@shopee.com> Precedence: bulk X-Mailing-List: linux-fsdevel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Tang Yizhou The name of the BANDWIDTH_INTERVAL macro is misleading, as it is not only used in the bandwidth update functions wb_update_bandwidth() and __wb_update_bandwidth(), but also in the dirty limit update function domain_update_dirty_limit(). Currently, we haven't found an ideal name, so update the comment only. Signed-off-by: Tang Yizhou Reviewed-by: Jan Kara --- mm/page-writeback.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page-writeback.c b/mm/page-writeback.c index fcd4c1439cb9..c7c6b58a8461 100644 --- a/mm/page-writeback.c +++ b/mm/page-writeback.c @@ -54,7 +54,7 @@ #define DIRTY_POLL_THRESH (128 >> (PAGE_SHIFT - 10)) /* - * Estimate write bandwidth at 200ms intervals. + * Estimate write bandwidth or update dirty limit at 200ms intervals. */ #define BANDWIDTH_INTERVAL max(HZ/5, 1) From patchwork Wed Oct 9 15:17:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tang Yizhou X-Patchwork-Id: 13828550 Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 098FE1A0B16 for ; Wed, 9 Oct 2024 14:41:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.170 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728484904; cv=none; b=a2wof9lHhzhaeQ51+Yr9LaVxPyET+60IxyfecLPjTNLfYxWT7y/B4s95JAlEe6veuxj3e5vXD3T11haZHGqdcg9imVU9TE8m8EJ2jtx7t3i1w/zP983idBfrZIDYHQOwUwqqd6JD7sRAa9muZUYMMoJ2+4MwZiz4eANaVFlOO4M= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728484904; c=relaxed/simple; bh=x1PEDGoQZwbge4Fs0/XyWOQN0GzDczYGkUFOvNnIEXs=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=o6SnGittRSi8wWlh9rYhXi+5gxT4MYzLQGpHQ51y0VuTcLI///X2L+4yHGGh5wBWf+YY48ocCicT7Z+3ehF0BUD9nPZA4epBFQGLF+2nkM2mLC1DXFD673evh4HAFn3xOo3mcJZaDxUQpAHtEQUWoOdDRVNHWx8Ty1LiDyb5NMg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=shopee.com; spf=pass smtp.mailfrom=shopee.com; dkim=pass (2048-bit key) header.d=shopee.com header.i=@shopee.com header.b=MMd6c0jx; arc=none smtp.client-ip=209.85.210.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=shopee.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=shopee.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=shopee.com header.i=@shopee.com header.b="MMd6c0jx" Received: by mail-pf1-f170.google.com with SMTP id d2e1a72fcca58-71e05198d1dso2404171b3a.1 for ; Wed, 09 Oct 2024 07:41:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shopee.com; s=shopee.com; t=1728484902; x=1729089702; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=262u3WRSsnZCS6tRA/wryh4VmMTwkyxbe0lMaxXGOBA=; b=MMd6c0jxPSa1HgufRPOSfBtaBGFCjblfIJA2K7hKC3CnW5T7E+LY8nviBarVirRQ1x GRUargm8fPXekdmqIQRwQr9rtAvF+JYe34OjtlZSRbGFal7Tn24YFYhMN0XJlR4i2xea oChWpQ92PIlcwyRfRrgn/SCyUj0E2LXdzm4y2bLrpNJTyUm4QAO7GHKiUrp02GtFSjZu iAWfUQBiYS2bh2WngfVNCYpQ33ouT21H845Z0M1L0Emfxh3RZguvGMkRGVSKUfxMwDoe uFbWocIoUOlF+Y+gX6j3uNGQvYOeoFVppU5Iy0p6+YVl1AQOUo1ZuBCQ+ITza0dcz43T Jh5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728484902; x=1729089702; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=262u3WRSsnZCS6tRA/wryh4VmMTwkyxbe0lMaxXGOBA=; b=oaTIi7wTa+r/CxkkHChsGq/Q8i3rBxfg2L//EBaMhxJCGH9rAhDOxDdw8YFuznvV8W 9xHaGephIhmSmSoh6T9POOP8tkB5eGljhIGWo6GnAzGJ/J3Hit0LGPmqdS+SmHEo6DRM avZUUuj2ZW31ZiMWMIfxx49mYdyQnWG3Kkni7sz+H+8WZ6dDdyo55Pxp//xI+r28QDhZ nqG5Q10UCwuDfA4Cs0d6twJF+TKrhWFpnOlyzXxu+TwQ+72052J4mzt3A11arwaJUPTq QnCSMUUOgurL/uOHVabyewbFaGX0diQUS6DafTIWW8M4Y3FH5OGchqVVT3jzJqqV6rkI k4Pg== X-Forwarded-Encrypted: i=1; AJvYcCVoj2Xyy8nFFjAXailgNdR1mgnoHYM/Jt2QWnCtfUDiEKykKtPj45SRjfFmCNAoUQHXF7mZhyt5UzcaAOy9@vger.kernel.org X-Gm-Message-State: AOJu0YxyqLOvtoeCjPWTU6yAosDSioi2qKbJLAdxF17vCbIN+0k94UGC 4HzHlWwFgce4rgGZRAl+RlUw6SAsByMMOEMSrNhLzaZa9ZhDZDbir9LMiel1ULw= X-Google-Smtp-Source: AGHT+IG8FUHdCZJ605uLVInPK/Fx/m2C72TUt/JwkrShuf6hbCKGofvSPaCkEirNpBKGNWAE8tweJA== X-Received: by 2002:a05:6a00:194f:b0:71d:eb7d:20d5 with SMTP id d2e1a72fcca58-71e1db74bbamr4668154b3a.8.1728484902193; Wed, 09 Oct 2024 07:41:42 -0700 (PDT) Received: from localhost.localdomain ([143.92.64.20]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71df0ccdb64sm7852764b3a.48.2024.10.09.07.41.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Oct 2024 07:41:41 -0700 (PDT) From: Tang Yizhou X-Google-Original-From: Tang Yizhou To: jack@suse.cz, hch@infradead.org, akpm@linux-foundation.org Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Tang Yizhou Subject: [PATCH v3 2/2] mm/page-writeback.c: Fix comment of wb_domain_writeout_add() Date: Wed, 9 Oct 2024 23:17:28 +0800 Message-Id: <20241009151728.300477-3-yizhou.tang@shopee.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20241009151728.300477-1-yizhou.tang@shopee.com> References: <20241009151728.300477-1-yizhou.tang@shopee.com> Precedence: bulk X-Mailing-List: linux-fsdevel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Tang Yizhou __bdi_writeout_inc() has undergone multiple renamings, but the comment within the function body have not been updated accordingly. Update it to reflect the latest wb_domain_writeout_add(). Signed-off-by: Tang Yizhou Reviewed-by: Jan Kara --- mm/page-writeback.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page-writeback.c b/mm/page-writeback.c index c7c6b58a8461..72a5d8836425 100644 --- a/mm/page-writeback.c +++ b/mm/page-writeback.c @@ -586,7 +586,7 @@ static void wb_domain_writeout_add(struct wb_domain *dom, /* First event after period switching was turned off? */ if (unlikely(!dom->period_time)) { /* - * We can race with other __bdi_writeout_inc calls here but + * We can race with other wb_domain_writeout_add calls here but * it does not cause any harm since the resulting time when * timer will fire and what is in writeout_period_time will be * roughly the same.