* Re: [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table
[not found] <20230314103357.26010-14-lukasz.luba@arm.com>
@ 2023-03-15 11:32 ` kernel test robot
2023-03-21 11:30 ` Lukasz Luba
0 siblings, 1 reply; 2+ messages in thread
From: kernel test robot @ 2023-03-15 11:32 UTC (permalink / raw)
To: Lukasz Luba, linux-kernel, linux-pm, rafael
Cc: llvm, oe-kbuild-all, lukasz.luba, dietmar.eggemann, rui.zhang,
amit.kucheria, amit.kachhap, daniel.lezcano, viresh.kumar,
len.brown, pavel, Pierre.Gondois, ionela.voinescu, rostedt,
mhiramat
Hi Lukasz,
I love your patch! Perhaps something to improve:
[auto build test WARNING on rafael-pm/linux-next]
[also build test WARNING on rafael-pm/thermal linus/master pavel-leds/for-next v6.3-rc2 next-20230315]
[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/Lukasz-Luba/PM-EM-Refactor-em_cpufreq_update_efficiencies-arguments/20230314-184448
base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next
patch link: https://lore.kernel.org/r/20230314103357.26010-14-lukasz.luba%40arm.com
patch subject: [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table
config: x86_64-randconfig-a003 (https://download.01.org/0day-ci/archive/20230315/202303151927.WD6O0PWN-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/ce3aad5db08006a2a6b6d52f9c26b11448cd8bb4
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Lukasz-Luba/PM-EM-Refactor-em_cpufreq_update_efficiencies-arguments/20230314-184448
git checkout ce3aad5db08006a2a6b6d52f9c26b11448cd8bb4
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/thermal/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303151927.WD6O0PWN-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/thermal/cpufreq_cooling.c:381:24: warning: unused variable 'table' [-Wunused-variable]
struct em_perf_state *table;
^
1 warning generated.
vim +/table +381 drivers/thermal/cpufreq_cooling.c
376
377 static unsigned int get_state_freq(struct cpufreq_cooling_device *cpufreq_cdev,
378 unsigned long state)
379 {
380 struct cpufreq_policy *policy;
> 381 struct em_perf_state *table;
382 unsigned long idx;
383
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table
2023-03-15 11:32 ` [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table kernel test robot
@ 2023-03-21 11:30 ` Lukasz Luba
0 siblings, 0 replies; 2+ messages in thread
From: Lukasz Luba @ 2023-03-21 11:30 UTC (permalink / raw)
To: rafael
Cc: llvm, oe-kbuild-all, linux-kernel, dietmar.eggemann, rui.zhang,
amit.kucheria, amit.kachhap, daniel.lezcano, viresh.kumar,
len.brown, pavel, Pierre.Gondois, ionela.voinescu, rostedt,
mhiramat, linux-pm, kernel test robot
Hi Rafael,
On 3/15/23 11:32, kernel test robot wrote:
> Hi Lukasz,
>
> I love your patch! Perhaps something to improve:
>
> [auto build test WARNING on rafael-pm/linux-next]
> [also build test WARNING on rafael-pm/thermal linus/master pavel-leds/for-next v6.3-rc2 next-20230315]
> [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/Lukasz-Luba/PM-EM-Refactor-em_cpufreq_update_efficiencies-arguments/20230314-184448
> base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next
> patch link: https://lore.kernel.org/r/20230314103357.26010-14-lukasz.luba%40arm.com
> patch subject: [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table
> config: x86_64-randconfig-a003 (https://download.01.org/0day-ci/archive/20230315/202303151927.WD6O0PWN-lkp@intel.com/config)
> compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
> reproduce (this is a W=1 build):
> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> # https://github.com/intel-lab-lkp/linux/commit/ce3aad5db08006a2a6b6d52f9c26b11448cd8bb4
> git remote add linux-review https://github.com/intel-lab-lkp/linux
> git fetch --no-tags linux-review Lukasz-Luba/PM-EM-Refactor-em_cpufreq_update_efficiencies-arguments/20230314-184448
> git checkout ce3aad5db08006a2a6b6d52f9c26b11448cd8bb4
> # save the config file
> mkdir build_dir && cp config build_dir/.config
> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 olddefconfig
> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/thermal/
>
> If you fix the issue, kindly add following tag where applicable
> | Reported-by: kernel test robot <lkp@intel.com>
> | Link: https://lore.kernel.org/oe-kbuild-all/202303151927.WD6O0PWN-lkp@intel.com/
>
> All warnings (new ones prefixed by >>):
>
>>> drivers/thermal/cpufreq_cooling.c:381:24: warning: unused variable 'table' [-Wunused-variable]
> struct em_perf_state *table;
> ^
> 1 warning generated.
>
>
> vim +/table +381 drivers/thermal/cpufreq_cooling.c
>
> 376
> 377 static unsigned int get_state_freq(struct cpufreq_cooling_device *cpufreq_cdev,
> 378 unsigned long state)
> 379 {
> 380 struct cpufreq_policy *policy;
> > 381 struct em_perf_state *table;
> 382 unsigned long idx;
> 383
>
I'll move that variable into the below section which has the #ifdef,
so it won't complain when there isn't IPA config set.
Thus, the change for this get_state_freq() in v2 would be like:
------------------------------8<----------------------
#ifdef CONFIG_THERMAL_GOV_POWER_ALLOCATOR
/* Use the Energy Model table if available */
if (cpufreq_cdev->em) {
+ struct em_perf_state *table;
+ table = cpufreq_cdev->em->default_table->state;
idx = cpufreq_cdev->max_level - state;
- return cpufreq_cdev->em->table[idx].frequency;
+ return table[idx].frequency;
}
#endif
------------------->8---------------------------------
BTW, I might refactor this cpufreq_cooling.c file later,
since there is a lot of this #ifdef sections spread around...
But that would be after OSPM in Ancona.
Regards,
Lukasz
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-03-21 11:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20230314103357.26010-14-lukasz.luba@arm.com>
2023-03-15 11:32 ` [PATCH 13/17] PM: EM: Refactor struct em_perf_domain and add default_table kernel test robot
2023-03-21 11:30 ` Lukasz Luba
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).