Skip to content

Fs55 ethernet integration#75

Merged
adybag14-cyber merged 2 commits intomainfrom
fs55-ethernet-integration
Mar 21, 2026
Merged

Fs55 ethernet integration#75
adybag14-cyber merged 2 commits intomainfrom
fs55-ethernet-integration

Conversation

@adybag14-cyber
Copy link
Owner

@adybag14-cyber adybag14-cyber commented Mar 21, 2026

Summary by CodeRabbit

  • New Features

    • Added a read-only /dev device overlay exposing synthetic device entries and state information for storage, display, and network components.
  • Documentation

    • Updated documentation to reflect the fourth adoption slice delivery with enhanced device introspection capabilities.

@adybag14-cyber adybag14-cyber merged commit 94ca07d into main Mar 21, 2026
16 checks passed
@coderabbitai
Copy link

coderabbitai bot commented Mar 21, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: da5e8538-278d-4534-aed5-d52e72e9f1f8

📥 Commits

Reviewing files that changed from the base of the PR and between c8a99a5 and c9026c0.

📒 Files selected for processing (11)
  • README.md
  • docs/zig-port/FS5_5_HARDWARE_DRIVERS_SYSTEMS.md
  • docs/zig-port/PHASE_CHECKLIST.md
  • docs/zig-port/PORT_PLAN.md
  • docs/zig-port/ZAR_VS_ZIGOS_INTEGRATION_PLAN.md
  • scripts/baremetal-qemu-e1000-tool-service-probe-check.ps1
  • src/baremetal/filesystem.zig
  • src/baremetal/tool_exec.zig
  • src/baremetal/tool_service.zig
  • src/baremetal/virtual_fs.zig
  • src/baremetal_main.zig

📝 Walkthrough

Walkthrough

This PR introduces a fourth adoption slice implementing a ZAR-native, read-only /dev device overlay alongside existing /proc and /sys overlays. The virtual filesystem now synthesizes /dev entries (storage, display, net, null) backed by existing ZAR state; filesystem and tool-service layers route read operations through this overlay while rejecting writes; and the E1000 tool-service probe validates live /dev functionality.

Changes

Cohort / File(s) Summary
Documentation Updates
README.md, docs/zig-port/FS5_5_HARDWARE_DRIVERS_SYSTEMS.md, docs/zig-port/PHASE_CHECKLIST.md, docs/zig-port/PORT_PLAN.md, docs/zig-port/ZAR_VS_ZIGOS_INTEGRATION_PLAN.md
Updated delivery status from 3 to 4 adoption slices; replaced /proc+/sys introspection overlay references with /dev device overlay; expanded scope rules to allow ZAR-owned and explicitly labeled adapted/imported code; updated proof script coverage expectations.
Virtual Filesystem Implementation
src/baremetal/virtual_fs.zig
Added /dev subtree with storage, display, net directories and null file; synthesizes entries from existing ZAR state; refactored display output path parsing/construction to support both /sys and /dev output queries via generalized helpers.
Filesystem and Tool-Service Integration
src/baremetal/filesystem.zig, src/baremetal/tool_exec.zig, src/baremetal/tool_service.zig
Extended read/list/stat operations to route through /dev overlay; added comprehensive test coverage for /dev paths (storage/state, display, net); confirmed write rejection for all /dev operations.
E1000 Tool-Service Probe Validation
src/baremetal_main.zig
Added live probe exchanges: LIST /dev and GET /dev/storage/state; validates response content and directory structure; includes debug markers for tracing.
Script Artifact Validation
scripts/baremetal-qemu-e1000-tool-service-probe-check.ps1
Added Resolve-TemporaryRoot and Test-CompilerRtArchiveElf functions; Resolve-CompilerRtArchive now validates multiple libcompiler_rt.a candidates via ELF magic number checks before returning the first valid archive.

Sequence Diagram(s)

sequenceDiagram
    actor Client as Tool-Service Client
    participant TService as Tool-Service
    participant FSLayer as Filesystem Layer
    participant VFS as Virtual FS
    participant State as ZAR State/Display/Net

    Client->>TService: GET /dev/storage/state
    TService->>FSLayer: readFileAlloc("/dev/storage/state")
    FSLayer->>VFS: recognize /dev path
    VFS->>State: fetch storage state
    State-->>VFS: backend=ram_disk
    VFS-->>FSLayer: render response
    FSLayer-->>TService: file content
    TService-->>Client: RESP with backend info

    Client->>TService: LIST /dev
    TService->>FSLayer: listDirectoryAlloc("/dev")
    FSLayer->>VFS: enumerate /dev children
    VFS->>State: query device directories
    State-->>VFS: storage, display, net, null
    VFS-->>FSLayer: directory entries
    FSLayer-->>TService: entry list
    TService-->>Client: RESP with dir/file entries

    Client->>TService: WRITE /dev/storage/state
    TService->>FSLayer: writeFile("/dev/storage/state", ...)
    FSLayer->>VFS: check /dev write permission
    VFS-->>FSLayer: error.ReadOnlyPath
    FSLayer-->>TService: error
    TService-->>Client: RESP error
Loading

Possibly related issues

Possibly related PRs

Poem

🐰 A fourth slice hops into view, /dev now overlaid anew,

Storage, display, networks all shine through the virtual device line,

Read-only, bounded, and clean—the finest /dev you've seen!

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fs55-ethernet-integration

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant