Skip to content

x86 boot thread starves: timer preempts it during busy-spin disk-completion wait, so test_exec self-tests may not complete #508

Description

@ryanbreen

After the RING3_SMOKE fix (#506/#507), boot-time disk loads run with interrupts hardware-enabled and preempt_disable() gating the scheduler; but direct boot testing showed the timer interrupt can STILL switch away from the boot thread during the busy-spin disk-completion wait window, so the ~450 lines of test_exec::test_*() calls between the first RING3_SMOKE block (kernel/src/main.rs ~1002) and the deliberate final interrupts::enable() (~1657) do NOT reliably run to completion.

This is a gap between the preempt_count primitive and this kernel's can_schedule()/scheduler-starvation behavior (per_cpu.rs can_schedule + timer set_need_resched).

Reproduces on unmodified merged main. Per CLAUDE.md this interrupt/scheduler issue needs a dedicated GDB-driven RCA, not log-based debugging. x86-specific boot path.

Surfaced during #498 x86-boot work (context: PRs #506, #507).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions