Skip to content

Commit b3e79d4

Browse files
committed
[feat] introduce the concept of GeneralRegisters
1 parent 9873b98 commit b3e79d4

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/vmx/vcpu.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1411,6 +1411,16 @@ impl<H: AxVCpuHal> AxArchVCpu for VmxVcpu<H> {
14111411
}
14121412

14131413
impl<H: AxVCpuHal> AxVcpuAccessGuestState for VmxVcpu<H> {
1414+
type GeneralRegisters = GeneralRegisters;
1415+
1416+
fn regs(&self) -> &Self::GeneralRegisters {
1417+
self.regs()
1418+
}
1419+
1420+
fn regs_mut(&mut self) -> &mut Self::GeneralRegisters {
1421+
self.regs_mut()
1422+
}
1423+
14141424
fn read_gpr(&self, reg: usize) -> usize {
14151425
self.regs().get_reg_of_index(reg as u8) as usize
14161426
}

0 commit comments

Comments
 (0)