Re: [PATCH v11 3/3] crypto: Add Inside Secure SafeXcel EIP-93 crypto engine support
From: Herbert Xu
Date: Tue Apr 01 2025 - 06:08:26 EST
On Tue, Jan 14, 2025 at 01:36:36PM +0100, Christian Marangi wrote:
>
> +static int eip93_send_hash_req(struct crypto_async_request *async, u8 *data,
> + dma_addr_t *data_dma, u32 len, bool last)
> +{
...
> +again:
> + ret = eip93_put_descriptor(eip93, &cdesc);
> + if (ret) {
> + usleep_range(EIP93_RING_BUSY_DELAY,
> + EIP93_RING_BUSY_DELAY * 2);
> + goto again;
> + }
> +
> + /* Writing new descriptor count starts DMA action */
> + writel(1, eip93->base + EIP93_REG_PE_CD_COUNT);
Why is there no locking here? Shouldn't this be under ring->write_lock?
Cheers,
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt