Message ID | 20240202191956.88791-1-sj@kernel.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:9bc1:b0:106:209c:c626 with SMTP id op1csp649695dyc; Fri, 2 Feb 2024 11:21:37 -0800 (PST) X-Google-Smtp-Source: AGHT+IG8wqz92Y1CPo8pF/7YCxO65uPiFLwji5141pAdtKqNL4bR8+aHtvzztpXjUNoVQeplLoY4 X-Received: by 2002:a05:6a20:c896:b0:19e:3a94:6272 with SMTP id hb22-20020a056a20c89600b0019e3a946272mr8690876pzb.44.1706901697698; Fri, 02 Feb 2024 11:21:37 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706901697; cv=pass; d=google.com; s=arc-20160816; b=mzieASDCOdK7vWre/D1YkIBTgA3h8j0enRmb62qNj4LLNikAYD6qIlatqqic3S4VHP NMRGNLYAASN2YNqhbq4o907A96QHFr/BVHpwpmlpO1BcU/OhKT654G9XdhQcxZnKs4+I fA/1SKf444UmwMnkV+cuXiyc1WDSIpikUZXuGhHmrZxNUJcM579eR6tbjUHMYUzp2l7s r/IySJnxg2Nkhko0q0pP0GyywlNh9dvntFNvVHdkYDtpcwmQpUYl5mjbVorL7pHk54qg 9AzyBvYcvLOLPbxsmaP8Rj46oAp3vzp6v3RUFVvaGZsxRElQwgh86ILerkqJksrt3vlI 9xaQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=1uACqC+cFdcEnN5VRNHcoyIRX2QzIDbWYdV37Z6AbDQ=; fh=jj/+lLcFV7VPlmQycOwQQbuiLLeLl815h9mILcYvJj4=; b=YrzapIVnPEGtT1yRBU6AawAbUvqy70xRfD5BSMJ4hzvXiWhVNCLbhZVF+XuMqq6KUs CkOAazV58UmKCPU2nm7OJkGxwHSO+W7osvfI4vcpMp8vw1OMPOcumsR9Vk6vnnbwMd7x m3y2cPiph/R+yebu1t3NXf+hn1KkV+vqmXY2BOl5V78nceRlrIpIL5EvWoESv3jcAwgX OptWRSUzbPQYn6M4NiXbGLOXVc2rQrz5A0xCmqp20V6GE+EQkGzMUC+CmgDH+gPYA4DW TNIYqRMqJ/vHy0mQc8M0vF4rPn6jT0OwuFeyNveYmaSZB+E7wG5DXY0bwDnwBS7YgDch cILg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=fWWnRyOf; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCVIsxoGHY+GkPcdu6wfmvdWFgcJAPeVcRFTloCMlGHBg6cnV3uU6Z85C96wuMDCYooE94uzs1OOs84kGS7OE5+BR6GMPQ== Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id x33-20020a634a21000000b005c6c950c3bdsi2023427pga.642.2024.02.02.11.21.37 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Feb 2024 11:21:37 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=fWWnRyOf; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50473-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=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 sv.mirrors.kernel.org (Postfix) with ESMTPS id EBF9128B6F6 for <ouuuleilei@gmail.com>; Fri, 2 Feb 2024 19:20:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A4B2B15E5AE; Fri, 2 Feb 2024 19:20:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="fWWnRyOf" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 EB85A15E5A0; Fri, 2 Feb 2024 19:20:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706901601; cv=none; b=ipf2KbB9XuNA1d0d7qefM/AGjwwJv16/UAL5rpwE9IxYWfxlqAm1MNn5FcA7x7Y6LwPTIy3eTowqFGXFHLE+TYhRJtu6WFdTnH5BVcyS2iO24t4FBvbYCy1dFtwjRiYmDz2WicbvVHUeB8vaa2AOIXG0BUjfPaouU0igiY1Y0Q8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706901601; c=relaxed/simple; bh=CbXReCX3ZlwbbZZ2LtMRe+PpRclG31Ljw0m0O0lK4fo=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=Oe0HPkht0TCMdpkHMpWI27bQfSalwAd2CB6cmjKOksRTAW/K1iNnXmNsrMWhXHWS61S0x/dGR3EKlSh6+Xqdd+l0Qh6j+gMy8ftG6nKKpctPlK/aCNFK/EbOYPCYVASrkc4zp0nkrnx0FIq66M4zlLEXPK/51YDwhkv7HLeBJjk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=fWWnRyOf; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 12E5EC433F1; Fri, 2 Feb 2024 19:20:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706901600; bh=CbXReCX3ZlwbbZZ2LtMRe+PpRclG31Ljw0m0O0lK4fo=; h=From:To:Cc:Subject:Date:From; b=fWWnRyOfm4mJOX4/eZm+IhaEuLd1JuKdV+JW9Cqe8Z9GKZLpYjLR+5gi8kaWErJYW 3K2uTX+OuwDimwPLsJKDLMCcYTyK/9WaPRneECK2oHFpiWGS/psfiQHarTduW11vtq NJcFDB8Uird8U3HpiEpeO5H6m/aTS3hYKe5RoB4a9jLR2IBN27hS+e7QbL6zt8twBD Sxh2/kDFpF9026EJNrEwzxCygItSwYJ46LVz+a3FXjBJeloGejiKvT3ELuY3LSEfoZ VRqeGWicI+QLrMmr76xm0QYXyNbPgmJP8NmrhBMeJkFpZnhdPdnkahKMIR3hcQOn+b vAsjtwJfaQG3A== From: SeongJae Park <sj@kernel.org> To: Andrew Morton <akpm@linux-foundation.org> Cc: SeongJae Park <sj@kernel.org>, damon@lists.linux.dev, linux-mm@kvack.org, stable@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH ] mm/damon/sysfs-schemes: fix wrong DAMOS tried regions update timeout setup Date: Fri, 2 Feb 2024 11:19:56 -0800 Message-Id: <20240202191956.88791-1-sj@kernel.org> X-Mailer: git-send-email 2.39.2 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1789816154811532727 X-GMAIL-MSGID: 1789816154811532727 |
Series |
mm/damon/sysfs-schemes: fix wrong DAMOS tried regions update timeout setup
|
|
Commit Message
SeongJae Park
Feb. 2, 2024, 7:19 p.m. UTC
DAMON sysfs interface's update_schemes_tried_regions command has a
timeout of two apply intervals of the DAMOS scheme. Having zero value
DAMOS scheme apply interval means it will use the aggregation interval
as the value. However, the timeout setup logic is mistakenly using the
sampling interval insted of the aggregartion interval for the case.
This could cause earlier-than-expected timeout of the command. Fix it.
Fixes: 7d6fa31a2fd7 ("mm/damon/sysfs-schemes: add timeout for update_schemes_tried_regions")
Cc: <stable@vger.kernel.org> # 6.7.x
Signed-off-by: SeongJae Park <sj@kernel.org>
---
mm/damon/sysfs-schemes.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/damon/sysfs-schemes.c b/mm/damon/sysfs-schemes.c index 8dbaac6e5c2d..dd2fb5127009 100644 --- a/mm/damon/sysfs-schemes.c +++ b/mm/damon/sysfs-schemes.c @@ -2194,7 +2194,7 @@ static void damos_tried_regions_init_upd_status( sysfs_regions->upd_timeout_jiffies = jiffies + 2 * usecs_to_jiffies(scheme->apply_interval_us ? scheme->apply_interval_us : - ctx->attrs.sample_interval); + ctx->attrs.aggr_interval); } }