roadmap PARTIAL

818. jh7110_entropy: proven JH7110 TRNG logic, released on its own

(From calef's rulings on pull request #1806; the title and slug are drafts. Milestone 813 (a proven FAT crate released on its own) is the shape this follows.)

calef's rulings, quoted from the maintainer comments on #1806 of 2026-10-07 (UTC):

What exists, checked 2026-10-07 (UTC)

Reuse: the alternatives were surveyed in #1806's other-implementations.md appendix (looked up 2026-10-07), and none is taken, because calef ruled this crate "publish ours". The only Rust JH7110 crates found, weathered-steel's jh71xx-pac 0.11.1 and jh71xx-hal 0.7.2 (Codeberg, 2025-03), are register maps under GPL-3.0-only, which nife cannot take under its license and which carry no TRNG logic. No Rust crate for the TRNG was found. Linux's jh7110-trng driver stays the reference and is read, never copied. No upstream offer goes anywhere, by the ruling in milestone 814 (proven NVMe queue logic).

What is proven

Each row is a property this crate must prove before it publishes. The harness cell reads as in milestone 813's table. Each patch is at falsifications/ in partsfoundry/jh7110_entropy. All four prove.

property harness
A lockup bit is never overridden verification::a_lockup_bit_is_never_overridden
Ready requires RAND_RDY and carries the words untouched verification::ready_requires_rand_rdy_and_carries_the_words_untouched
Neither bit set is always not ready verification::neither_bit_set_is_always_not_ready
An unseeded core never yields bytes verification::an_unseeded_core_never_yields_bytes

Not proven: the quality of the randomness, which is a property of the silicon that no proof reaches; Pool and output_bytes, which copy words; and the device-tree query, which the cut moves out.

Release, by #1806's rulings

  1. The name is settled before anything leaves (857's Fork 5 as calef amended it on 2026-10-11 UTC). script/names jh7110_entropy reports it ratified, crates.io answers 404 for it (or it is already ours), and partsfoundry/jh7110_entropy does not exist yet. script/crate-standalone checks the first.
  2. Make the cut above. cargo tree -p jh7110_entropy then lists no nife crate, and the tests read only fixtures inside the package.
  3. In the tree, script/verify proves the harnesses and Cargo.toml says publish = false.
  4. The package meets Fork 3 of milestone 857 (crates released on their own). cargo package --list shows its harnesses and falsification patches.
  5. Ready means proofs passing and the API stable. Milestone 814 (proven NVMe queue logic) says how each is measured; here the soak is step 6. When the soak exits, calef adds it to the lint-checked publish allowlist. The partsfoundry/jh7110_entropy repository is created when the crate moves, on the shared CI template (milestone 887), through reusable workflows: Kani through kani-github-action, lint, release. Its release workflow refuses to publish unless the proof job is green. No harness here reads target_arch, so stock Kani proves them. §218 (carry a Kani patch so riscv64 is proved) applies only if a harness comes to need riscv64. Milestone 589 (Kani can prove riscv64 from the hosts we already have) built it.
  6. Soak, as its own repository, until the soak's five end conditions in the runbook hold. This crate is the pilot and soaks first: it is the smallest crate with a real cut, and the cut is where refactor lessons show up.
  7. Publish and consume the release by version, by the runbook's publication steps.

Parity

Pure logic, tested on the host. This lane built it on 2026-10-07 with the pinned nightly for aarch64-unknown-none-softfloat, riscv64imac-unknown-none-elf, x86_64-unknown-none and the host, all exit 0. The release workflow builds the same four. The silicon is riscv64 only; the crate is not.

Standalone, measured 2026-10-11 (UTC)

script/crate-standalone jh7110_entropy fails today, at base ae6b91e79. The manifest and files fail as for all nine crates in milestone 814 (proven NVMe queue logic). It does not build alone: device_tree_blob is a path dependency outside the copy, so neither the build nor Kani ran. A test reads a fixture from ../../device_tree_blob/tests/fixtures/, outside the crate. Beyond manifest and files, 26 lines cite this tree: 14 milestone N, 5 tree paths, 3 §N, 2 naming calef and 2 provenance blocks.

script/names reports the name jh7110_entropy ratified (checked 2026-10-25).

Measured again on 2026-10-25 (UTC) with --no-kani: the manifest and files pass, the build passes on all four targets, and the only citations left sit in Name: blocks, which stay until the ratification pass. With Kani, the four harnesses prove and each falsification patch fails its harness.

The soak, started 2026-10-31 (UTC)

The architect's review and the tags

The architect reads every crate by hand before it leaves (condition 4 of §247 (the split begins with basalt holding nife, and procps moves first), ruled 2026-11-01 (UTC)). This crate is the first so reviewed, the pilot of the review as of the mechanics. It moved on 2026-10-31 (UTC), before that ruling, so the review reads its repository, and it comes before any contract crate leaves. The ruling's second item needs a tagged release whose commit carries the Cargo version, so that cargo-semver-checks --baseline-rev has a baseline. partsfoundry/jh7110_entropy carries the tags v0.1.0, v0.1.1, v0.2.0 and v0.3.0-pre.1, and nife's three pins state version = "0.3.0-pre.1" beside the revision. The architect cleared this crate's review on 2026-11-01 (UTC).

Review before release

Exit

A check proves it. In nife, cargo tree --locked -i jh7110_entropy resolves to v0.1.x from crates.io with a checksum in Cargo.lock, crates/jh7110_entropy no longer exists, and the tree builds for all three targets. In partsfoundry/jh7110_entropy, the run that published 0.1.0 shows the Kani job green ahead of the publish job, and every harness's falsification patch makes its proof fail. The five soak criteria of release step 6 hold before it publishes.

Two checks of the shared template (milestone 887) are this crate's, because it publishes first. calef, 2026-10-22 (UTC): "A: 887 is BUILT once a v7 dry-run release on the canary passes the gate and waits in crates-io for my approval; the first-publish and semver-baseline checks move to 818."

The name check of release step 1 passes first, by Fork 5 of milestone 857. Before the move, script/crate-standalone jh7110_entropy exits 0 in nife, and every row of What is proven names a harness that stock Kani proves in the copy and whose falsification patch makes it fail. No crate publishes without the proofs milestone 857 (crates released on their own) requires.

What the crate no longer cites

The crate's source cites nothing of this tree beyond its Name: blocks. This section keeps the links it carried, by milestone 857's provenance rule.

BUGS

Follow-on

Index row

nife's StarFive JH7110 true random number generator logic, with four Kani proofs and their falsification patches, cut free of nife's device tree. It is published on crates.io as jh7110_entropy 0.1 from its own nifeos repository, and nife consumes that release.