[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200817080941.19227-16-allen.lkml@gmail.com>
Date: Mon, 17 Aug 2020 13:39:37 +0530
From: Allen Pais <allen.lkml@...il.com>
To: nicolas.ferre@...rochip.com, alexandre.belloni@...tlin.com,
ludovic.desroches@...rochip.com, heiko@...ech.de,
matthias.bgg@...il.com
Cc: keescook@...omium.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-rockchip@...ts.infradead.org,
inux-mediatek@...ts.infradead.org,
Allen Pais <allen.lkml@...il.com>,
Romain Perier <romain.perier@...il.com>
Subject: [PATCH 15/19] crypto: qce: convert tasklets to use new tasklet_setup() API
In preparation for unconditionally passing the
struct tasklet_struct pointer to all tasklet
callbacks, switch to using the new tasklet_setup()
and from_tasklet() to pass the tasklet pointer explicitly.
Signed-off-by: Romain Perier <romain.perier@...il.com>
Signed-off-by: Allen Pais <allen.lkml@...il.com>
---
drivers/crypto/qce/core.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/qce/core.c b/drivers/crypto/qce/core.c
index cb6d61eb7302..0b171ef9e3b7 100644
--- a/drivers/crypto/qce/core.c
+++ b/drivers/crypto/qce/core.c
@@ -116,9 +116,9 @@ static int qce_handle_queue(struct qce_device *qce,
return ret;
}
-static void qce_tasklet_req_done(unsigned long data)
+static void qce_tasklet_req_done(struct tasklet_struct *t)
{
- struct qce_device *qce = (struct qce_device *)data;
+ struct qce_device *qce = from_tasklet(qce, t, done_tasklet);
struct crypto_async_request *req;
unsigned long flags;
@@ -221,8 +221,7 @@ static int qce_crypto_probe(struct platform_device *pdev)
goto err_clks;
spin_lock_init(&qce->lock);
- tasklet_init(&qce->done_tasklet, qce_tasklet_req_done,
- (unsigned long)qce);
+ tasklet_setup(&qce->done_tasklet, qce_tasklet_req_done);
crypto_init_queue(&qce->queue, QCE_QUEUE_LENGTH);
qce->async_req_enqueue = qce_async_request_enqueue;
--
2.17.1
Powered by blists - more mailing lists