Re: [PATCH v3 5/5] scsi: ufs: rockchip: initial support for UFS

From: kernel test robot
Date: Wed Oct 09 2024 - 16:01:44 EST


Hi Shawn,

kernel test robot noticed the following build errors:

[auto build test ERROR on jejb-scsi/for-next]
[also build test ERROR on mkp-scsi/for-next robh/for-next linus/master v6.12-rc2 next-20241009]
[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/Shawn-Lin/scsi-ufs-core-Add-UFSHCI_QUIRK_DME_RESET_ENABLE_AFTER_HCE/20241009-042350
base: https://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
patch link: https://lore.kernel.org/r/1728368130-37213-6-git-send-email-shawn.lin%40rock-chips.com
patch subject: [PATCH v3 5/5] scsi: ufs: rockchip: initial support for UFS
config: csky-randconfig-r073-20241010 (https://download.01.org/0day-ci/archive/20241010/202410100321.D89hHCPV-lkp@xxxxxxxxx/config)
compiler: csky-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241010/202410100321.D89hHCPV-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/202410100321.D89hHCPV-lkp@xxxxxxxxx/

All error/warnings (new ones prefixed by >>):

drivers/ufs/host/ufs-rockchip.c: In function 'ufs_rockchip_runtime_suspend':
>> drivers/ufs/host/ufs-rockchip.c:293:16: error: implicit declaration of function 'ufshcd_runtime_suspend'; did you mean 'pm_runtime_suspend'? [-Wimplicit-function-declaration]
293 | return ufshcd_runtime_suspend(dev);
| ^~~~~~~~~~~~~~~~~~~~~~
| pm_runtime_suspend
drivers/ufs/host/ufs-rockchip.c: In function 'ufs_rockchip_runtime_resume':
>> drivers/ufs/host/ufs-rockchip.c:312:16: error: implicit declaration of function 'ufshcd_runtime_resume'; did you mean 'pm_runtime_resume'? [-Wimplicit-function-declaration]
312 | return ufshcd_runtime_resume(dev);
| ^~~~~~~~~~~~~~~~~~~~~
| pm_runtime_resume
drivers/ufs/host/ufs-rockchip.c: In function 'ufs_rockchip_system_suspend':
>> drivers/ufs/host/ufs-rockchip.c:324:16: error: implicit declaration of function 'ufshcd_system_suspend'; did you mean 'ufs_rockchip_system_suspend'? [-Wimplicit-function-declaration]
324 | return ufshcd_system_suspend(dev);
| ^~~~~~~~~~~~~~~~~~~~~
| ufs_rockchip_system_suspend
drivers/ufs/host/ufs-rockchip.c: At top level:
>> drivers/ufs/host/ufs-rockchip.c:315:12: warning: 'ufs_rockchip_system_suspend' defined but not used [-Wunused-function]
315 | static int ufs_rockchip_system_suspend(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/ufs/host/ufs-rockchip.c:296:12: warning: 'ufs_rockchip_runtime_resume' defined but not used [-Wunused-function]
296 | static int ufs_rockchip_runtime_resume(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/ufs/host/ufs-rockchip.c:275:12: warning: 'ufs_rockchip_runtime_suspend' defined but not used [-Wunused-function]
275 | static int ufs_rockchip_runtime_suspend(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~


vim +293 drivers/ufs/host/ufs-rockchip.c

274
> 275 static int ufs_rockchip_runtime_suspend(struct device *dev)
276 {
277 struct ufs_hba *hba = dev_get_drvdata(dev);
278 struct ufs_rockchip_host *host = ufshcd_get_variant(hba);
279 struct generic_pm_domain *genpd = pd_to_genpd(dev->pm_domain);
280
281 clk_disable_unprepare(host->ref_out_clk);
282
283 /*
284 * Shouldn't power down if rpm_lvl is less than level 5.
285 * This flag will be passed down to platform power-domain driver
286 * which has the final decision.
287 */
288 if (hba->rpm_lvl < UFS_PM_LVL_5)
289 genpd->flags |= GENPD_FLAG_RPM_ALWAYS_ON;
290 else
291 genpd->flags &= ~GENPD_FLAG_RPM_ALWAYS_ON;
292
> 293 return ufshcd_runtime_suspend(dev);
294 }
295
> 296 static int ufs_rockchip_runtime_resume(struct device *dev)
297 {
298 struct ufs_hba *hba = dev_get_drvdata(dev);
299 struct ufs_rockchip_host *host = ufshcd_get_variant(hba);
300 int err;
301
302 err = clk_prepare_enable(host->ref_out_clk);
303 if (err) {
304 dev_err(hba->dev, "failed to enable ref out clock %d\n", err);
305 return err;
306 }
307
308 reset_control_assert(host->rst);
309 usleep_range(1, 2);
310 reset_control_deassert(host->rst);
311
> 312 return ufshcd_runtime_resume(dev);
313 }
314
> 315 static int ufs_rockchip_system_suspend(struct device *dev)
316 {
317 struct ufs_hba *hba = dev_get_drvdata(dev);
318 struct ufs_rockchip_host *host = ufshcd_get_variant(hba);
319
320 /* Pass down desired spm_lvl to Firmware */
321 arm_smccc_smc(ROCKCHIP_SIP_SUSPEND_MODE, ROCKCHIP_SLEEP_PD_CONFIG,
322 host->pd_id, hba->spm_lvl < 5 ? 1 : 0, 0, 0, 0, 0, NULL);
323
> 324 return ufshcd_system_suspend(dev);
325 }
326

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