ASELSANMicrokernel
S310 · SOURCE-BOUND GATE EVIDENCE

G8l: QEMU S139 multi-event transport writer-authority audit

Operations --test hedefi → test hedefiyle aynı adlı uygulama/model modülü → kaynak kesiti Bu sayfa yalnız S310 kapısına aittir; komşu kapıların kaynakları bu kabulün içine katılmaz.

S310Focused kod testiOperations id exactsource SHA exacttest target exact

operation: g8l-s310-qemu-s139-multi-event-transport-writer-authority-audit-partial

uygulama/model · focused test · Operations · 3 exact excerpt

sequence-bound=true · implementation-bound=true
01 · Testin bağlı olduğu uygulama/model kodu

Kapının yürüttüğü gerçek kaynak

tam Rust öğesiL31–L101
kernel/src/g8l_target_dispatch_scheduler_owner_scheduler_mutation_production_migration_lifecycle_s310_qemu_s139_multi_event_transport_writer_authority_audit.rs::S310_S139_CALLER_REMAINING_UNAUDITED_WRITER_SITES
pub const S310_WRITER_AUTHORITY_SITES: usize = 0;
pub const S310_MAIN_EXPLICIT_WRITER_SITES: usize = 17;
pub const S310_MAIN_REMAINING_UNAUDITED_WRITER_SITES: usize = 16;
pub const S310_S139_CALLER_EXPLICIT_WRITER_SITES: usize = 2;
pub const S310_S139_CALLER_REMAINING_UNAUDITED_WRITER_SITES: usize = 1;
pub const S310_DIRECT_SCHEDULER_ACCESS_SITES: usize = S309_DIRECT_SCHEDULER_ACCESS_SITES;
pub const S310_IMMUTABLE_READ_SITES: usize = S309_IMMUTABLE_READ_SITES;
pub const S310_WHOLE_SCHEDULER_GUARDED_SITES: usize = S309_WHOLE_SCHEDULER_GUARDED_SITES;
pub const S310_WHOLE_SCHEDULER_UNROUTED_SITES: usize = S309_WHOLE_SCHEDULER_UNROUTED_SITES;
pub const S310_OPEN_WRITER_SITES: usize = S309_OPEN_WRITER_SITES;

#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum G8lS310SchedulerWriterAuthorityAuditOutcome {
    Idle,
    AwaitingWriterAuthority {
        request_id: u64,
        guarded_sites: usize,
        writer_sites: usize,
    },
}

#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum G8lS310SchedulerWriterAuthorityAuditError {
    S309(G8lS309SchedulerWriterAuthorityAuditError),
    S245(G8lS245ExclusionAdmissionRequestError),
    PriorCoverageDrift {
        guarded_sites: usize,
        unrouted_sites: usize,
    },
}

/// Revalidate the prior fail-closed authority boundary without taking
/// admission or constructing a production exclusive wrapper.
pub fn preflight_s310_scheduler_writer_authority(
    caller_cpu: usize,
    request: Option<G8lS245WholeSchedulerExclusionAdmissionRequestView>,
) -> Result<G8lS310SchedulerWriterAuthorityAuditOutcome, G8lS310SchedulerWriterAuthorityAuditError>
{
    match preflight_s309_scheduler_writer_authority(caller_cpu, request)
        .map_err(G8lS310SchedulerWriterAuthorityAuditError::S309)?
    {
        G8lS309SchedulerWriterAuthorityAuditOutcome::Idle => {
            Ok(G8lS310SchedulerWriterAuthorityAuditOutcome::Idle)
        }
        G8lS309SchedulerWriterAuthorityAuditOutcome::AwaitingWriterAuthority {
            request_id,
            guarded_sites,
            writer_sites,
        } if guarded_sites == S310_WHOLE_SCHEDULER_GUARDED_SITES
            && writer_sites == S310_OPEN_WRITER_SITES =>
        {
            Ok(
                G8lS310SchedulerWriterAuthorityAuditOutcome::AwaitingWriterAuthority {
                    request_id,
                    guarded_sites,
                    writer_sites,
                },
            )
        }
        G8lS309SchedulerWriterAuthorityAuditOutcome::AwaitingWriterAuthority {
            guarded_sites,
            writer_sites: _,
            ..
        } => Err(
            G8lS310SchedulerWriterAuthorityAuditError::PriorCoverageDrift {
                guarded_sites,
                unrouted_sites: S310_DIRECT_SCHEDULER_ACCESS_SITES - guarded_sites,
            },
        ),
    }
}
snippet sha256: 5d469df29602file sha256: 84a45e943ad3
02 · Doğrulayan test kodu

