public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@kernel.org>
To: linux-kernel@vger.kernel.org
Cc: Peter Zijlstra <peterz@infradead.org>,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Shrikanth Hegde <sshegde@linux.ibm.com>,
	Valentin Schneider <vschneid@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>
Subject: [PATCH 4/5] sched/fair: Remove NEXT_BUDDY
Date: Sun,  7 Apr 2024 10:43:18 +0200	[thread overview]
Message-ID: <20240407084319.1462211-5-mingo@kernel.org> (raw)
In-Reply-To: <20240407084319.1462211-1-mingo@kernel.org>

It has been turned off in 2009 and hasn't been enabled since,
15 years ought to be enough to remove it.

Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 kernel/sched/fair.c     | 11 -----------
 kernel/sched/features.h |  7 -------
 2 files changed, 18 deletions(-)

diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 0197ba78b89c..93ea653065f5 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -1901,13 +1901,6 @@ set_next_entity(struct cfs_rq *cfs_rq, struct sched_entity *se)
 static struct sched_entity *
 pick_next_entity(struct cfs_rq *cfs_rq)
 {
-	/*
-	 * Enabling NEXT_BUDDY will affect latency but not fairness.
-	 */
-	if (sched_feat(NEXT_BUDDY) &&
-	    cfs_rq->next && entity_eligible(cfs_rq, cfs_rq->next))
-		return cfs_rq->next;
-
 	return pick_eevdf(cfs_rq);
 }
 
@@ -4671,10 +4664,6 @@ static void check_preempt_wakeup_fair(struct rq *rq, struct task_struct *p, int
 	if (unlikely(throttled_hierarchy(cfs_rq_of(pse))))
 		return;
 
-	if (sched_feat(NEXT_BUDDY) && !(wake_flags & WF_FORK)) {
-		set_next_buddy(pse);
-	}
-
 	/*
 	 * We can come here with TIF_NEED_RESCHED already set from new task
 	 * wake up path.
diff --git a/kernel/sched/features.h b/kernel/sched/features.h
index 143f55df890b..f0df03fe24d8 100644
--- a/kernel/sched/features.h
+++ b/kernel/sched/features.h
@@ -8,13 +8,6 @@ SCHED_FEAT(PLACE_LAG, true)
 SCHED_FEAT(PLACE_DEADLINE_INITIAL, true)
 SCHED_FEAT(RUN_TO_PARITY, true)
 
-/*
- * Prefer to schedule the task we woke last (assuming it failed
- * wakeup-preemption), since its likely going to consume data we
- * touched, increases cache locality.
- */
-SCHED_FEAT(NEXT_BUDDY, false)
-
 /*
  * Consider buddies to be cache hot, decreases the likeliness of a
  * cache buddy being migrated away, increases cache locality.
-- 
2.40.1


  parent reply	other threads:[~2024-04-07  8:43 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-07  8:43 [PATCH 0/5] sched: Split out kernel/sched/fair_balance.c, numa_balancing.c and syscalls.c, plus other updates Ingo Molnar
2024-04-07  8:43 ` [PATCH 1/5] sched: Split out kernel/sched/syscalls.c from kernel/sched/core.c Ingo Molnar
2024-04-07 19:09   ` kernel test robot
2024-05-27 12:05   ` [tip: sched/core] sched/syscalls: " tip-bot2 for Ingo Molnar
2024-04-07  8:43 ` [PATCH 2/5] sched: Split out kernel/sched/fair_balance.c from kernel/sched/fair.c Ingo Molnar
2024-04-07 10:04   ` kernel test robot
2024-04-07 10:15   ` kernel test robot
2024-04-07 20:21   ` kernel test robot
2024-04-07  8:43 ` [PATCH 3/5] sched: Split out kernel/sched/numa_balancing.c " Ingo Molnar
2024-04-07 18:49   ` kernel test robot
2024-04-07  8:43 ` Ingo Molnar [this message]
2024-04-07  8:43 ` [PATCH 5/5] sched/fair: Rename set_next_buddy() to set_next_pick() Ingo Molnar
2024-04-08  9:16   ` Peter Zijlstra
2024-04-09  8:32     ` Ingo Molnar
2024-04-09  9:27       ` Peter Zijlstra

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240407084319.1462211-5-mingo@kernel.org \
    --to=mingo@kernel.org \
    --cc=dietmar.eggemann@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=sshegde@linux.ibm.com \
    --cc=torvalds@linux-foundation.org \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox