Repository navigation
feat: add hypercall to query ECAM base - #377
Merged
Merged
Conversation
Contributor
|
We'd better not called |
yydawx
force-pushed
the
ecam-dynamic-prob
branch
from
August 10, 2026 02:04
71fc6e6 to
6aa5338
Compare
Contributor
Author
|
Thanks for the review. I updated the implementation to follow your suggestion:
Related hvisor-tool PR: syswonder/hvisor-tool#115. Verification: with zone JSON |
Solicey
approved these changes
Aug 10, 2026
agicy
pushed a commit
that referenced
this pull request
Aug 24, 2026
feat: add hypercall to query ECAM base
agicy
pushed a commit
that referenced
this pull request
Aug 24, 2026
feat: add hypercall to query ECAM base
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.
Motivation
ECAM base can differ across x86_64 devices. hvisor already parses ACPI MCFG, but hvisor-tool needs a way to obtain the correct base before constructing the zone configuration.
Changes
src/hypercall/mod.rs: addHvGetEcamBase = 9hypercall and dispatch it.src/arch/x86_64/hypercall.rs: implementhv_get_ecam_base()to write the ACPI MCFG ECAM base into the caller-provided address.hvisor-tool
hvisor-tool queries this hypercall before starting a zone and overrides
pci_config[0].ecam_base. See syswonder/hvisor-tool#115.Verification
ecam_base=0x12345000; hvisor receives0xe0000000after hvisor-tool correction, Asterinas starts and the shell responds toecho ci-ok.