From: liulongfang <liulongfang@huawei.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: <wangzhou1@hisilicon.com>, <linux-crypto@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] crypto/hisilicon: Add null judgment to the callback interface
Date: Thu, 10 Nov 2022 10:03:53 +0800 [thread overview]
Message-ID: <32686c5b-04b2-7103-bf2e-113db2315ef4@huawei.com> (raw)
In-Reply-To: <Y2twbHyQkTMoTz+O@gondor.apana.org.au>
On 2022/11/9 17:18, Herbert Xu wrote:
> On Wed, Nov 09, 2022 at 02:21:11PM +0800, liulongfang wrote:
>>
>> The trigger method is to not call the function skcipher_request_set_callback()
>> when using the skcipher interface for encryption and decryption services.
>
> Yes but which function exactly? Please give the exact call path
> leading to this crash.
>
This problem occurs in the application code of the encryption usage scenario
(unfortunately, these codes are not open to the public and cannot be given to you),
but its code logic is similar to test_skcipher_vec_cfg() in kernel\crypto\testmgr.c,
and it is also in accordance with this call logic execution:
crypto_alloc_skcipher()--->skcipher_request_alloc()--->crypto_skcipher_setkey()--->
sg_init_table()--->skcipher_request_set_crypt()--->
crypto_skcipher_encrypt()/crypto_skcipher_decrypt()--->
skcipher_request_free()--->crypto_free_skcipher()
Just don't add "wait" and skcipher_request_set_callback(),
use it as a synchronous mode.
Thanks
Longfang.
> Cheers,
>
next prev parent reply other threads:[~2022-11-10 2:04 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-30 2:43 Longfang Liu
2022-09-30 2:49 ` Herbert Xu
2022-09-30 3:48 ` liulongfang
2022-10-28 3:57 ` Herbert Xu
2022-10-29 1:25 ` liulongfang
2022-11-04 9:08 ` Herbert Xu
2022-11-07 13:22 ` liulongfang
2022-11-08 9:59 ` Herbert Xu
2022-11-09 6:21 ` liulongfang
2022-11-09 9:18 ` Herbert Xu
2022-11-10 2:03 ` liulongfang [this message]
2022-11-10 3:20 ` Herbert Xu
2022-11-10 4:11 ` liulongfang
2022-11-10 8:53 ` Herbert Xu
2022-11-12 1:51 ` liulongfang
2022-10-28 2:26 ` liulongfang
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=32686c5b-04b2-7103-bf2e-113db2315ef4@huawei.com \
--to=liulongfang@huawei.com \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=wangzhou1@hisilicon.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
all inboxes | Powered by JetHome®