mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* arch/x86/events/rapl.c:540:59: sparse: sparse: Using plain integer as NULL pointer
@ 2022-01-25  7:56 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2022-01-25  7:56 UTC (permalink / raw)
  To: Stephane Eranian; +Cc: kbuild-all, linux-kernel, Peter Zijlstra

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   dd81e1c7d5fb126e5fbc5c9e334d7b3ec29a16a0
commit: 0036fb00a756a2f6e360d44e2e3d2200a8afbc9b perf/x86/rapl: fix AMD event handling
date:   7 days ago
config: i386-randconfig-s001-20220124 (https://download.01.org/0day-ci/archive/20220125/202201251514.ZEiF0Q7N-lkp@intel.com/config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.4-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0036fb00a756a2f6e360d44e2e3d2200a8afbc9b
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 0036fb00a756a2f6e360d44e2e3d2200a8afbc9b
        # save the config file to linux build tree
        mkdir build_dir
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash arch/x86/events/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


sparse warnings: (new ones prefixed by >>)
>> arch/x86/events/rapl.c:540:59: sparse: sparse: Using plain integer as NULL pointer
   arch/x86/events/rapl.c:542:59: sparse: sparse: Using plain integer as NULL pointer
   arch/x86/events/rapl.c:543:59: sparse: sparse: Using plain integer as NULL pointer
   arch/x86/events/rapl.c:544:59: sparse: sparse: Using plain integer as NULL pointer

vim +540 arch/x86/events/rapl.c

   533	
   534	/*
   535	 * Force to PERF_RAPL_MAX size due to:
   536	 * - perf_msr_probe(PERF_RAPL_MAX)
   537	 * - want to use same event codes across both architectures
   538	 */
   539	static struct perf_msr amd_rapl_msrs[] = {
 > 540		[PERF_RAPL_PP0]  = { 0, &rapl_events_cores_group, 0, false, 0 },
   541		[PERF_RAPL_PKG]  = { MSR_AMD_PKG_ENERGY_STATUS,  &rapl_events_pkg_group,   test_msr, false, RAPL_MSR_MASK },
   542		[PERF_RAPL_RAM]  = { 0, &rapl_events_ram_group,   0, false, 0 },
   543		[PERF_RAPL_PP1]  = { 0, &rapl_events_gpu_group,   0, false, 0 },
   544		[PERF_RAPL_PSYS] = { 0, &rapl_events_psys_group,  0, false, 0 },
   545	};
   546	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-01-25  8:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-25  7:56 arch/x86/events/rapl.c:540:59: sparse: sparse: Using plain integer as NULL pointer kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome