royzah opened a new pull request, #20445: URL: https://github.com/apache/nuttx/pull/20445
*Note: Please adhere to [Contributing Guidelines](https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md).* ## Summary A `JRCR` reset only flushes and halts the CAAM job ring. A second reset, once `JRINT` reports the halt done, completes it; Linux's `caam_reset_hw_jr()` does the same. `imxrt_caam_ring_init()` wrote the reset once, so the ring stayed halted and the RNG instantiate job never completed: every boot logged `imxrt_caam_run: ERROR: job ring did not answer`. It recovered only because the settle loop in `imxrt_caam_rng_init()` calls `imxrt_caam_ring_init()` a second time, and that second write finished the reset. ## Impact i.MX RT117x CAAM only. No error at boot; the job ring works from its first job. ## Testing Host: Ubuntu 24.04, x86_64. Builds in `ghcr.io/apache/nuttx/apache-nuttx-ci-linux`. | Where | Result | | --- | --- | | `fmu-v6xrt:nsh` (`CONFIG_IMXRT_RNG`), `imxrt1170-evk:nsh` | build | | FMU-v6X-RT, the two changed files built into its firmware, 3 warm boots and 1 cold boot | no CAAM error; `/dev/random` returns 16 fresh bytes each boot | | same board, `master`'s files, 3 warm boots | `job ring did not answer` on every boot | `tools/checkpatch.sh -c -u -m -g` clean. <details> <summary>Boot logs and /dev/random, master vs this PR</summary> `master`, each of 3 boots: ``` imxrt_caam_run: ERROR: job ring did not answer nsh> dd if=/dev/random of=/fs/microsd/r1 bs=16 count=1 16 bytes (1 blocks) copied, 2000 usec, 7 KB/s ``` This PR, 3 warm boots and a cold boot, no CAAM line in any boot log: ``` nsh> dd if=/dev/random of=/fs/microsd/r1 bs=16 count=1 16 bytes (1 blocks) copied, 2000 usec, 7 KB/s nsh> hexdump /fs/microsd/r1 0000: ec 25 b4 3f 6c 21 72 20 d8 62 42 65 94 cc af e2 0000: 47 c4 cd 75 a8 0f 6b a0 1a ea 55 9b 82 74 90 9c 0000: 13 9e be 59 48 17 54 ca cd dd b7 f0 21 c1 9d 26 0000: 97 b4 70 86 aa 14 f7 ad 4e 1c db 87 cc 0a fc cc (cold boot) ``` </details> -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