Operations komutuna bağlı focused test

tam Rust öğesiL298–L337
simulation/tests/g8l_target_dispatch_scheduler_owner_scheduler_mutation_production_migration_lifecycle_s310_qemu_s139_multi_event_transport_writer_authority_audit.rs::s310_helper_revalidates_kernel_caller_send_and_linked_reply_under_transaction

#[test]
fn s310_helper_revalidates_kernel_caller_send_and_linked_reply_under_transaction() {
    let source = include_str!("../../kernel/src/task/scheduler.rs");
    let helper = kernel_call_and_wait_boundary(source);
    for required in [
        "IrqGuard::new()",
        "IPC_TRANSACTION_LOCK.lock()",
        "IPC_CALL_DEADLINES.lock()",
        ".filter(|task| !task.is_user)",
        ".filter(|task_id| *task_id != 0)",
        "current_endpoint_authority_is_live(",
        "CapabilityRights::ENDPOINT_SEND",
        "ENDPOINT_REGISTRY.lock()",
        "endpoint.id == target_endpoint && !endpoint.is_reply_cap",
        "endpoint.id == reply_cap_id",
        "endpoint.is_reply_cap",
        "endpoint.owner == caller_task",
        "endpoint.reply_target == Some(target_endpoint)",
        "if !reply_is_linked",
    ] {
        assert!(
            helper.contains(required),
            "missing S310 helper authority token: {required}"
        );
    }
    let irq = helper.find("IrqGuard::new()").unwrap();
    let transaction = helper.find("IPC_TRANSACTION_LOCK.lock()").unwrap();
    let caller = helper.find("let caller_task").unwrap();
    let send = helper.find("current_endpoint_authority_is_live(").unwrap();
    let endpoints = helper.find("ENDPOINT_REGISTRY.lock()").unwrap();
    let reply = helper.find("let reply_is_linked").unwrap();
    assert!(
        irq < transaction
            && transaction < caller
            && caller < send
            && send < endpoints
            && endpoints < reply
    );
}
snippet sha256: d7e1e179fca7file sha256: f39a27bd13ca
03 · Kapı kimlik kaydı

Operations sıra, kimlik ve başlık bağı

