]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
pci: dw_mvebu: Use dev_read_addr_x APIs
authorPeng Fan <peng.fan@nxp.com>
Tue, 26 May 2026 08:09:11 +0000 (16:09 +0800)
committerNeil Armstrong <neil.armstrong@linaro.org>
Wed, 1 Jul 2026 09:42:52 +0000 (11:42 +0200)
Use dev_read_addr_x APIs which support both live device tree and flat DT
backends, avoiding direct dependency on devfdt_* helpers.

No functional changes.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Reviewed-by: Stefan Roese <stefan.roese@mailbox.org>
Link: https://patch.msgid.link/20260526-devfdt-pci-v1-3-ed7f31d73938@nxp.com
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
drivers/pci/pcie_dw_mvebu.c

index 43b919175c9255de3cb7415ce66ee0c9c6686569..5a177478afc7be7a195b93fb50c8d6b9ba6b55a1 100644 (file)
@@ -565,13 +565,12 @@ static int pcie_dw_mvebu_of_to_plat(struct udevice *dev)
        struct pcie_dw_mvebu *pcie = dev_get_priv(dev);
 
        /* Get the controller base address */
-       pcie->ctrl_base = devfdt_get_addr_index_ptr(dev, 0);
+       pcie->ctrl_base = dev_read_addr_index_ptr(dev, 0);
        if (!pcie->ctrl_base)
                return -EINVAL;
 
        /* Get the config space base address and size */
-       pcie->cfg_base = devfdt_get_addr_size_index_ptr(dev, 1,
-                                                       &pcie->cfg_size);
+       pcie->cfg_base = dev_read_addr_size_index_ptr(dev, 1, &pcie->cfg_size);
        if (!pcie->cfg_base)
                return -EINVAL;