[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <d1d70f62-fb3d-4af5-936e-b59491ee1c34@ti.com>
Date: Wed, 20 Aug 2025 14:28:35 +0530
From: T Pratham <t-pratham@...com>
To: Ovidiu Panait <ovidiu.panait.oss@...il.com>,
Herbert Xu
<herbert@...dor.apana.org.au>,
"David S . Miller" <davem@...emloft.net>
CC: <linux-kernel@...r.kernel.org>, <linux-crypto@...r.kernel.org>,
Kamlesh
Gurudasani <kamlesh@...com>,
Manorit Chawdhry <m-chawdhry@...com>,
Vignesh
Raghavendra <vigneshr@...com>,
Praneeth Bajjuri <praneeth@...com>, Vishal
Mahaveer <vishalm@...com>,
Kavitha Malarvizhi <k-malarvizhi@...com>
Subject: Re: [PATCH v6 2/2] crypto: ti: Add driver for DTHE V2 AES Engine
(ECB, CBC)
On 19/08/25 15:26, Ovidiu Panait wrote:
> Hi,
>
> On 8/19/25 9:12 AM, T Pratham wrote:
>> Add support for ECB and CBC modes in the AES Engine of the DTHE V2
>> hardware cryptography engine.
>>
>> Signed-off-by: T Pratham <t-pratham@...com>
>> ---
>> MAINTAINERS | 1 +
>> drivers/crypto/Kconfig | 1 +
>> drivers/crypto/Makefile | 1 +
>> drivers/crypto/ti/Kconfig | 14 +
>> drivers/crypto/ti/Makefile | 3 +
>> drivers/crypto/ti/dthev2-aes.c | 411 ++++++++++++++++++++++++++++++
>> drivers/crypto/ti/dthev2-common.c | 220 ++++++++++++++++
>> drivers/crypto/ti/dthev2-common.h | 101 ++++++++
>> 8 files changed, 752 insertions(+)
>> create mode 100644 drivers/crypto/ti/Kconfig
>> create mode 100644 drivers/crypto/ti/Makefile
>> create mode 100644 drivers/crypto/ti/dthev2-aes.c
>> create mode 100644 drivers/crypto/ti/dthev2-common.c
>> create mode 100644 drivers/crypto/ti/dthev2-common.h
>>
>
> [...]
>
[...]
>> +
>> +probe_reg_err:
>> + crypto_engine_stop(dev_data->engine);
>> +probe_engine_start_err:
>> + crypto_engine_exit(dev_data->engine);
>
> crypto_engine_exit() calls crypto_engine_stop() internally, so there is
> no need to call both functions here. Just use crypto_engine_exit().
>
> /**
> * crypto_engine_exit - free the resources of hardware engine when exit
> * @engine: the hardware engine need to be freed
> */
> void crypto_engine_exit(struct crypto_engine *engine)
> {
> int ret;
>
> ret = crypto_engine_stop(engine);
> if (ret)
> return;
>
> kthread_destroy_worker(engine->kworker);
> }
>
Thanks for this insight! Will correct this.
[...]
>
> Ovidiu
Regards
T Pratham
Powered by blists - more mailing lists