mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: T Pratham <t-pratham@ti.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: "David S. Miller" <davem@davemloft.net>,
	Manorit Chawdhry <m-chawdhry@ti.com>,
	Kamlesh Gurudasani <kamlesh@ti.com>,
	Shiva Tripathi <s-tripathi1@ti.com>,
	Kavitha Malarvizhi <k-malarvizhi@ti.com>,
	Vishal Mahaveer <vishalm@ti.com>,
	Praneeth Bajjuri <praneeth@ti.com>,
	<linux-crypto@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v4 1/4] crypto: ti - Add support for AES-XTS in DTHEv2 driver
Date: Tue, 21 Oct 2025 20:40:40 +0530	[thread overview]
Message-ID: <c76843e9-e644-4b9b-803f-b9eb9a31b89c@ti.com> (raw)
In-Reply-To: <07032efd-52a2-44e1-89bd-81602be9eb32@ti.com>

Hi Herbert,
On 17-10-2025 22:13, T Pratham wrote:
> On 17-10-2025 11:11, Herbert Xu wrote:
>> On Thu, Oct 09, 2025 at 04:11:31PM +0530, T Pratham wrote:
>>>
>>
>> You should allocate a fallback that is synchronous only.  Then you
>> can store the sub-request on the stack with SYNC_SKCIPHER_REQUEST_ON_STACK.
>> Otherwise the sub-request reqsize may overflow your request object.
> 
> Understood. Will correct this.

Since a similar mechanism is not available for AEADs, I was wondering if
doing the following in the tfm_init functions of AEAD algs (PATCH 3/4
and 4/4 of this series) is acceptable, esp. since setting reqsize is
moved to the algorithm struct field cra_reqsize.

+       unsigned int reqsize = crypto_aead_reqsize(tfm);
+       crypto_aead_set_reqsize(tfm, reqsize +
crypto_aead_reqsize(ctx->aead_fb));


I noticed all older existing drivers using a fallback do something
similar, and was wondering if you'll still accept new drivers which use
crypto_*_set_reqsize() to modify reqsize for fallback use-cases?

-- 
Regards
T Prathm <t-pratham@ti.com>

  reply	other threads:[~2025-10-21 15:10 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-09 10:41 [PATCH v4 0/4] Add support for more AES modes in TI DTHEv2 T Pratham
2025-10-09 10:41 ` [PATCH v4 1/4] crypto: ti - Add support for AES-XTS in DTHEv2 driver T Pratham
2025-10-17  5:41   ` Herbert Xu
2025-10-17 16:43     ` T Pratham
2025-10-21 15:10       ` T Pratham [this message]
2025-10-22  0:35         ` Herbert Xu
2025-10-09 10:41 ` [PATCH v4 2/4] crypto: ti - Add support for AES-CTR " T Pratham
2025-10-09 10:41 ` [PATCH v4 3/4] crypto: ti - Add support for AES-GCM " T Pratham
2025-10-09 10:41 ` [PATCH v4 4/4] crypto: ti - Add support for AES-CCM " T Pratham

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=c76843e9-e644-4b9b-803f-b9eb9a31b89c@ti.com \
    --to=t-pratham@ti.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=k-malarvizhi@ti.com \
    --cc=kamlesh@ti.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m-chawdhry@ti.com \
    --cc=praneeth@ti.com \
    --cc=s-tripathi1@ti.com \
    --cc=vishalm@ti.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®