[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250617042755.GG8289@sol>
Date: Mon, 16 Jun 2025 21:27:55 -0700
From: Eric Biggers <ebiggers@...nel.org>
To: T Pratham <t-pratham@...com>
Cc: Herbert Xu <herbert@...dor.apana.org.au>,
"David S. Miller" <davem@...emloft.net>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>, linux-crypto@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
Kamlesh Gurudasani <kamlesh@...com>,
Vignesh Raghavendra <vigneshr@...com>,
Praneeth Bajjuri <praneeth@...com>,
Manorit Chawdhry <m-chawdhry@...com>
Subject: Re: [PATCH v5 0/2] Add support for Texas Instruments DTHE V2 crypto
accelerator
On Tue, Jun 03, 2025 at 06:07:27PM +0530, T Pratham wrote:
> This series adds support for TI DTHE V2 crypto accelerator. DTHE V2 is a
> new crypto accelerator which contains multiple crypto IPs [1].
> This series implements support for ECB and CBC modes of AES for the AES
> Engine of the DTHE, using skcipher APIs of the kernel.
>
> Tested with:
> CONFIG_CRYPTO_MANAGER_DISABLE_TESTS is not set
> CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y
>
> and tcrypt,
> sudo modprobe tcrypt mode=500 sec=1
>
> Signed-off-by: T Pratham <t-pratham@...com>
> ---
> [1]: Section 14.6.3 (DMA Control Registers -> DMASS_DTHE)
> Link: https://www.ti.com/lit/ug/sprujb4/sprujb4.pdf
Numbers, please. What is the specific, real use case in Linux where this
patchset actually improves performance? Going off the CPU and back again just
to en/decrypt some data is hugely expensive.
Note that the manual you linked to above explicitly states that the CPU supports
the ARMv8 Cryptography Extensions. That definitively makes any off-CPU offload
obsolete. But even without that, these sorts of off-CPU offloads have always
been highly questionable.
I think it's implausible that this patchset could actually be beneficial.
In fact, it might actually be really harmful. You set your algorithms to
priority 30000, which makes them be prioritized over ARMv8 CE. I've seen
exactly that bug with other "accelerators", which actually regressed performance
by over 50x compared to simply staying on the CPU.
- Eric
Powered by blists - more mailing lists