From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 46961324B30; Mon, 27 Oct 2025 18:57:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1761591424; cv=none; b=q2N3QAQUg0WTOmlnsh7Cvha1WNgFynzJSjGBvEtJ1HHbDbPgRF6L9IfvZyxGp1nFvt4rC2TX2qtaEg1feU1x0qUhb20n3j5fCjsX9r8kd9S3R7ngrkmBtOJ+TyNzERi4VBfBiVxL8sFWmFcH19c6HLwNCiMW9bbxBPRP7jbvjfo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1761591424; c=relaxed/simple; bh=O+Fdmhms1+Ej+1eRaSWpqaWyXSZryLFe5LCYNArXW1c=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=lAjB5MjJjUekYS3EKjscqQYbvxqsPXBqmXgH83X7K3rMZO8xCePfQoZBql+8C8KPYsrgkr6AodB3C9VMu+oseSxi3mWPlVNQ/MRyj8lIJtKPJr3i8PKqtC1VOesOJsLEvI/Cw0jDFYRPsehvfF9k6e6PAKtqki7DxSE0yoBFsIg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=0mpoOBOo; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="0mpoOBOo" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 33507C4CEF1; Mon, 27 Oct 2025 18:57:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1761591423; bh=O+Fdmhms1+Ej+1eRaSWpqaWyXSZryLFe5LCYNArXW1c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0mpoOBOobsThrhd5dw/iLfjflBMDu008sEJtCxNV7+7wTRfXykGqKyecudJV2oejr GACPkYQt1KSZMWPbdLavgbVsywDXkM7datnkQzrBfCuZ4lvFJmkibVzXD2vxSWxLEK nokSkeg/j9IzZET9IJRNq+UqhniAqYlp2Y3GfXfQ= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Jiri Slaby , Siddharth Vadapalli , Manivannan Sadhasivam Subject: [PATCH 5.10 161/332] PCI: keystone: Use devm_request_irq() to free "ks-pcie-error-irq" on exit Date: Mon, 27 Oct 2025 19:33:34 +0100 Message-ID: <20251027183528.880116492@linuxfoundation.org> X-Mailer: git-send-email 2.51.1 In-Reply-To: <20251027183524.611456697@linuxfoundation.org> References: <20251027183524.611456697@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.10-stable review patch. If anyone has any objections, please let me know. ------------------ From: Siddharth Vadapalli commit e51d05f523e43ce5d2bad957943a2b14f68078cd upstream. Commit under Fixes introduced the IRQ handler for "ks-pcie-error-irq". The interrupt is acquired using "request_irq()" but is never freed if the driver exits due to an error. Although the section in the driver that invokes "request_irq()" has moved around over time, the issue hasn't been addressed until now. Fix this by using "devm_request_irq()" which automatically frees the interrupt if the driver exits. Fixes: 025dd3daeda7 ("PCI: keystone: Add error IRQ handler") Reported-by: Jiri Slaby Closes: https://lore.kernel.org/r/3d3a4b52-e343-42f3-9d69-94c259812143@kernel.org Signed-off-by: Siddharth Vadapalli Signed-off-by: Manivannan Sadhasivam Cc: stable@vger.kernel.org Link: https://patch.msgid.link/20250912100802.3136121-2-s-vadapalli@ti.com Signed-off-by: Greg Kroah-Hartman --- drivers/pci/controller/dwc/pci-keystone.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/pci/controller/dwc/pci-keystone.c +++ b/drivers/pci/controller/dwc/pci-keystone.c @@ -1261,8 +1261,8 @@ static int ks_pcie_probe(struct platform if (irq < 0) return irq; - ret = request_irq(irq, ks_pcie_err_irq_handler, IRQF_SHARED, - "ks-pcie-error-irq", ks_pcie); + ret = devm_request_irq(dev, irq, ks_pcie_err_irq_handler, IRQF_SHARED, + "ks-pcie-error-irq", ks_pcie); if (ret < 0) { dev_err(dev, "failed to request error IRQ %d\n", irq);