Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ page_table_entry = "0.5"
memory_addr = "0.4"
crate_interface = "0.1"

axaddrspace = { git = "https://github.com/arceos-hypervisor/axaddrspace.git" }
axvcpu = { git = "https://github.com/arceos-hypervisor/axvcpu.git" }
x86_vlapic = { git = "https://github.com/arceos-hypervisor/x86_vlapic.git" }
axdevice_base = { git = "https://github.com/arceos-hypervisor/axdevice_crates.git" }
axvisor_api = { git = "https://github.com/arceos-hypervisor/axvisor_api.git" }
axaddrspace = "0.1"
axvcpu = "0.1"
x86_vlapic = "0.1"
axdevice_base = "0.1"
axvisor_api = "0.1"

spin = { version = "0.9", default-features = false }
spin = { version = "0.10", default-features = false }

[features]
default = ["vmx"]
Expand Down
2 changes: 2 additions & 0 deletions src/vmx/vcpu.rs
Original file line number Diff line number Diff line change
Expand Up @@ -878,6 +878,7 @@ macro_rules! vmx_entry_with {
($instr:literal) => {
unsafe {
naked_asm!(
".code64",
save_regs_to_stack!(), // save host status
"mov [rdi + {host_stack_size}], rsp", // save current RSP to Vcpu::host_stack_top
"mov rsp, rdi", // set RSP to guest regs area
Expand Down Expand Up @@ -922,6 +923,7 @@ impl<H: AxVCpuHal> VmxVcpu<H> {
unsafe extern "C" fn vmx_exit(&mut self) -> usize {
unsafe {
naked_asm!(
".code64",
save_regs_to_stack!(), // save guest status, after this, rsp points to the `VmxVcpu`
"mov rsp, [rsp + {host_stack_top}]", // set RSP to Vcpu::host_stack_top
restore_regs_from_stack!(), // restore host status
Expand Down
Loading