Skip to content

Commit 5d331f7

Browse files
committed
feat: 增强外部中断处理,添加未实现处理的错误提示
1 parent 42968bd commit 5d331f7

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/arch/aarch64/cpu.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,12 @@ impl VCpuOp for CPUState {
190190
}
191191
arm_vcpu::AxVCpuExitReason::SysRegWrite { addr, value } => todo!(),
192192
arm_vcpu::AxVCpuExitReason::ExternalInterrupt => {
193-
axhal::irq::irq_handler(0);
193+
if !axhal::irq::irq_handler(0) {
194+
unimplemented!(
195+
"No handler for external interrupt in vCPU {:#x}",
196+
self.mpidr_el1
197+
);
198+
}
194199
}
195200
arm_vcpu::AxVCpuExitReason::CpuUp {
196201
target_cpu,

0 commit comments

Comments
 (0)