feat(arm-qemu-virt): add initial support for ARM QEMU platform#32
Open
luodeb wants to merge 29 commits intoarceos-org:mainfrom
Open
feat(arm-qemu-virt): add initial support for ARM QEMU platform#32luodeb wants to merge 29 commits intoarceos-org:mainfrom
luodeb wants to merge 29 commits intoarceos-org:mainfrom
Conversation
Contributor
|
Please rebase it first. |
equation314
reviewed
Dec 21, 2025
Member
|
Cloud you also update the examples for the arm platform? |
equation314
reviewed
Jan 22, 2026
equation314
reviewed
Jan 22, 2026
equation314
reviewed
Jan 22, 2026
equation314
reviewed
Jan 26, 2026
There was a problem hiding this comment.
Pull request overview
Adds an initial ARM (armv7a) QEMU virt platform crate and wires it into the workspace, examples, and CI so the existing example kernels can be built for armv7a-none-eabi.
Changes:
- Introduces
platforms/axplat-arm-qemu-virtwith boot/MMU setup, memory translation, init, timer, and power interfaces. - Updates example kernels (hello/irq/smp) to support
ARCH=armbuilds and QEMU invocation. - Extends workspace membership and CI target matrices to include
armv7a-none-eabi.
Reviewed changes
Copilot reviewed 29 out of 30 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
| platforms/axplat-arm-qemu-virt/src/power.rs | PSCI-based power + SMP boot hook for ARM QEMU virt |
| platforms/axplat-arm-qemu-virt/src/mem.rs | Physical/virtual translation + RAM/MMIO ranges for the platform |
| platforms/axplat-arm-qemu-virt/src/lib.rs | Platform crate root + config include + interface wiring |
| platforms/axplat-arm-qemu-virt/src/init.rs | Early/later init (UART, PSCI, GIC, timer IRQ enable) |
| platforms/axplat-arm-qemu-virt/src/generic_timer.rs | ARM timer-backed TimeIf implementation + oneshot timer |
| platforms/axplat-arm-qemu-virt/src/boot.rs | ARM32 boot entry + page table setup + MMU enable trampoline |
| platforms/axplat-arm-qemu-virt/build.rs | Rebuild triggers for config path env var |
| platforms/axplat-arm-qemu-virt/axconfig.toml | Default platform configuration for ARM QEMU virt |
| platforms/axplat-arm-qemu-virt/Cargo.toml | New platform crate manifest + dependencies/features |
| examples/smp-kernel/src/main.rs | Adds cfg(target_arch="arm") platform selection |
| examples/smp-kernel/linker.lds.S | Discards .ARM.exidx* in linker script |
| examples/smp-kernel/build.rs | Adds ARM kernel base selection for linker script generation |
| examples/smp-kernel/README.md | Documents arm as supported ARCH |
| examples/smp-kernel/Makefile | Adds ARCH=arm target triple and QEMU args |
| examples/smp-kernel/Cargo.toml | Adds ARM-specific platform dependency |
| examples/irq-kernel/src/main.rs | Adds cfg(target_arch="arm") platform selection |
| examples/irq-kernel/linker.lds.S | Discards .ARM.exidx* in linker script |
| examples/irq-kernel/build.rs | Adds ARM kernel base selection for linker script generation |
| examples/irq-kernel/README.md | Documents arm as supported ARCH |
| examples/irq-kernel/Makefile | Adds ARCH=arm target triple and QEMU args |
| examples/irq-kernel/Cargo.toml | Adds ARM-specific platform dependency |
| examples/hello-kernel/src/main.rs | Adds cfg(target_arch="arm") platform selection |
| examples/hello-kernel/linker.lds.S | Discards .ARM.exidx* in linker script |
| examples/hello-kernel/build.rs | Adds ARM kernel base selection for linker script generation |
| examples/hello-kernel/README.md | Documents arm as supported ARCH |
| examples/hello-kernel/Makefile | Adds ARCH=arm target triple and QEMU args |
| examples/hello-kernel/Cargo.toml | Adds ARM-specific platform dependency |
| Cargo.toml | Adds the new platform crate to workspace members |
| Cargo.lock | Locks new/updated dependencies pulled in by ARM support |
| .github/workflows/ci.yml | Adds armv7a-none-eabi to CI build/clippy matrices |
Comments suppressed due to low confidence (1)
platforms/axplat-arm-qemu-virt/Cargo.toml:25
- This crate depends on
axplat-aarch64-peripherals, whosegeneric_timerimplementation uses AArch64 system registers (CNTFRQ_EL0,CNTP_*_EL0, etc.). That dependency may not compile fortarget_arch = "arm"(and even if it compiles, parts of it are AArch64-specific). Consider splitting peripherals into arch-neutral vs arch-specific modules (or introducing anaxplat-arm-peripheralscrate) so the ARMv7 build doesn’t pull in AArch64-only code.
axplat = { workspace = true }
axplat-aarch64-peripherals = { path = "../axplat-aarch64-peripherals" }
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
equation314
reviewed
Mar 1, 2026
equation314
reviewed
Mar 4, 2026
equation314
reviewed
Mar 10, 2026
Enables symmetric multiprocessing by introducing secondary CPU boot sequence, updates dependencies, and clarifies memory mapping for QEMU ARM virt. Improves IRQ initialization and exposes configurable CPU count for better scalability and maintainability.
Streamlines code by cleaning up unused commented imports, reducing clutter and improving maintainability.
…age table structure and memory mappings
…n Cargo.toml refactor(boot): replace BootPageTable with Aligned4K for better alignment refactor(generic_timer): remove inline assembly functions and use axcpu::asm directly
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.