* [PATCH next] PCI: rockchip-ep: Fix error code in rockchip_pcie_ep_init_ob_mem()
@ 2024-11-30 10:01 Dan Carpenter
2024-11-30 10:28 ` Damien Le Moal
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2024-11-30 10:01 UTC (permalink / raw)
To: Damien Le Moal
Cc: Shawn Lin, Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Rob Herring, Bjorn Helgaas, Heiko Stuebner,
linux-pci, linux-rockchip, linux-arm-kernel, linux-kernel,
kernel-janitors
Return -ENOMEM if pci_epc_mem_alloc_addr() fails. Don't return success.
Fixes: c35a85126116 ("PCI: rockchip-ep: Refactor rockchip_pcie_ep_probe() memory allocations")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
drivers/pci/controller/pcie-rockchip-ep.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c
index 1064b7b06cef..34162ca14093 100644
--- a/drivers/pci/controller/pcie-rockchip-ep.c
+++ b/drivers/pci/controller/pcie-rockchip-ep.c
@@ -784,6 +784,7 @@ static int rockchip_pcie_ep_init_ob_mem(struct rockchip_pcie_ep *ep)
SZ_1M);
if (!ep->irq_cpu_addr) {
dev_err(dev, "failed to reserve memory space for MSI\n");
+ err = -ENOMEM;
goto err_epc_mem_exit;
}
--
2.45.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH next] PCI: rockchip-ep: Fix error code in rockchip_pcie_ep_init_ob_mem()
2024-11-30 10:01 [PATCH next] PCI: rockchip-ep: Fix error code in rockchip_pcie_ep_init_ob_mem() Dan Carpenter
@ 2024-11-30 10:28 ` Damien Le Moal
0 siblings, 0 replies; 2+ messages in thread
From: Damien Le Moal @ 2024-11-30 10:28 UTC (permalink / raw)
To: Dan Carpenter
Cc: Shawn Lin, Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Rob Herring, Bjorn Helgaas, Heiko Stuebner,
linux-pci, linux-rockchip, linux-arm-kernel, linux-kernel,
kernel-janitors
On 11/30/24 19:01, Dan Carpenter wrote:
> Return -ENOMEM if pci_epc_mem_alloc_addr() fails. Don't return success.
>
> Fixes: c35a85126116 ("PCI: rockchip-ep: Refactor rockchip_pcie_ep_probe() memory allocations")
> Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Oops. My bad :)
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Note that this patch is in Linus tree now so the Fixes tag should be:
Fixes: 945648019466 ("PCI: rockchip-ep: Refactor rockchip_pcie_ep_probe() memory
allocations")
Thanks !
--
Damien Le Moal
Western Digital Research
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-11-30 10:29 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-30 10:01 [PATCH next] PCI: rockchip-ep: Fix error code in rockchip_pcie_ep_init_ob_mem() Dan Carpenter
2024-11-30 10:28 ` Damien Le Moal
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox