From: Rosen Penev <rosenp@gmail.com>
To: linux-crypto@vger.kernel.org
Cc: Srujana Challa <schalla@marvell.com>,
Bharat Bhushan <bbhushan2@marvell.com>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>,
linux-kernel@vger.kernel.org (open list)
Subject: [PATCH] crypto: cesa: add missing free_irq() calls
Date: Sun, 28 Jun 2026 16:20:00 -0700 [thread overview]
Message-ID: <20260628232000.1287439-1-rosenp@gmail.com> (raw)
Add the missing free_irq() calls, along with irq_set_affinity_hint(NULL)
to clear the affinity hint set during probe.
Fixes: 5bbf25419f8e ("crypto: marvell/cesa - use request_threaded_irq instead of devm variant")
Assisted-by: opencode:big-pickle
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
drivers/crypto/marvell/cesa/cesa.c | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/drivers/crypto/marvell/cesa/cesa.c b/drivers/crypto/marvell/cesa/cesa.c
index 75d8ba23d9a2..57c9295be711 100644
--- a/drivers/crypto/marvell/cesa/cesa.c
+++ b/drivers/crypto/marvell/cesa/cesa.c
@@ -511,7 +511,7 @@ static int mv_cesa_probe(struct platform_device *pdev)
writel(engine->sram_dma & CESA_SA_SRAM_MSK,
engine->regs + CESA_SA_DESC_P0);
- ret = devm_request_threaded_irq(dev, irq, NULL, mv_cesa_int,
+ ret = request_threaded_irq(irq, NULL, mv_cesa_int,
IRQF_ONESHOT,
dev_name(&pdev->dev),
engine);
@@ -540,6 +540,10 @@ static int mv_cesa_probe(struct platform_device *pdev)
return 0;
err_cleanup:
+ while (i--) {
+ irq_set_affinity_hint(cesa->engines[i].irq, NULL);
+ free_irq(cesa->engines[i].irq, &cesa->engines[i]);
+ }
for (i = 0; i < caps->nengines; i++)
mv_cesa_put_sram(pdev, i);
@@ -553,8 +557,13 @@ static void mv_cesa_remove(struct platform_device *pdev)
mv_cesa_remove_algs(cesa);
- for (i = 0; i < cesa->caps->nengines; i++)
+ for (i = 0; i < cesa->caps->nengines; i++) {
+ struct mv_cesa_engine *engine = &cesa->engines[i];
+
+ irq_set_affinity_hint(engine->irq, NULL);
+ free_irq(engine->irq, engine);
mv_cesa_put_sram(pdev, i);
+ }
}
static const struct platform_device_id mv_cesa_plat_id_table[] = {
--
2.54.0
reply other threads:[~2026-06-28 23:20 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260628232000.1287439-1-rosenp@gmail.com \
--to=rosenp@gmail.com \
--cc=bbhushan2@marvell.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=schalla@marvell.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox