Content-Type: multipart/mixed; boundary="===============0534214059009215452==" MIME-Version: 1.0 From: kernel test robot To: kbuild-all@lists.01.org Subject: Re: [PATCH] PCI: kirin: Fix kirin960-pcie probe failure issue Date: Wed, 02 Feb 2022 12:00:23 +0800 Message-ID: <202202021149.TJc443Qq-lkp@intel.com> In-Reply-To: <20220201215941.1203155-1-huobean@gmail.com> List-Id: --===============0534214059009215452== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Bean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on helgaas-pci/next] [also build test WARNING on v5.17-rc2 next-20220201] [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/Bean-Huo/PCI-kirin-Fix-kir= in960-pcie-probe-failure-issue/20220202-060120 base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next config: riscv-randconfig-r001-20220130 (https://download.01.org/0day-ci/arc= hive/20220202/202202021149.TJc443Qq-lkp(a)intel.com/config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 6b1e84= 4b69f15bb7dffaf9365cd2b355d2eb7579) 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/91a6cc1deb484e0590261edbf= 304784499ca1784 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Bean-Huo/PCI-kirin-Fix-kirin960-pc= ie-probe-failure-issue/20220202-060120 git checkout 91a6cc1deb484e0590261edbf304784499ca1784 # 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/pci/controller/dwc/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): >> drivers/pci/controller/dwc/pcie-kirin.c:784:13: warning: cast to smaller= integer type 'enum pcie_kirin_phy_type' from 'const void *' [-Wvoid-pointe= r-to-enum-cast] phy_type =3D (enum pcie_kirin_phy_type)of_device_get_match_data(= dev); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~ 1 warning generated. vim +784 drivers/pci/controller/dwc/pcie-kirin.c 770 = 771 static int kirin_pcie_probe(struct platform_device *pdev) 772 { 773 enum pcie_kirin_phy_type phy_type; 774 struct device *dev =3D &pdev->dev; 775 struct kirin_pcie *kirin_pcie; 776 struct dw_pcie *pci; 777 int ret; 778 = 779 if (!dev->of_node) { 780 dev_err(dev, "NULL node\n"); 781 return -EINVAL; 782 } 783 = > 784 phy_type =3D (enum pcie_kirin_phy_type)of_device_get_match_data(dev= ); 785 = 786 kirin_pcie =3D devm_kzalloc(dev, sizeof(struct kirin_pcie), GFP_KER= NEL); 787 if (!kirin_pcie) 788 return -ENOMEM; 789 = 790 pci =3D devm_kzalloc(dev, sizeof(*pci), GFP_KERNEL); 791 if (!pci) 792 return -ENOMEM; 793 = 794 pci->dev =3D dev; 795 pci->ops =3D &kirin_dw_pcie_ops; 796 pci->pp.ops =3D &kirin_pcie_host_ops; 797 kirin_pcie->pci =3D pci; 798 kirin_pcie->type =3D phy_type; 799 = 800 ret =3D kirin_pcie_get_resource(kirin_pcie, pdev); 801 if (ret) 802 return ret; 803 = 804 platform_set_drvdata(pdev, kirin_pcie); 805 = 806 ret =3D kirin_pcie_power_on(pdev, kirin_pcie); 807 if (ret) 808 return ret; 809 = 810 return dw_pcie_host_init(&pci->pp); 811 } 812 = --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org --===============0534214059009215452==--