* [openeuler:OLK-6.6 1869/2940] drivers/cpufreq/cppc_cpufreq.c:852:26: error: invalid use of undefined type 'struct fb_ctr_pair'
@ 2024-02-04 8:57 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-02-04 8:57 UTC (permalink / raw)
To: kernel, Zeng Heng; +Cc: oe-kbuild-all
tree: https://gitee.com/openeuler/kernel.git OLK-6.6
head: 0570b06ba8090c198595a26f8b1eb221e12ec70c
commit: 12f136b2134d4ded731c3ef23ac08c85b9c0b1fa [1869/2940] cpufreq: CPPC: Keep the target core awake when reading its cpufreq rate
config: arm64-randconfig-004-20240202 (https://download.01.org/0day-ci/archive/20240204/202402041617.THbvDKTe-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240204/202402041617.THbvDKTe-lkp@intel.com/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 <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202402041617.THbvDKTe-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/cpufreq/cppc_cpufreq.c: In function 'cppc_get_perf_ctrs_pair':
>> drivers/cpufreq/cppc_cpufreq.c:852:26: error: invalid use of undefined type 'struct fb_ctr_pair'
852 | int cpu = fb_ctrs->cpu;
| ^~
drivers/cpufreq/cppc_cpufreq.c:855:47: error: invalid use of undefined type 'struct fb_ctr_pair'
855 | ret = cppc_get_perf_ctrs(cpu, &fb_ctrs->fb_ctrs_t0);
| ^~
drivers/cpufreq/cppc_cpufreq.c:861:48: error: invalid use of undefined type 'struct fb_ctr_pair'
861 | return cppc_get_perf_ctrs(cpu, &fb_ctrs->fb_ctrs_t1);
| ^~
drivers/cpufreq/cppc_cpufreq.c: In function 'cppc_cpufreq_get_rate':
>> drivers/cpufreq/cppc_cpufreq.c:866:16: error: variable 'fb_ctrs' has initializer but incomplete type
866 | struct fb_ctr_pair fb_ctrs = { .cpu = cpu, };
| ^~~~~~~~~~~
>> drivers/cpufreq/cppc_cpufreq.c:866:41: error: 'struct fb_ctr_pair' has no member named 'cpu'
866 | struct fb_ctr_pair fb_ctrs = { .cpu = cpu, };
| ^~~
drivers/cpufreq/cppc_cpufreq.c:866:47: warning: excess elements in struct initializer
866 | struct fb_ctr_pair fb_ctrs = { .cpu = cpu, };
| ^~~
drivers/cpufreq/cppc_cpufreq.c:866:47: note: (near initialization for 'fb_ctrs')
>> drivers/cpufreq/cppc_cpufreq.c:866:28: error: storage size of 'fb_ctrs' isn't known
866 | struct fb_ctr_pair fb_ctrs = { .cpu = cpu, };
| ^~~~~~~
drivers/cpufreq/cppc_cpufreq.c:866:28: warning: unused variable 'fb_ctrs' [-Wunused-variable]
vim +852 drivers/cpufreq/cppc_cpufreq.c
848
849 static int cppc_get_perf_ctrs_pair(void *val)
850 {
851 struct fb_ctr_pair *fb_ctrs = val;
> 852 int cpu = fb_ctrs->cpu;
853 int ret;
854
855 ret = cppc_get_perf_ctrs(cpu, &fb_ctrs->fb_ctrs_t0);
856 if (ret)
857 return ret;
858
859 udelay(2); /* 2usec delay between sampling */
860
861 return cppc_get_perf_ctrs(cpu, &fb_ctrs->fb_ctrs_t1);
862 }
863
864 static unsigned int cppc_cpufreq_get_rate(unsigned int cpu)
865 {
> 866 struct fb_ctr_pair fb_ctrs = { .cpu = cpu, };
867 struct cpufreq_policy *policy = cpufreq_cpu_get(cpu);
868 struct cppc_cpudata *cpu_data = policy->driver_data;
869 u64 delivered_perf;
870 int ret;
871
872 cpufreq_cpu_put(policy);
873
874 if (cpu_has_amu_feat(cpu))
875 ret = smp_call_on_cpu(cpu, cppc_get_perf_ctrs_pair,
876 &fb_ctrs, false);
877 else
878 ret = cppc_get_perf_ctrs_pair(&fb_ctrs);
879
880 if (ret)
881 return 0;
882
883 delivered_perf = cppc_perf_from_fbctrs(cpu_data,
884 &fb_ctrs.fb_ctrs_t0,
885 &fb_ctrs.fb_ctrs_t1);
886
887 return cppc_cpufreq_perf_to_khz(cpu_data, delivered_perf);
888 }
889
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-02-04 8:58 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-04 8:57 [openeuler:OLK-6.6 1869/2940] drivers/cpufreq/cppc_cpufreq.c:852:26: error: invalid use of undefined type 'struct fb_ctr_pair' kernel test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.