linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [linux-next:master 1761/1915] drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c:315:17: sparse: sparse: incompatible types in conditional expression (different base types):
@ 2023-03-08 13:18 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-03-08 13:18 UTC (permalink / raw)
  To: Lijo Lazar
  Cc: oe-kbuild-all, Linux Memory Management List, Alex Deucher, Hawking Zhang

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   fc31900c948610e7b5c2f15fb7795832c8325327
commit: 511a95552ec878fc59a294652ebbf73a0e8e0c76 [1761/1915] drm/amd/pm: Add SMU 13.0.6 support
config: alpha-randconfig-s033-20230305 (https://download.01.org/0day-ci/archive/20230308/202303082135.NjdX1Bij-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 12.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.4-39-gce1a6720-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=511a95552ec878fc59a294652ebbf73a0e8e0c76
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 511a95552ec878fc59a294652ebbf73a0e8e0c76
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=alpha olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=alpha SHELL=/bin/bash drivers/gpu/drm/

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/202303082135.NjdX1Bij-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
   drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c: note: in included file (through drivers/gpu/drm/amd/amdgpu/../amdgpu/amdgpu_virt.h, drivers/gpu/drm/amd/amdgpu/../amdgpu/amdgpu.h):
   drivers/gpu/drm/amd/amdgpu/../amdgpu/amdgv_sriovmsg.h:315:49: sparse: sparse: static assertion failed: "amd_sriov_msg_vf2pf_info must be 1 KB"
   drivers/gpu/drm/amd/amdgpu/../amdgpu/amdgv_sriovmsg.h:319:49: sparse: sparse: static assertion failed: "amd_sriov_msg_pf2vf_info must be 1 KB"
>> drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c:315:17: sparse: sparse: incompatible types in conditional expression (different base types):
>> drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c:315:17: sparse:    void
>> drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c:315:17: sparse:    int

vim +315 drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c

   296	
   297	static int smu_v13_0_6_get_metrics_table(struct smu_context *smu,
   298						 void *metrics_table, bool bypass_cache)
   299	{
   300		struct smu_table_context *smu_table = &smu->smu_table;
   301		uint32_t table_size = smu_table->tables[SMU_TABLE_SMU_METRICS].size;
   302		struct smu_table *table = &smu_table->driver_table;
   303		int ret;
   304	
   305		if (bypass_cache || !smu_table->metrics_time ||
   306		    time_after(jiffies,
   307			       smu_table->metrics_time + msecs_to_jiffies(1))) {
   308			ret = smu_cmn_send_smc_msg(smu, SMU_MSG_GetMetricsTable, NULL);
   309			if (ret) {
   310				dev_info(smu->adev->dev,
   311					 "Failed to export SMU metrics table!\n");
   312				return ret;
   313			}
   314	
 > 315			amdgpu_asic_invalidate_hdp(smu->adev, NULL);
   316			memcpy(smu_table->metrics_table, table->cpu_addr, table_size);
   317	
   318			smu_table->metrics_time = jiffies;
   319		}
   320	
   321		if (metrics_table)
   322			memcpy(metrics_table, smu_table->metrics_table, table_size);
   323	
   324		return 0;
   325	}
   326	

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


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

only message in thread, other threads:[~2023-03-08 13:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-08 13:18 [linux-next:master 1761/1915] drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_6_ppt.c:315:17: sparse: sparse: incompatible types in conditional expression (different base types): 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