Skip to content

Conversation

@luodeb
Copy link
Contributor

@luodeb luodeb commented Jun 6, 2025

Add the get_sysreg_device function to enable the virtual machine to register system registers and respond to system register read/write events.

Rely on the following content:
axdevice_base
axvm

TODO:
Wait for other repositories' PRs to be merged, and finally handle this PR.

luodeb and others added 11 commits March 27, 2025 18:31
…er handling

- Add interrupt injection support to Aarch64VCpu
- Implement get_sysreg_device function for system register access
- Update GuestSystemRegisters to include CNTHCTL_EL2
- Modify exception handling to use SysRegAddr
- Adjust vcpu initialization to enable virtual IRQ and FIQ
#26)

* fix(vcpu): correct return value handling for `run_guest` function

- Update the `run_guest` function to properly handle the return value from `vmexit_trampoline`
- Use inline assembly to extract the exit reason from x0 register
- Return the extracted exit reason instead of a dummy value

* format code

* refactor(exception): update vmexit_trampoline and vcpu handling

- Add unsafe annotation to vmexit_trampoline function
- Implement temporary workaround for issue [#22](#22) in vcpu.rs
- Include related PR and issue references in vcpu.rs

* format code

* refactor(exception): remove unnecessary unsafe(naked) attribute

- Replace #[unsafe(naked)] with #[naked] for the vmexit_trampoline function
- This change simplifies the code without affecting functionality

* ci: switch to stable Rust toolchain

- Update dtolnay/rust-toolchain action from nightly to stable
- This change ensures more consistent and reliable builds

* ci: update Rust toolchain to nightly-2024-12-25 for documentation build

* ci: fix incorrect way to specify rust toolchain version in doc job

---------

Co-authored-by: aarkegz <[email protected]>
…issue (#28)

* add a `#[naked]` version of `run_guest`, to be tested

* remove the old version of `run_guest`

* formatted

* add more detailed comments

* mark `run_guest_panic` as never returns

* add a paragraph describing why using x0 is safe
- Remove unused imports for GuestPhysAddrRange and BaseMmioDeviceOps
- Simplify import statements for axaddrspace and aarch64_cpu
- Update function parameters to use _ to ignore unused values
@luodeb luodeb marked this pull request as draft June 20, 2025 09:26
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.

5 participants