]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
PCI: dwc: rcar-gen4: Mark BAR0 and BAR2 as Resizable BARs in endpoint mode
authorKoichiro Den <den@valinux.co.jp>
Tue, 10 Feb 2026 16:03:15 +0000 (01:03 +0900)
committerManivannan Sadhasivam <mani@kernel.org>
Sat, 21 Mar 2026 14:25:47 +0000 (19:55 +0530)
R-Car Gen4 (S4) endpoint controller implements the PCIe Resizable BAR
capability for BAR0 and BAR2. Advertise them as BAR_RESIZABLE so that EPF
requested BAR sizes are reflected to the host.

Signed-off-by: Koichiro Den <den@valinux.co.jp>
[commit log]
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
Reviewed-by: Niklas Cassel <cassel@kernel.org>
Link: https://patch.msgid.link/20260210160315.2272930-1-den@valinux.co.jp
drivers/pci/controller/dwc/pcie-rcar-gen4.c

index a6912e85e4ddc3791c4e6f4b6d4df8c5f30f1851..3d4a889e38cc998ddde8a79767c21e3ae78835df 100644 (file)
@@ -422,7 +422,9 @@ static int rcar_gen4_pcie_ep_raise_irq(struct dw_pcie_ep *ep, u8 func_no,
 static const struct pci_epc_features rcar_gen4_pcie_epc_features = {
        DWC_EPC_COMMON_FEATURES,
        .msi_capable = true,
+       .bar[BAR_0] = { .type = BAR_RESIZABLE, },
        .bar[BAR_1] = { .type = BAR_RESERVED, },
+       .bar[BAR_2] = { .type = BAR_RESIZABLE, },
        .bar[BAR_3] = { .type = BAR_RESERVED, },
        .bar[BAR_4] = { .type = BAR_FIXED, .fixed_size = 256 },
        .bar[BAR_5] = { .type = BAR_RESERVED, },