Re: [PATCH v2 5/5] perf: Correct perf sampling with guest VMs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Colton,

kernel test robot noticed the following build warnings:

[auto build test WARNING on perf-tools-next/perf-tools-next]
[also build test WARNING on tip/perf/core perf-tools/perf-tools acme/perf/core linus/master v6.11-rc7 next-20240912]
[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/Colton-Lewis/arm-perf-Drop-unused-functions/20240912-063910
base:   https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next
patch link:    https://lore.kernel.org/r/20240911222433.3415301-6-coltonlewis%40google.com
patch subject: [PATCH v2 5/5] perf: Correct perf sampling with guest VMs
config: x86_64-buildonly-randconfig-005-20240912 (https://download.01.org/0day-ci/archive/20240912/202409122254.PnIe8ulL-lkp@xxxxxxxxx/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240912/202409122254.PnIe8ulL-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202409122254.PnIe8ulL-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

   arch/x86/events/core.c: In function 'perf_arch_misc_flags':
>> arch/x86/events/core.c:2971:22: warning: unused variable 'guest_state' [-Wunused-variable]
    2971 |         unsigned int guest_state = perf_guest_state();
         |                      ^~~~~~~~~~~


vim +/guest_state +2971 arch/x86/events/core.c

8f19518b57cef1 arch/x86/events/core.c           Colton Lewis        2024-09-11  2968  
a2d1490e40282f arch/x86/events/core.c           Colton Lewis        2024-09-11  2969  unsigned long perf_arch_misc_flags(struct pt_regs *regs)
39447b386c846b arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-19  2970  {
1c3430516b0732 arch/x86/events/core.c           Sean Christopherson 2021-11-11 @2971  	unsigned int guest_state = perf_guest_state();
8f19518b57cef1 arch/x86/events/core.c           Colton Lewis        2024-09-11  2972  	unsigned long misc = common_misc_flags(regs);
dcf46b9443ad48 arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-20  2973  
d07bdfd322d307 arch/x86/kernel/cpu/perf_event.c Peter Zijlstra      2012-07-10  2974  	if (user_mode(regs))
dcf46b9443ad48 arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-20  2975  		misc |= PERF_RECORD_MISC_USER;
dcf46b9443ad48 arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-20  2976  	else
dcf46b9443ad48 arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-20  2977  		misc |= PERF_RECORD_MISC_KERNEL;
dcf46b9443ad48 arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-20  2978  
39447b386c846b arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-19  2979  	return misc;
39447b386c846b arch/x86/kernel/cpu/perf_event.c Zhang, Yanmin       2010-04-19  2980  }
b3d9468a8bd218 arch/x86/kernel/cpu/perf_event.c Gleb Natapov        2011-11-10  2981  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux