diff options
author | Frank Li <frank.li@nxp.com> | 2022-11-02 10:10:10 -0400 |
---|---|---|
committer | Lorenzo Pieralisi <lpieralisi@kernel.org> | 2022-11-23 16:24:06 +0100 |
commit | 0c031262d2ddfb938f9668d620d7ed674771646c (patch) | |
tree | 9daad1adf3d6aae6296dbcc275e5938ce1433fa1 /drivers/pci | |
parent | 1d118fed348f65bcc08e9bfb947085c276d05b52 (diff) | |
download | linux-0c031262d2ddfb938f9668d620d7ed674771646c.tar.gz linux-0c031262d2ddfb938f9668d620d7ed674771646c.tar.bz2 linux-0c031262d2ddfb938f9668d620d7ed674771646c.zip |
PCI: endpoint: pci-epf-vntb: Fix call pci_epc_mem_free_addr() in error path
Replace pci_epc_mem_free_addr() with pci_epf_free_space() in the
error handle path to match pci_epf_alloc_space().
Link: https://lore.kernel.org/r/20221102141014.1025893-4-Frank.Li@nxp.com
Fixes: e35f56bb0330 ("PCI: endpoint: Support NTB transfer between RC and EP")
Signed-off-by: Frank Li <frank.li@nxp.com>
Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/endpoint/functions/pci-epf-vntb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c b/drivers/pci/endpoint/functions/pci-epf-vntb.c index 1863006cc36c..191924a83454 100644 --- a/drivers/pci/endpoint/functions/pci-epf-vntb.c +++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c @@ -571,7 +571,7 @@ static int epf_ntb_db_bar_init(struct epf_ntb *ntb) return ret; err_alloc_peer_mem: - pci_epc_mem_free_addr(ntb->epf->epc, epf_bar->phys_addr, mw_addr, epf_bar->size); + pci_epf_free_space(ntb->epf, mw_addr, barno, 0); return -1; } |