[PATCH] sched: core: Remove unnecessary ‘NULL’ values from core_rq
From: Li zeming
Date: Tue May 28 2024 - 03:16:07 EST
core_rq is assigned first, so it does not need to initialize the
assignment.
Signed-off-by: Li zeming <zeming@xxxxxxxxxxxx>
---
kernel/sched/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index e32fea8f5830..346159a24705 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -6485,7 +6485,7 @@ static void sched_core_cpu_starting(unsigned int cpu)
static void sched_core_cpu_deactivate(unsigned int cpu)
{
const struct cpumask *smt_mask = cpu_smt_mask(cpu);
- struct rq *rq = cpu_rq(cpu), *core_rq = NULL;
+ struct rq *rq = cpu_rq(cpu), *core_rq;
int t;
guard(core_lock)(&cpu);
--
2.18.2