Commit 96747228 authored by Herbert Xu's avatar Herbert Xu

dm: Add scaffolding to change completion function signature

This patch adds temporary scaffolding so that the Crypto API
completion function can take a void * instead of crypto_async_request.
Once affected users have been converted this can be removed.
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
Acked-by: default avatarMike Snitzer <snitzer@kernel.org>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent c35e03ea
...@@ -1458,8 +1458,7 @@ static int crypt_convert_block_skcipher(struct crypt_config *cc, ...@@ -1458,8 +1458,7 @@ static int crypt_convert_block_skcipher(struct crypt_config *cc,
return r; return r;
} }
static void kcryptd_async_done(struct crypto_async_request *async_req, static void kcryptd_async_done(crypto_completion_data_t *async_req, int error);
int error);
static int crypt_alloc_req_skcipher(struct crypt_config *cc, static int crypt_alloc_req_skcipher(struct crypt_config *cc,
struct convert_context *ctx) struct convert_context *ctx)
...@@ -2147,10 +2146,9 @@ static void kcryptd_crypt_read_convert(struct dm_crypt_io *io) ...@@ -2147,10 +2146,9 @@ static void kcryptd_crypt_read_convert(struct dm_crypt_io *io)
crypt_dec_pending(io); crypt_dec_pending(io);
} }
static void kcryptd_async_done(struct crypto_async_request *async_req, static void kcryptd_async_done(crypto_completion_data_t *data, int error)
int error)
{ {
struct dm_crypt_request *dmreq = async_req->data; struct dm_crypt_request *dmreq = crypto_get_completion_data(data);
struct convert_context *ctx = dmreq->ctx; struct convert_context *ctx = dmreq->ctx;
struct dm_crypt_io *io = container_of(ctx, struct dm_crypt_io, ctx); struct dm_crypt_io *io = container_of(ctx, struct dm_crypt_io, ctx);
struct crypt_config *cc = io->cc; struct crypt_config *cc = io->cc;
......
...@@ -955,9 +955,9 @@ static void xor_journal(struct dm_integrity_c *ic, bool encrypt, unsigned sectio ...@@ -955,9 +955,9 @@ static void xor_journal(struct dm_integrity_c *ic, bool encrypt, unsigned sectio
async_tx_issue_pending_all(); async_tx_issue_pending_all();
} }
static void complete_journal_encrypt(struct crypto_async_request *req, int err) static void complete_journal_encrypt(crypto_completion_data_t *data, int err)
{ {
struct journal_completion *comp = req->data; struct journal_completion *comp = crypto_get_completion_data(data);
if (unlikely(err)) { if (unlikely(err)) {
if (likely(err == -EINPROGRESS)) { if (likely(err == -EINPROGRESS)) {
complete(&comp->ic->crypto_backoff); complete(&comp->ic->crypto_backoff);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment