[PATCH] PCI: rcar-gen4: set ep BAR4 fixed size

Jerome Brunet posted 1 patch 8 months, 3 weeks ago
drivers/pci/controller/dwc/pcie-rcar-gen4.c | 1 +
1 file changed, 1 insertion(+)
[PATCH] PCI: rcar-gen4: set ep BAR4 fixed size
Posted by Jerome Brunet 8 months, 3 weeks ago
On rcar-gen4, the ep BAR4 has a fixed size of 256B.
Document this constraint in the epc features of the platform.

Fixes: e311b3834dfa ("PCI: rcar-gen4: Add endpoint mode support")
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
---
This was tested on rcar-gen4 r8a779f0-spider device.
---
 drivers/pci/controller/dwc/pcie-rcar-gen4.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/pci/controller/dwc/pcie-rcar-gen4.c b/drivers/pci/controller/dwc/pcie-rcar-gen4.c
index fc872dd35029c083da58144dce23cd1ce80f9374..02638ec442e7012d61dfad70016077d9becf56a6 100644
--- a/drivers/pci/controller/dwc/pcie-rcar-gen4.c
+++ b/drivers/pci/controller/dwc/pcie-rcar-gen4.c
@@ -403,6 +403,7 @@ static const struct pci_epc_features rcar_gen4_pcie_epc_features = {
 	.msix_capable = false,
 	.bar[BAR_1] = { .type = BAR_RESERVED, },
 	.bar[BAR_3] = { .type = BAR_RESERVED, },
+	.bar[BAR_4] = { .type = BAR_FIXED, .fixed_size = 256 },
 	.bar[BAR_5] = { .type = BAR_RESERVED, },
 	.align = SZ_1M,
 };

---
base-commit: dea140198b846f7432d78566b7b0b83979c72c2b
change-id: 20250328-rcar-gen4-bar4-dccd1347fe38

Best regards,
-- 
Jerome
Re: [PATCH] PCI: rcar-gen4: set ep BAR4 fixed size
Posted by Manivannan Sadhasivam 8 months ago
On Fri, 28 Mar 2025 15:30:44 +0100, Jerome Brunet wrote:
> On rcar-gen4, the ep BAR4 has a fixed size of 256B.
> Document this constraint in the epc features of the platform.
> 
> 

Applied, thanks!

[1/1] PCI: rcar-gen4: set ep BAR4 fixed size
      commit: ca0c5fd2282eff988738539f80b8eb4e1f81a342

Best regards,
-- 
Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Re: [PATCH] PCI: rcar-gen4: set ep BAR4 fixed size
Posted by Manivannan Sadhasivam 8 months, 2 weeks ago
On Fri, Mar 28, 2025 at 03:30:44PM +0100, Jerome Brunet wrote:
> On rcar-gen4, the ep BAR4 has a fixed size of 256B.
> Document this constraint in the epc features of the platform.
> 
> Fixes: e311b3834dfa ("PCI: rcar-gen4: Add endpoint mode support")
> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>

Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>

- Mani

> ---
> This was tested on rcar-gen4 r8a779f0-spider device.
> ---
>  drivers/pci/controller/dwc/pcie-rcar-gen4.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/pci/controller/dwc/pcie-rcar-gen4.c b/drivers/pci/controller/dwc/pcie-rcar-gen4.c
> index fc872dd35029c083da58144dce23cd1ce80f9374..02638ec442e7012d61dfad70016077d9becf56a6 100644
> --- a/drivers/pci/controller/dwc/pcie-rcar-gen4.c
> +++ b/drivers/pci/controller/dwc/pcie-rcar-gen4.c
> @@ -403,6 +403,7 @@ static const struct pci_epc_features rcar_gen4_pcie_epc_features = {
>  	.msix_capable = false,
>  	.bar[BAR_1] = { .type = BAR_RESERVED, },
>  	.bar[BAR_3] = { .type = BAR_RESERVED, },
> +	.bar[BAR_4] = { .type = BAR_FIXED, .fixed_size = 256 },
>  	.bar[BAR_5] = { .type = BAR_RESERVED, },
>  	.align = SZ_1M,
>  };
> 
> ---
> base-commit: dea140198b846f7432d78566b7b0b83979c72c2b
> change-id: 20250328-rcar-gen4-bar4-dccd1347fe38
> 
> Best regards,
> -- 
> Jerome
> 

-- 
மணிவண்ணன் சதாசிவம்