Content-Type: multipart/mixed; boundary="===============6018421561392950364==" MIME-Version: 1.0 From: kernel test robot To: kbuild-all@lists.01.org Subject: Re: [PATCH] drm/v3d: Fix PM disable depth imbalance in v3d_platform_drm_probe Date: Thu, 06 Jan 2022 06:37:34 +0800 Message-ID: <202201060655.NBwUPRqC-lkp@intel.com> In-Reply-To: <20220105120442.14418-1-linmq006@gmail.com> List-Id: --===============6018421561392950364== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Miaoqian, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on drm/drm-next] [also build test WARNING on linux/master linus/master v5.16-rc8 next-202201= 05] [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] url: https://github.com/0day-ci/linux/commits/Miaoqian-Lin/drm-v3d-Fix-P= M-disable-depth-imbalance-in-v3d_platform_drm_probe/20220105-200602 base: git://anongit.freedesktop.org/drm/drm drm-next config: riscv-randconfig-r013-20220105 (https://download.01.org/0day-ci/arc= hive/20220106/202201060655.NBwUPRqC-lkp(a)intel.com/config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project d5b6e3= 0ed3acad794dd0aec400e617daffc6cc3d) reproduce (this is a W=3D1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/= make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # install riscv cross compiling tool for clang build # apt-get install binutils-riscv64-linux-gnu # https://github.com/0day-ci/linux/commit/9e89d2b210d16b00d43b6cf5a= 8e70495403da480 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Miaoqian-Lin/drm-v3d-Fix-PM-disabl= e-depth-imbalance-in-v3d_platform_drm_probe/20220105-200602 git checkout 9e89d2b210d16b00d43b6cf5a8e70495403da480 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=3D$HOME/0day COMPILER=3Dclang make.cross W=3D= 1 O=3Dbuild_dir ARCH=3Driscv SHELL=3D/bin/bash drivers/gpu/drm/v3d/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): >> drivers/gpu/drm/v3d/v3d_drv.c:303:1: warning: unused label 'pm_disable' = [-Wunused-label] pm_disable: ^~~~~~~~~~~ 1 warning generated. vim +/pm_disable +303 drivers/gpu/drm/v3d/v3d_drv.c 213 = 214 static int v3d_platform_drm_probe(struct platform_device *pdev) 215 { 216 struct device *dev =3D &pdev->dev; 217 struct drm_device *drm; 218 struct v3d_dev *v3d; 219 int ret; 220 u32 mmu_debug; 221 u32 ident1; 222 = 223 v3d =3D devm_drm_dev_alloc(dev, &v3d_drm_driver, struct v3d_dev, dr= m); 224 if (IS_ERR(v3d)) 225 return PTR_ERR(v3d); 226 = 227 drm =3D &v3d->drm; 228 = 229 platform_set_drvdata(pdev, drm); 230 = 231 ret =3D map_regs(v3d, &v3d->hub_regs, "hub"); 232 if (ret) 233 return ret; 234 = 235 ret =3D map_regs(v3d, &v3d->core_regs[0], "core0"); 236 if (ret) 237 return ret; 238 = 239 mmu_debug =3D V3D_READ(V3D_MMU_DEBUG_INFO); 240 dma_set_mask_and_coherent(dev, 241 DMA_BIT_MASK(30 + V3D_GET_FIELD(mmu_debug, V3D_MMU_PA_WIDTH))); 242 v3d->va_width =3D 30 + V3D_GET_FIELD(mmu_debug, V3D_MMU_VA_WIDTH); 243 = 244 ident1 =3D V3D_READ(V3D_HUB_IDENT1); 245 v3d->ver =3D (V3D_GET_FIELD(ident1, V3D_HUB_IDENT1_TVER) * 10 + 246 V3D_GET_FIELD(ident1, V3D_HUB_IDENT1_REV)); 247 v3d->cores =3D V3D_GET_FIELD(ident1, V3D_HUB_IDENT1_NCORES); 248 WARN_ON(v3d->cores > 1); /* multicore not yet implemented */ 249 = 250 v3d->reset =3D devm_reset_control_get_exclusive(dev, NULL); 251 if (IS_ERR(v3d->reset)) { 252 ret =3D PTR_ERR(v3d->reset); 253 = 254 if (ret =3D=3D -EPROBE_DEFER) 255 return ret; 256 = 257 v3d->reset =3D NULL; 258 ret =3D map_regs(v3d, &v3d->bridge_regs, "bridge"); 259 if (ret) { 260 dev_err(dev, 261 "Failed to get reset control or bridge regs\n"); 262 return ret; 263 } 264 } 265 = 266 if (v3d->ver < 41) { 267 ret =3D map_regs(v3d, &v3d->gca_regs, "gca"); 268 if (ret) 269 return ret; 270 } 271 = 272 v3d->mmu_scratch =3D dma_alloc_wc(dev, 4096, &v3d->mmu_scratch_padd= r, 273 GFP_KERNEL | __GFP_NOWARN | __GFP_ZERO); 274 if (!v3d->mmu_scratch) { 275 dev_err(dev, "Failed to allocate MMU scratch page\n"); 276 return -ENOMEM; 277 } 278 = 279 pm_runtime_use_autosuspend(dev); 280 pm_runtime_set_autosuspend_delay(dev, 50); 281 pm_runtime_enable(dev); 282 = 283 ret =3D v3d_gem_init(drm); 284 if (ret) 285 goto dma_free; 286 = 287 ret =3D v3d_irq_init(v3d); 288 if (ret) 289 goto gem_destroy; 290 = 291 ret =3D drm_dev_register(drm, 0); 292 if (ret) 293 goto irq_disable; 294 = 295 return 0; 296 = 297 irq_disable: 298 v3d_irq_disable(v3d); 299 gem_destroy: 300 v3d_gem_destroy(drm); 301 dma_free: 302 dma_free_wc(dev, 4096, v3d->mmu_scratch, v3d->mmu_scratch_paddr); > 303 pm_disable: 304 pm_runtime_disable(dev); 305 return ret; 306 } 307 = --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org --===============6018421561392950364==--