linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] cpuidle: Handle TIF_NR_POLLING on behalf of polling idle states v2
@ 2024-12-06 13:04 Frederic Weisbecker
  2024-12-06 13:04 ` [PATCH 1/5] cpuidle: Remove unnecessary current_clr_polling_and_test() from haltpoll Frederic Weisbecker
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Frederic Weisbecker @ 2024-12-06 13:04 UTC (permalink / raw)
  To: LKML
  Cc: Frederic Weisbecker, Rafael J . Wysocki, Daniel Lezcano, linux-pm,
	Thomas Gleixner, Ingo Molnar, Borislav Petkov, Dave Hansen,
	Peter Zijlstra

The TIF_NR_POLLING handling against TIF_NEED_RESCHED polling/monitoring
idle states (mwait and also software polling) is a bit messy, with quite
some wasted cycles spent on useless atomic operations. This tries to
consolidate this state handling from the cpuidle core.

Changes since v1:

* Drop two x86 applied patches
* s/CPUIDLE_FLAG_POLLING_HARD/CPUIDLE_FLAG_MWAIT (Rafael)
* Fix confusion between polling and monitoring on comments (Rafael)
* Remove call_cpuidle_s2idle() (Rafael)

Frederic Weisbecker (3):
  cpuidle: Remove unnecessary current_clr_polling_and_test() from
    haltpoll
  cpuidle: Remove call_cpuidle_s2idle()
  cpuidle: Handle TIF_NR_POLLING on behalf of software polling idle
    states

Peter Zijlstra (2):
  cpuidle: Introduce CPUIDLE_FLAG_MWAIT
  cpuidle: Handle TIF_NR_POLLING on behalf of CPUIDLE_FLAG_MWAIT states

 arch/x86/include/asm/mwait.h       |  3 +-
 drivers/acpi/processor_idle.c      |  3 ++
 drivers/cpuidle/cpuidle-haltpoll.c |  3 --
 drivers/cpuidle/cpuidle-powernv.c  | 10 ------
 drivers/cpuidle/cpuidle-pseries.c  | 11 -------
 drivers/cpuidle/cpuidle.c          | 22 ++++++++++++-
 drivers/cpuidle/poll_state.c       | 30 +++++++----------
 drivers/idle/intel_idle.c          |  5 ++-
 include/linux/cpuidle.h            |  1 +
 include/linux/sched/idle.h         |  7 +++-
 kernel/sched/idle.c                | 53 +++++++++---------------------
 11 files changed, 63 insertions(+), 85 deletions(-)

-- 
2.46.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-12-18 14:04 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-06 13:04 [PATCH 0/5] cpuidle: Handle TIF_NR_POLLING on behalf of polling idle states v2 Frederic Weisbecker
2024-12-06 13:04 ` [PATCH 1/5] cpuidle: Remove unnecessary current_clr_polling_and_test() from haltpoll Frederic Weisbecker
2024-12-06 13:04 ` [PATCH 2/5] cpuidle: Introduce CPUIDLE_FLAG_MWAIT Frederic Weisbecker
2024-12-10 14:03   ` Peter Zijlstra
2024-12-06 13:04 ` [PATCH 3/5] cpuidle: Handle TIF_NR_POLLING on behalf of CPUIDLE_FLAG_MWAIT states Frederic Weisbecker
2024-12-10 14:03   ` Peter Zijlstra
2024-12-18 13:24   ` Rafael J. Wysocki
2024-12-18 14:04     ` Frederic Weisbecker
2024-12-06 13:04 ` [PATCH 4/5] cpuidle: Remove call_cpuidle_s2idle() Frederic Weisbecker
2024-12-06 13:04 ` [PATCH 5/5] cpuidle: Handle TIF_NR_POLLING on behalf of software polling idle states Frederic Weisbecker

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).