hi,
Check log, call trace output "irqstate: 00000103"
Check code: drivers/crypto/caam/jr.c
286 if (irqstate & JRINT_JR_ERROR) {
287 dev_err(dev, "job ring error: irqstate: %08x\n", irqstate);
288 BUG();
289 }
caam_jr_remove function
238 if (atomic_read(&jrpriv->tfm_count)) {
239 dev_err(jrdev, "Device is busy\n");
240 return -EBUSY;
241 }
Judging from the current log, the caam_jr_remove function was called, but the check device is still busy.
I found a similar problem:
https://community.nxp.com/t5/Layerscape/Kernel-panic-with-Layerscape-17-09-kernel-4-9-35/m-p/697467
NXP suggest:
"You are working with the kernel from LSDK 1709 ( 4.9.35), but your u-Boot seem to be taken from an earlier release (1709 u-Boot is 2017.07, your one is 2017.03).
Can you update your u-Boot and try again?"
Check our version:
nxp-ls1028 kernel: Linux version 5.10.154*
nxp-ls1028 kernel: efi: EFI v2.80 by Das U-Boot
U-Boot 2019.10+fsl+g3d542a3d22 (Dec 21 2021 - 20:21:21 +0000)
our uboot version is Higher, do you know the possible cause of this problem?
Thanks!
BR/SK
caam_jr 8030000.jr: Device is busy
caam_jr 8020000.jr: Device is busy
caam_jr 8010000.jr: Device is busy
arm-smmu 5000000.iommu: disabling translation
caam_jr 8010000.jr: job ring error: irqstate: 00000103
------------[ cut here ]------------
kernel BUG at drivers/crypto/caam/jr.c:288!
Internal error: Oops - BUG: 0 [#1] PREEMPT SMP
Modules linked in: lttng_ring_buffer_client_discard(O) lttng_ring_buffer_client_overwrite(O) lttng_ring_buffer_metadata_client(O) lttng_ring_buffer_client_mmap_discard(O) lttng_ring_buffer_client_mmap_overwrite(O) lttng_ring_buffer_metadata_mmap_client(O) lttng_probe_printk(O) lttng_probe_signal(O) lttng_probe_irq(O) lttng_probe_sched(O) lttng_tracer(O) lttng_statedump(O) lttng_wrapper(O) lttng_uprobes(O) lttng_clock(O) lttng_kprobes(O) lttng_lib_ring_buffer(O) lttng_kretprobes(O) binfmt_misc [last unloaded: tpm_ftpm_tee]
CPU: 0 PID: 163 Comm: hwrng Tainted: G W O 5.10.154-wrl21.15-wrprime-1-yocto-standard-custom-rcs #1
Hardware name: freescale ls1028a/ls1028a, BIOS 2019.10+fsl+g3d542a3d22 12/21/2021
pstate: 60000085 (nZCv daIf -PAN -UAO -TCO BTYPE=--)
pc : caam_jr_interrupt+0x128/0x130
lr : caam_jr_interrupt+0x128/0x130
sp : ffff80001144be50
x29: ffff80001144be50 x28: ffff800010f61008
x27: ffff800011228000 x26: ffff800010f61008
x25: ffff000027904800 x24: 0000000000000072
x23: ffff8000113ba140 x22: 0000000000000001
x21: ffff800011433000 x20: ffff000027904e80
x19: 0000000000000103 x18: 0000000000000030
x17: 0000000000000000 x16: 0000000000000000
x15: ffffffffffffffff x14: ffff8000113ebcb8
x13: 0000000000000008 x12: fffffffffffcac8f
x11: ffff00000038bb00 x10: ffff8000112a1e90
x9 : ffff8000100a99c0 x8 : ffff800011249e90
x7 : ffff8000112a1e90 x6 : 0000000000000000
x5 : 0000000000000000 x4 : 0000000000000000
x3 : 0000000000000000 x2 : 0000000000000000
x1 : 0000000000000000 x0 : ffff0000279ac600
Call trace:
caam_jr_interrupt+0x128/0x130
__handle_irq_event_percpu+0x84/0x2b0
handle_irq_event+0x6c/0xfc
handle_fasteoi_irq+0xc8/0x230
__handle_domain_irq+0xb8/0x130
gic_handle_irq+0x90/0x158
el1_irq+0xcc/0x180
_raw_spin_lock_irq+0x0/0x90
caam_rng_read_one.constprop.0+0x248/0x370
caam_read+0x8c/0xb0
hwrng_fillfn+0xfc/0x1cc
kthread+0x14c/0x160
ret_from_fork+0x10/0x30
Code: 2a1303e2 d00029a1 910ee021 940b2b1d (d4210000)
---[ end trace f04d90f3ad0da5f4 ]---
Kernel panic - not syncing: Oops - BUG: Fatal exception in interrupt
Kernel Offset: disabled
CPU features: 0x28040022,21002008
Memory Limit: none