[PATCH] PCI: remove unused resource assignment in pci_read_bridge_bases()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This cleanup removes the resource assignment in pci_read_bridge_bases()
since it has taken care by pci_alloc_child_bus() when allocating the bus:

       /* Set up default resource pointers and names.. */
       for (i = 0; i < PCI_BRIDGE_RES_NUM; i++) {
               child->resource[i] = &bridge->resource[PCI_BRIDGE_RESOURCES+i];
               child->resource[i]->name = child->name;
       }

Signed-off-by: Yu Zhao <yu.zhao@xxxxxxxxx>

---
drivers/pci/probe.c |    3 ---
1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 0647bd3..ae0ce6d 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -364,9 +364,6 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child)
			child->resource[i] = child->parent->resource[i - 3];
	}

-	for(i=0; i<3; i++)
-		child->resource[i] = &dev->resource[PCI_BRIDGE_RESOURCES+i];
-
	res = child->resource[0];
	pci_read_config_byte(dev, PCI_IO_BASE, &io_base_lo);
	pci_read_config_byte(dev, PCI_IO_LIMIT, &io_limit_lo);
--
1.5.6.4

--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux