Patch "PCI: xilinx-xdma: Fix error code in xilinx_pl_dma_pcie_init_irq_domain()" has been added to the 6.7-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    PCI: xilinx-xdma: Fix error code in xilinx_pl_dma_pcie_init_irq_domain()

to the 6.7-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     pci-xilinx-xdma-fix-error-code-in-xilinx_pl_dma_pcie.patch
and it can be found in the queue-6.7 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 0ece79e4981400c91cf19c00c094a802d77d180b
Author: Harshit Mogalapalli <harshit.m.mogalapalli@xxxxxxxxxx>
Date:   Mon Oct 30 00:27:57 2023 -0700

    PCI: xilinx-xdma: Fix error code in xilinx_pl_dma_pcie_init_irq_domain()
    
    [ Upstream commit 2324be17b5e05ac682e7c81fcbfc7b36a9b1becb ]
    
    Currently, if the function irq_domain_add_linear() fails to allocate
    a new IRQ domain and returns NULL, we would then still return a success
    from the xilinx_pl_dma_pcie_init_irq_domain() function regardless, as
    the PTR_ERR(NULL) would return a value of zero.  This is not a desirable
    outcome.
    
    Thus, fix the incorrect error code and return the -ENOMEM error code if
    the irq_domain_add_linear() fails to allocate a new IRQ domain.
    
    [kwilczynski: commit log]
    Link: https://lore.kernel.org/linux-pci/20231030072757.3236546-1-harshit.m.mogalapalli@xxxxxxxxxx
    Fixes: 8d786149d78c ("PCI: xilinx-xdma: Add Xilinx XDMA Root Port driver")
    Signed-off-by: Harshit Mogalapalli <harshit.m.mogalapalli@xxxxxxxxxx>
    Signed-off-by: Krzysztof Wilczyński <kwilczynski@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/pci/controller/pcie-xilinx-dma-pl.c b/drivers/pci/controller/pcie-xilinx-dma-pl.c
index 96aedc85802a..3d7f280edade 100644
--- a/drivers/pci/controller/pcie-xilinx-dma-pl.c
+++ b/drivers/pci/controller/pcie-xilinx-dma-pl.c
@@ -576,7 +576,7 @@ static int xilinx_pl_dma_pcie_init_irq_domain(struct pl_dma_pcie *port)
 						  &intx_domain_ops, port);
 	if (!port->intx_domain) {
 		dev_err(dev, "Failed to get a INTx IRQ domain\n");
-		return PTR_ERR(port->intx_domain);
+		return -ENOMEM;
 	}
 
 	irq_domain_update_bus_token(port->intx_domain, DOMAIN_BUS_WIRED);




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux