Re: [PATCH] crypto: caam: jr: Use dedicated shutdown callback

From: Herbert Xu

Date: Thu Nov 12 2026 - 05:16:02 EST


On Wed, Oct 28, 2026 at 10:28:25AM -0300, Fabio Estevam wrote:
> From: Fabio Estevam <festevam@xxxxxxxxxxxx>
>
> The CAAM job ring platform driver uses caam_jr_remove() as its
> shutdown callback.
>
> The remove path refuses to shut down a job ring while crypto
> consumers still hold references to it. This is necessary during
> driver unbinding, but causes the following warning on reboot:
>
> caam_jr 30903000.jr: Device is busy; consumers might start to crash
>
> Unlike driver removal, system shutdown does not require
> unregistering crypto algorithms or releasing driver resources.
>
> Introduce a dedicated platform shutdown callback that shuts down
> the hardware job ring without checking consumer references.
>
> Keep the reference checks and algorithm unregistration in the
> remove path.
>
> Tested on a i.MX8MP custom-board.
>
> Cc: stable@xxxxxxxxxxxxxxx
> Fixes: c007e720989e ("crypto: caam/jr - add .shutdown hook")
> Signed-off-by: Fabio Estevam <festevam@xxxxxxxxxxxx>
> ---
> drivers/crypto/caam/jr.c | 11 ++++++++++-
> 1 file changed, 10 insertions(+), 1 deletion(-)

Patch applied. Thanks.
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt