PCI: mvebu: Remove duplicate nports assignment
authorPali Rohár <pali@kernel.org>
Tue, 4 Jan 2022 15:35:24 +0000 (16:35 +0100)
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Thu, 3 Feb 2022 10:54:05 +0000 (10:54 +0000)
Member pcie->nports is initialized to correct value before the previous
for-loop. There is not need to initialize it more times.

Link: https://lore.kernel.org/r/20220104153529.31647-7-pali@kernel.org
Signed-off-by: Pali Rohár <pali@kernel.org>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Acked-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
drivers/pci/controller/pci-mvebu.c

index 7156ddc..a7eaa58 100644 (file)
@@ -1332,8 +1332,6 @@ static int mvebu_pcie_probe(struct platform_device *pdev)
                mvebu_pcie_set_local_dev_nr(port, 0);
        }
 
-       pcie->nports = i;
-
        bridge->sysdata = pcie;
        bridge->ops = &mvebu_pcie_ops;
        bridge->align_resource = mvebu_pcie_align_resource;