From nobody Wed Apr 8 12:49:45 2026 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 391D8ECAAD3 for ; Fri, 9 Sep 2022 14:00:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232043AbiIIOAj (ORCPT ); Fri, 9 Sep 2022 10:00:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231782AbiIIOAT (ORCPT ); Fri, 9 Sep 2022 10:00:19 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C6D66D9E5; Fri, 9 Sep 2022 07:00:18 -0700 (PDT) Date: Fri, 09 Sep 2022 14:00:15 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1662732017; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YCGme84nO6sBKEDLB3+s+9kW6qoJ0d6C7gstoiW8pRg=; b=Jy2SUweE1GxMxRsHi1y24sSLE45Pe9f0Cd5WFHIul7vieOHU78YGFkn0Z4gL9SqgfyFCzu ndjc0zftnoi0YwMRZUGfgHksKwHN68afM+XP+995HrpFPjQ7Ji+AjFgdUeH0qUstmYFSZ0 FP7BQdfQgJTmrLbEzJ0mQxirYpd6MD4CdrdlaYkztRsXTOSHBlCPAI3fp6ybJkjW87LEAv 6P9ftS+8l6C9KVbWofaaTRC+Hn2hIiVT51XDKM0G2nz/2/xZlpQfNvBReqKKNbMfkuobnL /Uf7FVsl9pdybvcKmMf9FyuHLScrrAa8Pnt9DsEobblmCmRtCRQmYmANNuRycQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1662732017; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YCGme84nO6sBKEDLB3+s+9kW6qoJ0d6C7gstoiW8pRg=; b=vGmZS6uwK4OoQ0pGgTqGLPJePXIzihTy5SjJiuRZdY1UsI+5QxG6jbJxm8p/FfXp72dCJs WpYb5tDggdzdJdAQ== From: "tip-bot2 for Chengming Zhou" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/psi] sched/psi: Move private helpers to sched/stats.h Cc: Chengming Zhou , "Peter Zijlstra (Intel)" , Johannes Weiner , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20220825164111.29534-5-zhouchengming@bytedance.com> References: <20220825164111.29534-5-zhouchengming@bytedance.com> MIME-Version: 1.0 Message-ID: <166273201595.401.8558598021682834136.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the sched/psi branch of tip: Commit-ID: d79ddb069c5257a924456eb99b53fc1ea715c0a3 Gitweb: https://git.kernel.org/tip/d79ddb069c5257a924456eb99b53fc1ea= 715c0a3 Author: Chengming Zhou AuthorDate: Fri, 26 Aug 2022 00:41:05 +08:00 Committer: Peter Zijlstra CommitterDate: Fri, 09 Sep 2022 11:08:31 +02:00 sched/psi: Move private helpers to sched/stats.h This patch move psi_task_change/psi_task_switch declarations out of PSI public header, since they are only needed for implementing the PSI stats tracking in sched/stats.h psi_task_switch is obvious, psi_task_change can't be public helper since it doesn't check psi_disabled static key. And there is no any user now, so put it in sched/stats.h too. Signed-off-by: Chengming Zhou Signed-off-by: Peter Zijlstra (Intel) Acked-by: Johannes Weiner Link: https://lore.kernel.org/r/20220825164111.29534-5-zhouchengming@byteda= nce.com --- include/linux/psi.h | 4 ---- kernel/sched/stats.h | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/linux/psi.h b/include/linux/psi.h index dd74411..fffd229 100644 --- a/include/linux/psi.h +++ b/include/linux/psi.h @@ -18,10 +18,6 @@ extern struct psi_group psi_system; =20 void psi_init(void); =20 -void psi_task_change(struct task_struct *task, int clear, int set); -void psi_task_switch(struct task_struct *prev, struct task_struct *next, - bool sleep); - void psi_memstall_enter(unsigned long *flags); void psi_memstall_leave(unsigned long *flags); =20 diff --git a/kernel/sched/stats.h b/kernel/sched/stats.h index baa839c..c39b467 100644 --- a/kernel/sched/stats.h +++ b/kernel/sched/stats.h @@ -107,6 +107,10 @@ __schedstats_from_se(struct sched_entity *se) } =20 #ifdef CONFIG_PSI +void psi_task_change(struct task_struct *task, int clear, int set); +void psi_task_switch(struct task_struct *prev, struct task_struct *next, + bool sleep); + /* * PSI tracks state that persists across sleeps, such as iowaits and * memory stalls. As a result, it has to distinguish between sleeps,