OSDN Git Service

intel_idle: refactor state->enter manipulation into its own function
authorArjan van de Ven <arjan@linux.intel.com>
Mon, 5 Jun 2023 15:47:13 +0000 (15:47 +0000)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 12 Jun 2023 18:07:22 +0000 (20:07 +0200)
commit4622ba923e55e12cb76081c8865b01fcb383a9d8
tree50b83b18d462888f75d3f2ec64fd0cb8c8cc531c
parent858fd168a95c5b9669aac8db6c14a9aeab446375
intel_idle: refactor state->enter manipulation into its own function

Since the 6.4 kernel, the logic for updating a state's enter method
based on "environmental conditions" (command line options, cpu sidechannel
workarounds etc etc) has gotten pretty complex.
This patch refactors this into a seperate small, self contained function
(no behavior changes) for improved readability and to make future
changes to this logic easier to do and understand.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/idle/intel_idle.c