From: "Dey, Megha" <megha.dey@intel.com> To: Herbert Xu <herbert@gondor.apana.org.au> Cc: "tim.c.chen@linux.intel.com" <tim.c.chen@linux.intel.com>, "davem@davemloft.net" <davem@davemloft.net>, "linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, "Yu, Fenghua" <fenghua.yu@intel.com>, "Megha Dey" <megha.dey@linux.intel.com> Subject: RE: [PATCH] crypto : async implementation for sha1-mb Date: Mon, 13 Jun 2016 19:10:26 +0000 [thread overview] Message-ID: <C440BA31B54DCD4AAC682D2365C8FEE703CABA2C@ORSMSX111.amr.corp.intel.com> (raw) In-Reply-To: <20160613082202.GA7148@gondor.apana.org.au> -----Original Message----- From: Herbert Xu [mailto:herbert@gondor.apana.org.au] Sent: Monday, June 13, 2016 1:22 AM To: Dey, Megha <megha.dey@intel.com> Cc: tim.c.chen@linux.intel.com; davem@davemloft.net; linux-crypto@vger.kernel.org; linux-kernel@vger.kernel.org; Yu, Fenghua <fenghua.yu@intel.com>; Megha Dey <megha.dey@linux.intel.com> Subject: Re: [PATCH] crypto : async implementation for sha1-mb On Tue, Jun 07, 2016 at 11:14:42AM -0700, Megha Dey wrote: > > - desc->tfm = child; > - desc->flags = CRYPTO_TFM_REQ_MAY_SLEEP; > + ahash_request_set_tfm(desc, child); > + ahash_request_set_callback(desc, CRYPTO_TFM_REQ_MAY_SLEEP, NULL, > +NULL); Why are the callbacks set to NULL/NULL? The child is async so you should have a valid callback function here. Instead of continuing to do the broken callback handling outside of the API (i.e., rctx->complete) please use the API mechanism that is provided for this purpose. > In the current implementation, the inner algorithm is called directly, and we use the outer algorithm's callback. We do not use the callback in inner algorithm. We are actually calling the child functions directly and the child is using the parent's call back function. Probably I can add a comment before the set callback function.. will this be ok? Thanks,
WARNING: multiple messages have this Message-ID (diff)
From: "Dey, Megha" <megha.dey@intel.com> To: Herbert Xu <herbert@gondor.apana.org.au> Cc: "tim.c.chen@linux.intel.com" <tim.c.chen@linux.intel.com>, "davem@davemloft.net" <davem@davemloft.net>, "linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, "Yu, Fenghua" <fenghua.yu@intel.com>, "Megha Dey" <megha.dey@linux.intel.com> Subject: RE: [PATCH] crypto : async implementation for sha1-mb Date: Mon, 13 Jun 2016 19:10:26 +0000 [thread overview] Message-ID: <C440BA31B54DCD4AAC682D2365C8FEE703CABA2C@ORSMSX111.amr.corp.intel.com> (raw) In-Reply-To: <20160613082202.GA7148@gondor.apana.org.au> -----Original Message----- From: Herbert Xu [mailto:herbert@gondor.apana.org.au] Sent: Monday, June 13, 2016 1:22 AM To: Dey, Megha <megha.dey@intel.com> Cc: tim.c.chen@linux.intel.com; davem@davemloft.net; linux-crypto@vger.kernel.org; linux-kernel@vger.kernel.org; Yu, Fenghua <fenghua.yu@intel.com>; Megha Dey <megha.dey@linux.intel.com> Subject: Re: [PATCH] crypto : async implementation for sha1-mb On Tue, Jun 07, 2016 at 11:14:42AM -0700, Megha Dey wrote: > > - desc->tfm = child; > - desc->flags = CRYPTO_TFM_REQ_MAY_SLEEP; > + ahash_request_set_tfm(desc, child); > + ahash_request_set_callback(desc, CRYPTO_TFM_REQ_MAY_SLEEP, NULL, > +NULL); Why are the callbacks set to NULL/NULL? The child is async so you should have a valid callback function here. Instead of continuing to do the broken callback handling outside of the API (i.e., rctx->complete) please use the API mechanism that is provided for this purpose. > In the current implementation, the inner algorithm is called directly, and we use the outer algorithm's callback. We do not use the callback in inner algorithm. We are actually calling the child functions directly and the child is using the parent's call back function. Probably I can add a comment before the set callback function.. will this be ok? Thanks, -- Email: Herbert Xu <herbert@gondor.apana.org.au> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
next prev parent reply other threads:[~2016-06-13 19:10 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-06-07 18:14 [PATCH] crypto : async implementation for sha1-mb Megha Dey 2016-06-13 8:22 ` Herbert Xu 2016-06-13 19:10 ` Dey, Megha [this message] 2016-06-13 19:10 ` Dey, Megha 2016-06-14 4:34 ` Herbert Xu 2016-06-17 19:28 Megha Dey 2016-06-20 11:21 ` Herbert Xu 2016-06-20 20:25 Megha Dey 2016-06-21 13:07 ` Herbert Xu 2016-06-22 1:21 Megha Dey 2016-06-23 10:45 ` Herbert Xu
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=C440BA31B54DCD4AAC682D2365C8FEE703CABA2C@ORSMSX111.amr.corp.intel.com \ --to=megha.dey@intel.com \ --cc=davem@davemloft.net \ --cc=fenghua.yu@intel.com \ --cc=herbert@gondor.apana.org.au \ --cc=linux-crypto@vger.kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=megha.dey@linux.intel.com \ --cc=tim.c.chen@linux.intel.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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.