[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20251009194818.1587650-1-kriish.sharma2006@gmail.com>
Date: Thu, 9 Oct 2025 19:48:18 +0000
From: Kriish Sharma <kriish.sharma2006@...il.com>
To: Ingo Molnar <mingo@...hat.com>,
Peter Zijlstra <peterz@...radead.org>,
Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Steven Rostedt <rostedt@...dmis.org>,
Ben Segall <bsegall@...gle.com>,
Mel Gorman <mgorman@...e.de>,
Valentin Schneider <vschneid@...hat.com>
Cc: linux-kernel@...r.kernel.org,
david.hunter.linux@...il.com,
skhan@...uxfoundation.org,
Kriish Sharma <kriish.sharma2006@...il.com>
Subject: [PATCH] sched: remove unused cpumask variable in mm_cid_get()
The variable 'cpumask' in mm_cid_get() was assigned but never used,
causing the following build error with -Werror:
kernel/sched/sched.h: In function ‘mm_cid_get’:
kernel/sched/sched.h:3743:25: error: variable ‘cpumask’ set but not used [-Werror=unused-but-set-variable]
3743 | struct cpumask *cpumask;
| ^~~~~~~
Removing the unused variable allows the kernel to compile without errors.
Signed-off-by: Kriish Sharma <kriish.sharma2006@...il.com>
---
kernel/sched/sched.h | 2 --
1 file changed, 2 deletions(-)
diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h
index 1f5d07067f60..361f9101cef9 100644
--- a/kernel/sched/sched.h
+++ b/kernel/sched/sched.h
@@ -3740,11 +3740,9 @@ static inline int mm_cid_get(struct rq *rq, struct task_struct *t,
struct mm_struct *mm)
{
struct mm_cid __percpu *pcpu_cid = mm->pcpu_cid;
- struct cpumask *cpumask;
int cid;
lockdep_assert_rq_held(rq);
- cpumask = mm_cidmask(mm);
cid = __this_cpu_read(pcpu_cid->cid);
if (mm_cid_is_valid(cid)) {
mm_cid_snapshot_time(rq, mm);
--
2.34.1
Powered by blists - more mailing lists