On Fri, Oct 16, 2020 at 02:04:31PM +0200, marek.vasut@xxxxxxxxx wrote: > From: Marek Vasut <marek.vasut+renesas@xxxxxxxxx> > > This fixes MSI operation on legacy PCI cards, which cannot issue 64bit MSIs. > The R-Car controller only has one MSI trigger address instead of two, one > for 64bit and one for 32bit MSI, set the address to 32bit PCIe space so that > legacy PCI cards can also trigger MSIs. > > Fixes: 290c1fb35860 ("PCI: rcar: Add MSI support for PCIe") > Signed-off-by: Marek Vasut <marek.vasut+renesas@xxxxxxxxx> > Cc: Bjorn Helgaas <bhelgaas@xxxxxxxxxx> > Cc: Geert Uytterhoeven <geert+renesas@xxxxxxxxx> > Cc: Lorenzo Pieralisi <lorenzo.pieralisi@xxxxxxx> > Cc: Wolfram Sang <wsa@xxxxxxxxxxxxx> > Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@xxxxxxxxxxx> > Cc: linux-renesas-soc@xxxxxxxxxxxxxxx > --- > drivers/pci/controller/pcie-rcar-host.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/pci/controller/pcie-rcar-host.c b/drivers/pci/controller/pcie-rcar-host.c > index 1194d5f3341b..ac5c7d7573a6 100644 > --- a/drivers/pci/controller/pcie-rcar-host.c > +++ b/drivers/pci/controller/pcie-rcar-host.c > @@ -753,7 +753,7 @@ static int rcar_pcie_enable_msi(struct rcar_pcie_host *host) > } > > /* setup MSI data target */ > - msi->pages = __get_free_pages(GFP_KERNEL, 0); > + msi->pages = __get_free_pages(GFP_KERNEL | GFP_DMA32, 0); This does not do what you want on !CONFIG_ZONE_DMA32 (ie arm LPAE). Can't you just pick up a non-DMA-able address < 4GB (ie outside the host controller inbound window range) and use it as doorbell address instead ? Thanks, Lorenzo > rcar_pcie_hw_enable_msi(host); > > return 0; > -- > 2.28.0 >