Skip to content

Commit d3f332b

Browse files
paliLorenzo Pieralisi
authored andcommitted
PCI: pci-bridge-emul: Rename PCI_BRIDGE_EMUL_NO_PREFETCHABLE_BAR to PCI_BRIDGE_EMUL_NO_PREFMEM_FORWARD
This flag describe whether PCI bridge supports forwarding of prefetchable memory requests in given range between primary and secondary buses. It does not specify if bridge has support for prefetchable memory BAR (moreover this pci-bridge-emul.c driver does not provide support for BARs). So change name of this flag to be less misleading and add comment. Link: https://lore.kernel.org/r/20220104153529.31647-4-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>
1 parent 64a70f5 commit d3f332b

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

drivers/pci/controller/pci-mvebu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -747,7 +747,7 @@ static int mvebu_pci_bridge_emul_init(struct mvebu_pcie_port *port)
747747
bridge->data = port;
748748
bridge->ops = &mvebu_pci_bridge_emul_ops;
749749

750-
return pci_bridge_emul_init(bridge, PCI_BRIDGE_EMUL_NO_PREFETCHABLE_BAR);
750+
return pci_bridge_emul_init(bridge, PCI_BRIDGE_EMUL_NO_PREFMEM_FORWARD);
751751
}
752752

753753
static inline struct mvebu_pcie *sys_to_pcie(struct pci_sys_data *sys)

drivers/pci/pci-bridge-emul.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ int pci_bridge_emul_init(struct pci_bridge_emul *bridge,
377377
~(BIT(10) << 16);
378378
}
379379

380-
if (flags & PCI_BRIDGE_EMUL_NO_PREFETCHABLE_BAR) {
380+
if (flags & PCI_BRIDGE_EMUL_NO_PREFMEM_FORWARD) {
381381
bridge->pci_regs_behavior[PCI_PREF_MEMORY_BASE / 4].ro = ~0;
382382
bridge->pci_regs_behavior[PCI_PREF_MEMORY_BASE / 4].rw = 0;
383383
}

drivers/pci/pci-bridge-emul.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,11 @@ struct pci_bridge_emul {
120120
};
121121

122122
enum {
123-
PCI_BRIDGE_EMUL_NO_PREFETCHABLE_BAR = BIT(0),
123+
/*
124+
* PCI bridge does not support forwarding of prefetchable memory
125+
* requests between primary and secondary buses.
126+
*/
127+
PCI_BRIDGE_EMUL_NO_PREFMEM_FORWARD = BIT(0),
124128
};
125129

126130
int pci_bridge_emul_init(struct pci_bridge_emul *bridge,

0 commit comments

Comments
 (0)