MCPcopy Create free account
hub / github.com/Simple-XX/SimpleKernel / ExternalInterruptHandler

Function ExternalInterruptHandler

src/arch/riscv64/interrupt_main.cpp:26–33  ·  view source on GitHub ↗

外部中断分发器:CPU 外部中断 -> PLIC -> 设备 handler

Source from the content-addressed store, hash-verified

24
25// 外部中断分发器:CPU 外部中断 -> PLIC -> 设备 handler
26auto ExternalInterruptHandler(uint64_t /*cause*/, cpu_io::TrapContext* context)
27 -> uint64_t {
28 auto& plic = InterruptSingleton::instance().plic();
29 auto source_id = plic.Which();
30 plic.Do(source_id, context);
31 plic.Done(source_id);
32 return 0;
33}
34
35// ebreak 中断处理
36auto EbreakHandler(uint64_t exception_code, cpu_io::TrapContext* context)

Callers

nothing calls this directly

Calls 4

plicMethod · 0.80
WhichMethod · 0.80
DoneMethod · 0.80
DoMethod · 0.45

Tested by

no test coverage detected