From patchwork Thu Mar 7 03:00:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SeongJae Park X-Patchwork-Id: 13584995 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9459CC5475B for ; Thu, 7 Mar 2024 03:00:24 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 000666B00E4; Wed, 6 Mar 2024 22:00:24 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id EF2AD6B00E5; Wed, 6 Mar 2024 22:00:23 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DE1936B00E6; Wed, 6 Mar 2024 22:00:23 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id CBF686B00E4 for ; Wed, 6 Mar 2024 22:00:23 -0500 (EST) Received: from smtpin19.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id A3032160B84 for ; Thu, 7 Mar 2024 03:00:23 +0000 (UTC) X-FDA: 81868739526.19.9DC75EF Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf10.hostedemail.com (Postfix) with ESMTP id 18D0FC0007 for ; Thu, 7 Mar 2024 03:00:21 +0000 (UTC) Authentication-Results: imf10.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=Gr9yFIso; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf10.hostedemail.com: domain of sj@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=sj@kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1709780422; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=PKLObw492qyGSLr6A5sSBR5ytCVigRuPnbDjcYv6NmI=; b=hC3Cu48enExYMPVtHEkdChqGd2oJhEQwSe4/MVlF9Icrzp3pAdGymxGTRhDW3bamf+HZaQ RjMPxDj8ZFUpMiptNrEF1uMlJWeG9MtJmZDPXveVsYlfzzOcEPrgH1AHzlzU3U5LpzAnH+ RhMfdQ4hWQSCwirQnoe5cgql7vnsZMo= ARC-Authentication-Results: i=1; imf10.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=Gr9yFIso; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf10.hostedemail.com: domain of sj@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=sj@kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1709780422; a=rsa-sha256; cv=none; b=AHAVZfiLC7GWbbecgdwDaJDJFiWDimMumWFfQXE/Zj1mhsnupYsTeYb1VGz/oQ99rxOeCh WSSZkogecq7m+fr1wJFZbJRQurxf9UqZoMNoYTytZcCwUZ43Y1IaZ4eaH3dyVaoohHQAsG IklVd0jvmQbCZQHOz0NRlbKqiW2Xakg= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 1EC7161AB8; Thu, 7 Mar 2024 03:00:21 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5CFA2C433A6; Thu, 7 Mar 2024 03:00:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709780420; bh=T4Zlt0HI2JO9pfzPw6anb118M3jARiv+TpO7SVPb1+s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Gr9yFIsoRpLje3SvSmfKYtWNR0uF3miMXc3LPHKsQdFSm9I+Tm4opJXvrkVMMmD3a jLeGpR1MNiipgS8Fs1hljL1UEMO0+qd9APCsbYJjrn0vZbc3dGYayyBIyW4qw++Q+f FJIxtv3yoBl4sUqUdis8IjJkjkkUm2xKA9Xr/eGFcN/S8cIiuRVBeWm636Z3k6qigh aMetigmopMzSlpeWgw3m1T481zUJtpufmVO0T2zISAyN/1SRgZUWDXOyKpgzLiNE30 hqoEhcnBLYXzqzwYIeHdQOGTb9wQAQI64t7ETWJVBakfeE4XdXny8xIed3YHH5t28n lfVc8S8ugzlNQ== From: SeongJae Park To: Cc: SeongJae Park , Andrew Morton , honggyu.kim@sk.com, hyeongtak.ji@sk.com, kernel_team@skhynix.com, damon@lists.linux.dev, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [RFC PATCH 3/3] mm/damon/paddr: support DAMOS filter type YOUNG Date: Wed, 6 Mar 2024 19:00:13 -0800 Message-Id: <20240307030013.47041-4-sj@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240307030013.47041-1-sj@kernel.org> References: <20240307030013.47041-1-sj@kernel.org> MIME-Version: 1.0 X-Rspamd-Queue-Id: 18D0FC0007 X-Rspam-User: X-Rspamd-Server: rspam02 X-Stat-Signature: hx7mpp3ojypbw7cmbwar8t7irmy6toko X-HE-Tag: 1709780421-928741 X-HE-Meta: U2FsdGVkX19cKkiDIPNcV2f+bq1jXmtZQdz38a37sIkXihw0UkpjxZqK0/WqxjZo+VlKE6n4DC6z8Xf5f4/Qb4WPhkPK+MCYwv24fpruW/GNeoV1mmKMqn9bIl79xNEpKHaFHHlxvytwK0ubK/WQXiXVRu5HGdDs7YPwPamcPWgdtlbTAuozdWiRDb2/ODE7o5rEVJxa2SGzCJlyu5nfpJARrgJpVA188EHzCMN5+s8EaWkdvM/+06ToeRuqMQIxwjofvqiiWqgdYC8FquEIpE+tk09ofxia9fiJLq1X2iNnM+d6b611rs0DYaLXfnJSLYV+hE7+5sS+f2rspgpauUuFnTSMytRY0WxJH/dWfobAhjEHFbTcroQa5zqcNoDfAColaHVswNO0DPAhQIeaF6V30VSqut3hWzQdxqBN3O8cq5B2SVrpO1Az+C9ZPLdEuhVOx71l4xw1ehEWxYlj23Iyl+tywF8kw5rITkxlWg9m8DGi8WmgbURg4yPBmZ2p1Pa6uxWEFY8Y6YhqexieJTAof8OC3ExEkZcwA4t/XcSFSBshxUHpmzQ3quLnrC4SFOamrSOqALkfmCgSBbHSq97QrF0BzOQlmF7ij4NmMRA0Nz7zr2os9JmZrM9xGX+guRo58NAzckHOJIplFFb83eofr7kuh9YZsUM+/uaDELID4lmYOzHBfmZFYRbnW+6RmTt2N/H+1r5Xtk0LpxB8RmBRz6VAyPthllBxTtsyAiCzzJ374T00TzIZMZNHTLktLTzbUdLLnkj8L7ALaWryvndZ3wEGZ1lcLSu6owP7au2XsWRE3/fG++/kNmmvFiuMsXfiWDnQPua3zQ3x1gq9FzVek2WKU0riyzi/lbW73iW0fp1fIwbPmmw6VZmSnB86Dof+8eAuGUus6DkzgE7wT9/S7o9yXsxqDw8hJmuGwtc= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: DAMOS filter of type YOUNG is defined, but not yet implemented by any DAMON operations set. Add the implementation to the DAMON operations set for the physical address space, paddr. Signed-off-by: SeongJae Park --- mm/damon/paddr.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mm/damon/paddr.c b/mm/damon/paddr.c index deee0fdf2e5b..52e4be7351cc 100644 --- a/mm/damon/paddr.c +++ b/mm/damon/paddr.c @@ -209,6 +209,9 @@ static bool __damos_pa_filter_out(struct damos_filter *filter, matched = filter->memcg_id == mem_cgroup_id(memcg); rcu_read_unlock(); break; + case DAMOS_FILTER_TYPE_YOUNG: + matched = damon_folio_young(folio); + break; default: break; }