thermal core: add option to run PM_POST_SUSPEND asynchronously
PATCH RESEND 1/1 thermal core: add option to run PM_POST_SUSPEND asynchronously
Some thermal zones are bus connected and slow to resume, thus delaying actions which depend on completion of PM_POST_SUSPEND. Add optional execution path to resume thermal zones on the system unbounded workqueue.
--- drivers/thermal/Kconfig | 11 +++++++ drivers/thermal/thermal_core.c | 58 ++++++++++++++++++++++++++++++---- 2 files changed, 62 insertions(+), 7 deletions(-)
drivers/thermal/Kconfig +11 -0
@@ -91,6 +91,17 @@ config THERMAL_WRITABLE_TRIPS Say 'Y' here if you would like to allow userspace tools to change trip temperatures. +config THERMAL_ASYNC_RESUME + bool "Thermal async init zones on system resume" + default n + help + Re-initialize thermal zones asynchronously on system resume. + Thermal zone sensors may be attached on slow buses, impacting + the duration of PM_POST_SUSPEND. If that is a concern enable + this switch. + + If in doubt, say N. + choice prompt "Default Thermal governor" default THERMAL_DEFAULT_GOV_STEP_WISE
drivers/thermal/thermal_core.c +51 -7
95 lines not on this page · raw message
Signature · 1 line
2.41.0.694.ge786442a9b-goog
kernel test robot
build botkernel test robot noticed the following build warnings:
Hi Radu,
kernel test robot noticed the following build warnings:
[auto build test WARNING on rafael-pm/thermal]
[also build test WARNING on linus/master v6.7-rc1 next-20231117] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Radu-Solea/thermal-core-add-option-to-run-PM_POST_SUSPEND-asynchronously/20231117-063150 base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git thermal patch link: https://lore.kernel.org/r/20231116222842.2121193-1-radusolea%40google.com patch subject: [PATCH RESEND] thermal core: add option to run PM_POST_SUSPEND asynchronously config: csky-randconfig-r111-20231118 (https://download.01.org/0day-ci/archive/20231118/[email protected]/config) compiler: csky-linux-gcc (GCC) 13.2.0 reproduce: (https://download.01.org/0day-ci/archive/20231118/[email protected]/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
sparse warnings: (new ones prefixed by >>)
>> drivers/thermal/thermal_core.c:49:20: sparse: sparse: symbol 'resume_thermal_zones_wk' was not declared. Should it be static?
drivers/thermal/thermal_core.c: note: in included file (through include/linux/rculist.h, include/linux/pid.h, include/linux/sched.h, ...):
include/linux/list.h:83:21: sparse: sparse: self-comparison always evaluates to true
include/linux/list.h:83:21: sparse: sparse: self-comparison always evaluates to true
include/linux/list.h:83:21: sparse: sparse: self-comparison always evaluates to true
include/linux/list.h:83:21: sparse: sparse: self-comparison always evaluates to true
include/linux/list.h:83:21: sparse: sparse: self-comparison always evaluates to true
vim +/resume_thermal_zones_wk +49 drivers/thermal/thermal_core.c
47
48 #ifdef CONFIG_THERMAL_ASYNC_RESUME
> 49 struct work_struct *resume_thermal_zones_wk;
50 #endif /* CONFIG_THERMAL_ASYNC_RESUME */
51 Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki