Commit 8181ea8d authored by Will McVicker's avatar Will McVicker Committed by Treehugger Robot
Browse files

BACKPORT: FROMGIT: PCI: dwc: Drop dependency on ZONE_DMA32

Re-work the msi_msg DMA allocation logic to use dmam_alloc_coherent() which
uses the coherent DMA mask to try to return an allocation within the DMA
mask limits. With that, we now can drop the msi_page parameter in struct
dw_pcie_rp. This allows kernel configurations that disable ZONE_DMA32 to
continue supporting a 32-bit DMA mask. Without this patch, the PCIe host
device will fail to probe when ZONE_DMA32 is disabled.

Bug: 241473543
Link: https://lore.kernel.org/r/20220825235404.4132818-2-willmcvicker@google.com


Fixes: 35797e67 ("PCI: dwc: Fix MSI msi_msg DMA mapping")
Reported-by: default avatarIsaac J. Manjarres <isaacmanjarres@google.com>
Signed-off-by: default avatarWill McVicker <willmcvicker@google.com>
Signed-off-by: default avatarLorenzo Pieralisi <lpieralisi@kernel.org>
Reviewed-by: default avatarRob Herring <robh@kernel.org>
Acked-by: default avatarJingoo Han <jingoohan1@gmail.com>
Change-Id: Ib76ffe9d90743a09c633e9f39428403aabd983e3
(cherry picked from commit 423511ec https://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/pci.git pci/dwc)
parent a8dfddb2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment