From: kernel test robot <lkp@intel.com>
To: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: oe-kbuild-all@lists.linux.dev, linux-pci@vger.kernel.org,
"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
"Fei Shao" <fshao@chromium.org>,
"Manivannan Sadhasivam" <manivannan.sadhasivam@linaro.org>
Subject: [pci:controller/mediatek 2/2] drivers/pci/controller/pcie-mediatek-gen3.c:898:14: error: implicit declaration of function 'of_property_read_u31'; did you mean 'of_property_read_u32'?
Date: Thu, 7 Nov 2024 02:56:31 +0800 [thread overview]
Message-ID: <202411070226.YqavKDUD-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/pci/pci.git controller/mediatek
head: 2bee4c1a6fc0408242aedca80a102ef50c0dfbe5
commit: 2bee4c1a6fc0408242aedca80a102ef50c0dfbe5 [2/2] PCI: mediatek-gen3: Add support for restricting link width
config: alpha-allyesconfig (https://download.01.org/0day-ci/archive/20241107/202411070226.YqavKDUD-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241107/202411070226.YqavKDUD-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202411070226.YqavKDUD-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/pci/controller/pcie-mediatek-gen3.c: In function 'mtk_pcie_parse_port':
>> drivers/pci/controller/pcie-mediatek-gen3.c:898:14: error: implicit declaration of function 'of_property_read_u31'; did you mean 'of_property_read_u32'? [-Wimplicit-function-declaration]
898 | ret = of_property_read_u31(dev->of_node, "num-lanes", &num_lanes);
| ^~~~~~~~~~~~~~~~~~~~
| of_property_read_u32
vim +898 drivers/pci/controller/pcie-mediatek-gen3.c
845
846 static int mtk_pcie_parse_port(struct mtk_gen3_pcie *pcie)
847 {
848 int i, ret, num_resets = pcie->soc->phy_resets.num_resets;
849 struct device *dev = pcie->dev;
850 struct platform_device *pdev = to_platform_device(dev);
851 struct resource *regs;
852 u32 num_lanes;
853
854 regs = platform_get_resource_byname(pdev, IORESOURCE_MEM, "pcie-mac");
855 if (!regs)
856 return -EINVAL;
857 pcie->base = devm_ioremap_resource(dev, regs);
858 if (IS_ERR(pcie->base)) {
859 dev_err(dev, "failed to map register base\n");
860 return PTR_ERR(pcie->base);
861 }
862
863 pcie->reg_base = regs->start;
864
865 for (i = 0; i < num_resets; i++)
866 pcie->phy_resets[i].id = pcie->soc->phy_resets.id[i];
867
868 ret = devm_reset_control_bulk_get_optional_shared(dev, num_resets, pcie->phy_resets);
869 if (ret) {
870 dev_err(dev, "failed to get PHY bulk reset\n");
871 return ret;
872 }
873
874 pcie->mac_reset = devm_reset_control_get_optional_exclusive(dev, "mac");
875 if (IS_ERR(pcie->mac_reset)) {
876 ret = PTR_ERR(pcie->mac_reset);
877 if (ret != -EPROBE_DEFER)
878 dev_err(dev, "failed to get MAC reset\n");
879
880 return ret;
881 }
882
883 pcie->phy = devm_phy_optional_get(dev, "pcie-phy");
884 if (IS_ERR(pcie->phy)) {
885 ret = PTR_ERR(pcie->phy);
886 if (ret != -EPROBE_DEFER)
887 dev_err(dev, "failed to get PHY\n");
888
889 return ret;
890 }
891
892 pcie->num_clks = devm_clk_bulk_get_all(dev, &pcie->clks);
893 if (pcie->num_clks < 0) {
894 dev_err(dev, "failed to get clocks\n");
895 return pcie->num_clks;
896 }
897
> 898 ret = of_property_read_u31(dev->of_node, "num-lanes", &num_lanes);
899 if (ret == 0) {
900 if (num_lanes == 0 || num_lanes > 16 || (num_lanes != 1 && num_lanes % 2))
901 dev_warn(dev, "invalid num-lanes, using controller defaults\n");
902 else
903 pcie->num_lanes = num_lanes;
904 }
905
906 return 0;
907 }
908
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2024-11-06 18:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-06 18:56 kernel test robot [this message]
2024-11-06 19:59 ` [pci:controller/mediatek 2/2] drivers/pci/controller/pcie-mediatek-gen3.c:898:14: error: implicit declaration of function 'of_property_read_u31'; did you mean 'of_property_read_u32'? Krzysztof Wilczyński
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202411070226.YqavKDUD-lkp@intel.com \
--to=lkp@intel.com \
--cc=angelogioacchino.delregno@collabora.com \
--cc=fshao@chromium.org \
--cc=kwilczynski@kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--cc=oe-kbuild-all@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox