Skip to content

Commit a2fa5f9

Browse files
floatiouskwilczynski
authored andcommitted
PCI: keystone: Specify correct alignment requirement
The support for a specific iATU alignment was added in commit 2a9a801 ("PCI: endpoint: Add support to specify alignment for buffers allocated to BARs"). This commit specifically mentions both that the alignment by each DWC based EP driver should match CX_ATU_MIN_REGION_SIZE, and that AM65x specifically has a 64 KB alignment. This also matches the CX_ATU_MIN_REGION_SIZE value specified in the section "12.2.2.4.7 PCIe Subsystem Address Translation" of the Technical Reference Manual (TRM) for AM65x: https://www.ti.com/lit/ug/spruid7e/spruid7e.pdf This higher value, 1 MB, was obviously an ugly hack used to be able to handle Resizable BARs which have a minimum size of 1 MB. Now when we actually have support for Resizable BARs, let's configure the iATU alignment requirement to the actual requirement. (BARs described as Resizable will still get aligned to 1 MB.) Cc: [email protected] # Depends on PCI endpoint Resizable BARs series Fixes: 23284ad ("PCI: keystone: Add support for PCIe EP in AM654x Platforms") Signed-off-by: Niklas Cassel <[email protected]> Reviewed-by: Manivannan Sadhasivam <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Manivannan Sadhasivam <[email protected]> [kwilczynski: commit log] Signed-off-by: Krzysztof Wilczyński <[email protected]>
1 parent 6a6b66f commit a2fa5f9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/pci/controller/dwc/pci-keystone.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -970,7 +970,7 @@ static const struct pci_epc_features ks_pcie_am654_epc_features = {
970970
.bar[BAR_3] = { .type = BAR_FIXED, .fixed_size = SZ_64K, },
971971
.bar[BAR_4] = { .type = BAR_FIXED, .fixed_size = 256, },
972972
.bar[BAR_5] = { .type = BAR_RESIZABLE, },
973-
.align = SZ_1M,
973+
.align = SZ_64K,
974974
};
975975

976976
static const struct pci_epc_features*

0 commit comments

Comments
 (0)