tam Operations kaydıL15691–L15753
website/src/lib/operations.ts::g8l-s310-qemu-s139-multi-event-transport-writer-authority-audit-partial
  {
    id: "g8l-s310-qemu-s139-multi-event-transport-writer-authority-audit-partial",
    date: "2026-08-27",
    sequence: 310,
    status: "passed",
    umbrella_status: "partial",
    title: "G8l: QEMU S139 multi-event transport writer-authority audit",
    summary:
      "S310 focused 15/15 PASS ile main.rs içindeki kaynak sırasına göre en alttaki explicit mutable scheduler aliasını doğrular: qemu_s139_multi_event_caller normal exact-ACK yolundaki ipc_kernel_call_and_wait sınırı. Nonzero kernel caller, current-task CNode exact Endpoint generation/ENDPOINT_SEND authority ve linked reply-cap mint iki alias öncesinde doğrulanır. QueueFull probe dalı unpublished reply cleanup/result publication/task_exit ile normal yoldan terminal ayrılır. Normal yol exact broker lease ve message'i kurup endpoint/generation/reply/message zarfını helper'a forward eder; helper existing IRQ/IPC transaction altında non-user caller SEND authority, normal endpoint, linked reply, optional receiver authority/deadline ve ready/blocked capacity'yi yeniden doğrular, CALL'u publish/park eder, optional receiver'ı uyandırır, aynı kernel caller continuation'ını doğrular ve exact ACK'i reconstruct eder. Writer authority yalnız model gate'inin exclusive lease'iyle mümkündür; reader lease'i writer'ı açmaz. main.rs 17 explicit writer / 16 remaining unaudited, qemu_s139_multi_event_caller 2 / 1; production inventory 113 direct / 44 immutable guarded / 69 open writer olarak değişmez ve production exclusive wrapper, provider authority, whole-scheduler exclusion veya scheduler mutation üretilmez.",
    evidence: [
      "S310 focused kaynak/model kapısı iki bağımsız koşuda 15/15 PASS verdi: 130 B / SHA-256 0447f2fe9dc6fdf30815a6962cf23d978425e51bef2acde1efb27e5da13a78b3.",
      "main.rs içindeki 17 explicit addr_of_mut!(crate::task::scheduler::SCHEDULER) sitesinin kaynakta en alttaki sınırı audit edilir. qemu_s139_multi_event_caller 2 explicit alias taşır; S310 normal exact-ACK aliasını kapatır ve işlevdeki QueueFull probe aliası ile main.rs genelinde 16 alias ayrıca açık kalır.",
      "QEMU_S139_TRANSPORT_STATE, nonzero current kernel caller, controller/supervisor ayrıklığı, bounded caller index, current-task CNode exact Endpoint owner/parent/nonzero generation/ENDPOINT_SEND authority ve mint_reply_endpoint_for_call iki writer aliasından önce gelir.",
      "caller_index == QEMU_S139_BATCH overflow dalı exact queued/in-flight full snapshot, overflow message, QueueFull sonucu, discard_unpublished_reply_endpoint, QEMU_S139_QUEUE_FULL result publication ve task_exit ile normal transport yolundan terminal ayrılır.",
      "Normal yol Acquire tick snapshot, claim_next exact broker lease, sequence identity ve event sequence/source/epoch/fingerprint message'ini writer'dan önce kurar. ipc_kernel_call_and_wait(state.endpoint_id, endpoint_authority.generation, reply_cap.id, message) exact forward edilir; reply label/badge/data doğrulanır, exact acknowledge yapılır ve stale expiry reddedilir.",
      "Scheduler helper IrqGuard/IPC_TRANSACTION_LOCK altında non-user nonzero caller, canlı SEND generation, normal target endpoint, caller-owned linked reply object, optional waiting receiver state/RECV authority/generation/deadline ve ready/blocked capacity koşullarını yeniden doğrular.",
      "Rendezvous CALL publication exact caller/reply/message ile yapılır ve finish_call_park exact Park ister. Caller reply endpoint üzerinde BlockedOnIpc/is_call:true olarak blocked listeye alınır; optional receiver deadline retirement/delivery/Ready enqueue yapılır. Lock'lar bırakıldıktan sonra switch gerçekleşir; aynı non-user caller continuation'ı Ok status/gpr7=0 ile doğrulanıp label/badge/MR0–MR3 exact reply olarak reconstruct edilir.",
      "Model gate reader membership exclusive writer authority'yi ExclusiveBusy ile bloklar; reader bırakıldıktan sonra non-zero token'lı exclusive lease alınır. Bu host/model evidence'tır.",
      "S309 authority preflight yeniden doğrulanır; pending S245 request korunur ve sonuç AwaitingWriterAuthority { guarded_sites: 44, writer_sites: 69 } olarak döner.",
      "Dört AArch64 profil derlemesi iki koşuda byte-equal exit 0 verdi: QEMU 110646 B / def0482e, RPi4 149371 B / b3bae800, RPi5 435762 B / eb2ed414 ve RPi5+SMP 435704 B / 657901f2. Warning header'ları sırasıyla 291, 389, 915 ve 915'tir; zero-warning iddiası değildir.",
      "Birleşik board-rpi5,board-qemu özellikleri iki koşuda beklenen exit 101, 18590 B / 89741d28, 17 error ve 22 warning header ile fail-closed kaldı; S310 writer boundary'si iki board profilinin birlikte etkinleşmesini açmaz.",
      "S238–S310 dependency matrisi iki koşuda 74 grup / 1034/1034 PASS; ham loglar byte-equal 9542 B / 37e1025d8aebf92618241b2940b12ca5cdf96f42dcac4c1ce896d4caaa024bb6, süre-normalize özetler byte-equal 9690 B / 51a044eb61dfd080e8bcefc9bd7560a4d1a7da9302fdde4a9f34a0de29c7d153. Bu production writer-authority invocation kanıtı değildir.",
      "Ortak make verify-qemu iki koşuda PASS verdi: 116222 B / 70f97bf0 ve 116139 B / f9442d43; guest logları 2108177 B / 86bbd10f ve 2100653 B / 69ed5fa0. W^X 31/31, S271 GRAPH_ABSENT=YES, RuntimePmm baseline, EL0 x4096, IPC 20/20, koşu başına tek S142 containment, SEC5 ve 13 KERNEL_FAULTS=0 marker'ı korunur. Bu ortak smoke S310 production writer-authority invocation kanıtı değildir.",
      "Exact yedi tarihsel G8h assertion adıyla dışlandığında workspace iki koşuda 272 sonuç grubu / 2833 PASS / 7 filtered verdi: ham loglar 323682 B / 691c31f3 ve 323564 B / ae146ce9, sonuç özetleri 25721 B / 4c6fe298 ve 4d131bd6, süre-normalize 26265 B özet byte-equal / SHA-256 377b82e1d458b93df6437e50b9557daa8bc5c336fde34dbaff9c588b65e7587d. Filtresiz koşu exit 101, 292018 B / ddd0f277 ile frozen S96 exceptions.S identity kapısında RED kaldı; full-workspace GREEN iddia edilmez.",
      "S310 production exclusive wrapper, provider authority, whole-scheduler exclusion, QEMU fixture mutation veya scheduler mutation iddiası eklemez; physical/device operations=0 ve RUNBOOK_EXECUTED_IN_S310=NO.",
    ],
    commands: [
      "cargo test --quiet -p aselsan_microkernel_simulation --test g8l_target_dispatch_scheduler_owner_scheduler_mutation_production_migration_lifecycle_s310_qemu_s139_multi_event_transport_writer_authority_audit -- --test-threads=1",
      "cargo check --quiet -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-qemu",
      "cargo check --quiet -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi4",
      "cargo check --quiet -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi5",
      "cargo check --quiet -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi5,smp",
      "cargo check --quiet -p aselsan_kernel --target aarch64-unknown-none --features board-rpi5",
      "make verify-qemu",
    ],
    terminalSessions: [
      {
        id: "g8l-s310-qemu-s139-multi-event-transport-writer-authority-audit",
        title:
          "G8l S310 QEMU S139 multi-event transport writer-authority audit",
        commandLines: [
          "cargo test --quiet -p aselsan_microkernel_simulation --test g8l_target_dispatch_scheduler_owner_scheduler_mutation_production_migration_lifecycle_s310_qemu_s139_multi_event_transport_writer_authority_audit -- --test-threads=1",
        ],
        outputLines: [
          "test result: ok; S310 focused 1 group / 15 passed; 0 failed",
          "repeat-stable quiet output: 130 B / 0447f2fe9dc6fdf30815a6962cf23d978425e51bef2acde1efb27e5da13a78b3",
          "QEMU S139 normal transport writer authority remains model-only: exact caller/SEND/reply/lease/message forwarding and helper park-delivery-resume paths are source-audited; main.rs retains 16 unaudited aliases and all 69 production writer sites remain open",
          "dependency: S238–S310 · 74 groups · 1034/1034 PASS; workspace: 272 groups · 2833 PASS · 7 historical filtered",
        ],
        exitCode: 0,
        outputMode: "selected",
      },
    ],
    terminalSessionsNote:
      "S310 kaynak/model fail-closed authority boundary'sidir; production writer guard/migration, QEMU fixture mutation ve fiziksel/device execution claim edilmez.",
    limitations: [
      "S310 main.rs içindeki kaynakta en alttaki qemu_s139_multi_event_caller normal exact-ACK mutable scheduler aliasını audit eder; aynı işlevde 1 ve main.rs genelinde 16 alias ile toplam 69 production writer site authority wrapper dışında açık kalır.",
      "Exclusive lease yalnız host/model gate'inde test edilir; production exclusive wrapper, provider authority ve whole-scheduler exclusion açık kalır.",
      "S238–S310 dependency matrisi exact 74 grup / 1034/1034 PASS'tir; bu production writer authority invocation kanıtı değildir.",
      "Filtresiz workspace frozen S96 identity kapısında RED'dir; workspace umbrella GREEN iddia edilmez.",
      "Supported-profile writer-authority runtime invocation, Generic SMP ve fiziksel RPi kabulü açık kalır; S310 physical/device operations=0 ve RUNBOOK_EXECUTED_IN_S310=NO.",
    ],
  },
snippet sha256: 80c2dd1de13dfile sha256: 9726dbf00f84
Focused test komutu
cargo test --quiet -p aselsan_microkernel_simulation --test g8l_target_dispatch_scheduler_owner_scheduler_mutation_production_migration_lifecycle_s310_qemu_s139_multi_event_transport_writer_authority_audit -- --test-threads=1
proof: docs/M8.1-RPi5-G8l-S310-QEMU-S139-Multi-Event-Transport-Writer-Authority-Audit-Proof.md
Registry schema v5 · generator website/scripts/generate-code-gates.mjs · Tam SHA-256: 3050638b71a684d8f8f947a8a6faa237a17fa8db5dc0db04fb207b668b462af9