Files
StarForth/src/starkernel/capsule
Robert Allan JamesandClaude Sonnet 5 b0416794de starkernel: item 2.2 complete -- bound the VM registry
Wires the birth-refusal check into capsule_birth_baby(): calls
vm_registry_live_count() (added in the prior WIP commit) between
capsule validation and vm_registry_alloc(), returning the new
CAPSULE_RUN_ERR_FLEET_FULL and logging via
capsule_parity_log_birth_failed() before any EMBRYO registry slot is
consumed.

Also fixes a gap in that WIP commit: STADIUM_MAX_VM_COUNT was only
ever defined via a Kconfig .config-driven -D flag, with no fallback
default the way every sibling knob in starforth_config.h has -- a
build with no .config present (this one) failed with the macro
undeclared. Added STARFORTH_CONFIG_STADIUM_MAX_VM_COUNT_DEFAULT (4,
matching Kconfig.kernel) following the existing HEARTBEAT_INFERENCE_FREQUENCY
pattern exactly.

All three architectures boot clean to ok> with dict_hash=0x3d4e1daf289da94f,
matching the item-0.10/2.1 baseline. FABRIC.md item 2.2 checked off.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-04 13:54:22 -04:00
..

src/starkernel/capsule/

Kernel-side capsule system: locating, validating, and executing the immutable, content-addressed .4th initialization payloads in capsules/ (embedded into the kernel image via tools/mkcapsule.c).

  • capsule_find.c — locates a capsule by name in the generated capsule directory.
  • capsule_validate.c — validates a capsule's content hash before use.
  • capsule_birth.c — the birth protocol: allocate VM ID → execute IDENTITY (capsule code) → execute PERSONALITY (block 1 from ramdrive) → log parity record.
  • capsule_run.c — capsule execution against a VM instance.
  • capsule_loader.c — loads capsule block content into kernel ramdrive block RAM, writing each Block N header to its literal numbered block address (not reordered).
  • capsule_vm_hooks.c — VM integration hooks for capsule execution.
  • capsule_vm_physics.c — physics-runtime bindings for capsule-birthed VMs.
  • mama_forth_words.c — Mama VM-specific FORTH word bindings.