[PATCH -next] drm/amd/pm: remove unused variable

kernel test robot lkp at intel.com
Mon Nov 2 17:23:36 UTC 2020


Hi Zou,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on next-20201102]

url:    https://github.com/0day-ci/linux/commits/Zou-Wei/drm-amd-pm-remove-unused-variable/20201102-195853
base:    b49976d8ef6448e86a7fda6a86f64867942b442d
config: x86_64-randconfig-a004-20201102 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project cc91554ebb66e8c9a4b8c67ca2f1343eaac10cf6)
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
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        # https://github.com/0day-ci/linux/commit/4a14c85aff468b2d26c02415991b440b0b56fc75
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Zou-Wei/drm-amd-pm-remove-unused-variable/20201102-195853
        git checkout 4a14c85aff468b2d26c02415991b440b0b56fc75
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All errors (new ones prefixed by >>):

>> drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu11/vangogh_ppt.c:402:3: error: use of undeclared identifier 'ret'
                   ret = vangogh_get_smu_metrics_data(smu,
                   ^
   1 error generated.

vim +/ret +402 drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu11/vangogh_ppt.c

271ab489f755245 Xiaojian Du 2020-10-26  392  
271ab489f755245 Xiaojian Du 2020-10-26  393  static int vangogh_get_current_activity_percent(struct smu_context *smu,
271ab489f755245 Xiaojian Du 2020-10-26  394  					       enum amd_pp_sensors sensor,
271ab489f755245 Xiaojian Du 2020-10-26  395  					       uint32_t *value)
271ab489f755245 Xiaojian Du 2020-10-26  396  {
271ab489f755245 Xiaojian Du 2020-10-26  397  	if (!value)
271ab489f755245 Xiaojian Du 2020-10-26  398  		return -EINVAL;
271ab489f755245 Xiaojian Du 2020-10-26  399  
271ab489f755245 Xiaojian Du 2020-10-26  400  	switch (sensor) {
271ab489f755245 Xiaojian Du 2020-10-26  401  	case AMDGPU_PP_SENSOR_GPU_LOAD:
271ab489f755245 Xiaojian Du 2020-10-26 @402  		ret = vangogh_get_smu_metrics_data(smu,
271ab489f755245 Xiaojian Du 2020-10-26  403  						  METRICS_AVERAGE_GFXACTIVITY,
271ab489f755245 Xiaojian Du 2020-10-26  404  						  value);
271ab489f755245 Xiaojian Du 2020-10-26  405  		break;
271ab489f755245 Xiaojian Du 2020-10-26  406  	default:
271ab489f755245 Xiaojian Du 2020-10-26  407  		dev_err(smu->adev->dev, "Invalid sensor for retrieving clock activity\n");
271ab489f755245 Xiaojian Du 2020-10-26  408  		return -EINVAL;
271ab489f755245 Xiaojian Du 2020-10-26  409  	}
271ab489f755245 Xiaojian Du 2020-10-26  410  
271ab489f755245 Xiaojian Du 2020-10-26  411  	return 0;
271ab489f755245 Xiaojian Du 2020-10-26  412  }
271ab489f755245 Xiaojian Du 2020-10-26  413  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 37751 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/amd-gfx/attachments/20201103/0c9538de/attachment-0001.gz>


More information about the amd-gfx mailing list