[radeon-alex:drm-next-4.19-wip 101/128] drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/vega12_hwmgr.c:504 vega12_get_dpm_frequency_by_index() error: uninitialized symbol 'result'.

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

 



tree:   git://people.freedesktop.org/~agd5f/linux.git drm-next-4.19-wip
head:   73b1f7132d9ad442b24d70d8769a4642302d6b49
commit: ce7577a2194b58bf7faf303612a24b7cd5210afc [101/128] drm/amdgpu/pp: split out common smumgr smu9 code

smatch warnings:
drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/vega12_hwmgr.c:504 vega12_get_dpm_frequency_by_index() error: uninitialized symbol 'result'.

git remote add radeon-alex git://people.freedesktop.org/~agd5f/linux.git
git remote update radeon-alex
git checkout ce7577a2194b58bf7faf303612a24b7cd5210afc
vim +/result +504 drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/vega12_hwmgr.c

7436854e Kenneth Feng 2018-03-20  487  
7436854e Kenneth Feng 2018-03-20  488  static int vega12_get_dpm_frequency_by_index(struct pp_hwmgr *hwmgr,
7436854e Kenneth Feng 2018-03-20  489  		PPCLK_e clkID, uint32_t index, uint32_t *clock)
7436854e Kenneth Feng 2018-03-20  490  {
7436854e Kenneth Feng 2018-03-20  491  	int result;
7436854e Kenneth Feng 2018-03-20  492  
7436854e Kenneth Feng 2018-03-20  493  	/*
7436854e Kenneth Feng 2018-03-20  494  	 *SMU expects the Clock ID to be in the top 16 bits.
7436854e Kenneth Feng 2018-03-20  495  	 *Lower 16 bits specify the level
7436854e Kenneth Feng 2018-03-20  496  	 */
7436854e Kenneth Feng 2018-03-20  497  	PP_ASSERT_WITH_CODE(smum_send_msg_to_smc_with_parameter(hwmgr,
7436854e Kenneth Feng 2018-03-20  498  		PPSMC_MSG_GetDpmFreqByIndex, (clkID << 16 | index)) == 0,
7436854e Kenneth Feng 2018-03-20  499  		"[GetDpmFrequencyByIndex] Failed to get dpm frequency from SMU!",
7436854e Kenneth Feng 2018-03-20  500  		return -EINVAL);
7436854e Kenneth Feng 2018-03-20  501  
ce7577a2 Alex Deucher 2018-07-12  502  	*clock = smum_get_argument(hwmgr);
7436854e Kenneth Feng 2018-03-20  503  
7436854e Kenneth Feng 2018-03-20 @504  	return result;
                                        ^^^^^^^^^^^^^
Should just be return 0;

7436854e Kenneth Feng 2018-03-20  505  }
7436854e Kenneth Feng 2018-03-20  506  

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux