feat(boards): both systems on every board image, chosen at boot -- system=v3 or system=v4
boards/BRINGUP.md A6, FABRIC-3 SXLIII (ruled: one image, switch at boot). A STARFORTH_V4 kernel carries v3 too; system= in the boot arguments chooses, else the build's default (V4_DEFAULT: 1 for plain STARFORTH_V4 builds as before, 0 for board images). make boot_image builds both and always writes starforth.cfg / cmdline.txt with system=v3 first, and cleans its ISA's objects first -- that clean was removing build/<arch>/SER5, not the kernel's objects, until fixed here. Each ISA: v3 by default (hash unchanged), v4 with system=v4 (538/538). The SER5 image under OVMF: v3 as built, v4 after a one-word edit on it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
e729c64ba3
commit
1a4b163861
@@ -561,12 +561,31 @@ static void kernel_main_deep(BootInfo *boot_info) {
|
||||
console_println("Kernel initialization complete.");
|
||||
console_println("Boot successful!\n");
|
||||
|
||||
/* Which system runs (boards/BRINGUP.md A6, ruled 2026-10-14: one image,
|
||||
* both systems, chosen at boot). A kernel built with STARFORTH_V4
|
||||
* carries v4 as well as v3; `system=v3` or `system=v4` among the boot
|
||||
* arguments (starforth.cfg on the ESP, cmdline.txt on the Pi 5) picks,
|
||||
* else the build's default (SK_V4_DEFAULT: on for a plain STARFORTH_V4
|
||||
* build, off for a board image). */
|
||||
#ifdef STARFORTH_V4
|
||||
/* StarForth v4 at a single prompt (Kconfig STARFORTH_V4): one host node
|
||||
* of the F18-derived engine, in place of the v3 VM and everything below.
|
||||
* It does not return. */
|
||||
sk_v4_boot_info = boot_info;
|
||||
sk_v4_run(sk_v4_block_chain);
|
||||
if (boot_info->args.system == KARGS_SYSTEM_V4 ||
|
||||
(boot_info->args.system == KARGS_SYSTEM_DEFAULT && SK_V4_DEFAULT)) {
|
||||
console_println(boot_info->args.system == KARGS_SYSTEM_V4
|
||||
? "System: StarForth v4 (system=v4)"
|
||||
: "System: StarForth v4 (this build's default)");
|
||||
/* StarForth v4 at a single prompt: one host node of the F18-derived
|
||||
* engine, in place of the v3 VM and everything below. It does not
|
||||
* return. */
|
||||
sk_v4_boot_info = boot_info;
|
||||
sk_v4_run(sk_v4_block_chain);
|
||||
}
|
||||
console_println(boot_info->args.system == KARGS_SYSTEM_V3
|
||||
? "System: StarForth v3 (system=v3)"
|
||||
: "System: StarForth v3 (this build's default; system=v4 for v4)");
|
||||
#else
|
||||
console_println(boot_info->args.system == KARGS_SYSTEM_V4
|
||||
? "System: StarForth v3 -- system=v4 asked for, and this kernel has no v4"
|
||||
: "System: StarForth v3");
|
||||
#endif
|
||||
|
||||
#ifdef STARFORTH_ENABLE_VM
|
||||
|
||||
Reference in New Issue
Block a user