[PATCH 1/4] ipmi: bt-bmc: Propagate errors from IRQ configuration

[email protected]
Newsgroups org.kernel.vger.linux-kernel
Message-ID <[email protected]>
From: bui duc phuc <[email protected]>

Check and propagate the return value of bt_bmc_config_irq() instead of
ignoring errors during probe.

Signed-off-by: bui duc phuc <[email protected]>
---
 drivers/char/ipmi/bt-bmc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/char/ipmi/bt-bmc.c b/drivers/char/ipmi/bt-bmc.c
index a179d4797011..7d3944bda8db 100644
--- a/drivers/char/ipmi/bt-bmc.c
+++ b/drivers/char/ipmi/bt-bmc.c
@@ -436,7 +436,9 @@ static int bt_bmc_probe(struct platform_device *pdev)
 		return rc;
 	}
 
-	bt_bmc_config_irq(bt_bmc, pdev);
+	rc = bt_bmc_config_irq(bt_bmc, pdev);
+	if (rc)
+		return rc;
 
 	if (bt_bmc->irq >= 0) {
 		dev_info(dev, "Using IRQ %d\n", bt_bmc->irq);
-- 
2.43.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.