/DragonOS/kernel/src/arch/riscv64/ |
H A D | kprobe.rs | 49 fn from(trap_frame: &TrapFrame) -> Self { in from() 51 pc: trap_frame.epc, in from() 52 ra: trap_frame.ra, in from() 53 sp: trap_frame.sp, in from() 54 gp: trap_frame.gp, in from() 55 tp: trap_frame.tp, in from() 56 t0: trap_frame.t0, in from() 57 t1: trap_frame.t1, in from() 58 t2: trap_frame.t2, in from() 59 s0: trap_frame.s0, in from() [all …]
|
/DragonOS/kernel/src/arch/riscv64/interrupt/ |
H A D | handle.rs | 35 unsafe extern "C" fn riscv64_do_irq(trap_frame: &mut TrapFrame) { in riscv64_do_irq() 36 if trap_frame.cause.is_interrupt() { in riscv64_do_irq() 37 riscv64_do_interrupt(trap_frame); in riscv64_do_irq() 38 } else if trap_frame.cause.is_exception() { in riscv64_do_irq() 39 riscv64_do_exception(trap_frame); in riscv64_do_irq() 44 fn riscv64_do_interrupt(trap_frame: &mut TrapFrame) { in riscv64_do_interrupt() 45 riscv_intc_irq(trap_frame); in riscv64_do_interrupt() 49 fn riscv64_do_exception(trap_frame: &mut TrapFrame) { in riscv64_do_exception() 50 let code = trap_frame.cause.code(); in riscv64_do_exception() 54 handler(trap_frame).ok(); in riscv64_do_exception() [all …]
|
/DragonOS/kernel/src/arch/x86_64/ |
H A D | kprobe.rs | 40 fn from(trap_frame: &TrapFrame) -> Self { in from() 42 r15: trap_frame.r15, in from() 43 r14: trap_frame.r14, in from() 44 r13: trap_frame.r13, in from() 45 r12: trap_frame.r12, in from() 46 rbp: trap_frame.rbp, in from() 47 rbx: trap_frame.rbx, in from() 48 r11: trap_frame.r11, in from() 49 r10: trap_frame.r10, in from() 50 r9: trap_frame.r9, in from() [all …]
|
/DragonOS/kernel/crates/kprobe/src/arch/ |
H A D | mod.rs | 66 pub fn call(&self, trap_frame: &dyn ProbeArgs) { in call() 67 (self.func)(trap_frame); in call() 84 fn call(&self, trap_frame: &dyn ProbeArgs); in call() 144 fn call(&self, trap_frame: &dyn ProbeArgs); in call() 158 pub fn call_pre_handler(&self, trap_frame: &dyn ProbeArgs) { in call_pre_handler() 159 self.pre_handler.call(trap_frame); in call_pre_handler() 162 pub fn call_post_handler(&self, trap_frame: &dyn ProbeArgs) { in call_post_handler() 163 self.post_handler.call(trap_frame); in call_post_handler() 166 pub fn call_fault_handler(&self, trap_frame: &dyn ProbeArgs) { in call_fault_handler() 167 self.fault_handler.call(trap_frame); in call_fault_handler() [all …]
|
/DragonOS/kernel/src/time/ |
H A D | tick_common.rs | 12 pub fn tick_handle_periodic(trap_frame: &TrapFrame) { in tick_handle_periodic() 15 tick_periodic(cpu_id, trap_frame); in tick_handle_periodic() 18 fn tick_periodic(cpu_id: ProcessorId, trap_frame: &TrapFrame) { in tick_periodic() 24 ProcessManager::update_process_times(trap_frame.is_from_user()); in tick_periodic()
|
/DragonOS/kernel/src/init/ |
H A D | initial_kthread.rs | 83 let mut trap_frame = TrapFrame::new(); in switch_to_user() localVariable 91 &mut trap_frame, in switch_to_user() 102 if try_to_run_init_process(path, &mut proc_init_info, &mut trap_frame).is_ok() { in switch_to_user() 115 unsafe { arch_switch_to_user(trap_frame) }; in switch_to_user() 121 trap_frame: &mut TrapFrame, in try_to_run_init_process() 125 if let Err(e) = run_init_process(proc_init_info, trap_frame) { in try_to_run_init_process() 141 trap_frame: &mut TrapFrame, in run_init_process() 151 trap_frame, in run_init_process()
|
/DragonOS/kernel/src/arch/x86_64/interrupt/ |
H A D | handle.rs | 16 unsafe extern "C" fn x86_64_do_irq(trap_frame: &mut TrapFrame, vector: u32) { in x86_64_do_irq() 19 if trap_frame.is_from_user() { in x86_64_do_irq() 31 handler.unwrap().handle(&desc, trap_frame); in x86_64_do_irq()
|
/DragonOS/docs/kernel/trace/ |
H A D | kprobe.md | 38 pub fn call_pre_handler(&self, trap_frame: &dyn ProbeArgs) 39 pub fn call_post_handler(&self, trap_frame: &dyn ProbeArgs) 40 pub fn call_fault_handler(&self, trap_frame: &dyn ProbeArgs) 41 pub fn call_event_callback(&self, trap_frame: &dyn ProbeArgs)
|
/DragonOS/kernel/src/arch/x86_64/ipc/ |
H A D | signal.rs | 503 fn sys_rt_sigreturn(trap_frame: &mut TrapFrame) -> u64 { in sys_rt_sigreturn() 504 let frame = (trap_frame.rsp as usize - size_of::<u64>()) as *mut SigFrame; in sys_rt_sigreturn() 511 return trap_frame.rax; in sys_rt_sigreturn() 516 if !unsafe { &mut (*frame).context }.restore_sigcontext(trap_frame) { in sys_rt_sigreturn() 523 return trap_frame.rax; in sys_rt_sigreturn() 557 trap_frame: &mut TrapFrame, in setup_frame() 621 let frame: *mut SigFrame = get_stack(trap_frame, size_of::<SigFrame>()); in setup_frame() 652 .setup_sigcontext(oldset, trap_frame) in setup_frame() 669 trap_frame.rdi = sig as u64; in setup_frame() 670 trap_frame.rsi = unsafe { &(*frame).info as *const SigInfo as u64 }; in setup_frame() [all …]
|
/DragonOS/kernel/src/driver/clocksource/ |
H A D | timer_riscv.rs | 40 fn handle_irq(trap_frame: &mut TrapFrame) -> Result<(), SystemError> { in handle_irq() 47 tick_handle_periodic(trap_frame); in handle_irq() 134 fn handle(&self, _irq_desc: &Arc<IrqDesc>, trap_frame: &mut TrapFrame) { in handle() 135 RiscVSbiTimer::handle_irq(trap_frame).unwrap(); in handle()
|
/DragonOS/kernel/src/perf/ |
H A D | kprobe.rs | 69 fn call(&self, trap_frame: &dyn ProbeArgs) { in call() 70 let trap_frame = trap_frame.as_any().downcast_ref::<TrapFrame>().unwrap(); in call() localVariable 71 let pt_regs = KProbeContext::from(trap_frame); in call()
|
/DragonOS/kernel/src/driver/irqchip/ |
H A D | riscv_intc.rs | 213 pub fn riscv_intc_irq(trap_frame: &mut TrapFrame) { in riscv_intc_irq() 214 let hwirq = HardwareIrqNumber::new(trap_frame.cause.code() as u32); in riscv_intc_irq() 217 do_plic_irq(trap_frame); in riscv_intc_irq() 222 trap_frame, in riscv_intc_irq()
|
H A D | riscv_sifive_plic.rs | 625 pub(super) fn do_plic_irq(trap_frame: &mut TrapFrame) { in do_plic_irq() 655 if let Err(e) = GenericIrqHandler::handle_domain_irq(domain.clone(), hwirq, trap_frame) { in do_plic_irq()
|
/DragonOS/kernel/src/arch/x86_64/driver/apic/ |
H A D | apic_timer.rs | 70 fn handle(&self, _irq_desc: &Arc<IrqDesc>, trap_frame: &mut TrapFrame) { in handle() 71 LocalApicTimer::handle_irq(trap_frame).ok(); in handle() 279 pub(super) fn handle_irq(trap_frame: &TrapFrame) -> Result<IrqReturn, SystemError> { in handle_irq() 281 tick_handle_periodic(trap_frame); in handle_irq()
|
/DragonOS/kernel/src/arch/x86_64/process/ |
H A D | mod.rs | 509 pub unsafe fn arch_switch_to_user(trap_frame: TrapFrame) -> ! { in arch_switch_to_user() 552 ready_to_switch_to_user(trap_frame, trap_frame_vaddr.data(), new_rip.data()); in arch_switch_to_user() 558 trap_frame: TrapFrame, in ready_to_switch_to_user() 562 *(trapframe_vaddr as *mut TrapFrame) = trap_frame; in ready_to_switch_to_user()
|
/DragonOS/kernel/src/arch/riscv64/process/ |
H A D | mod.rs | 51 pub unsafe fn arch_switch_to_user(trap_frame: TrapFrame) -> ! { in arch_switch_to_user() 73 *(trap_frame_vaddr.data() as *mut TrapFrame) = trap_frame; in arch_switch_to_user() 80 unsafe extern "C" fn ready_to_switch_to_user(trap_frame: usize, new_pc: usize) -> ! { in ready_to_switch_to_user()
|
/DragonOS/kernel/src/exception/ |
H A D | irqdesc.rs | 47 fn handle(&self, irq_desc: &Arc<IrqDesc>, trap_frame: &mut TrapFrame); in handle() 1040 trap_frame: &mut TrapFrame, in handle_domain_irq() 1045 irq_desc.handler().unwrap().handle(&irq_desc, trap_frame); in handle_domain_irq()
|
/DragonOS/kernel/src/ipc/ |
H A D | signal_types.rs | 547 fn sys_rt_sigreturn(trap_frame: &mut TrapFrame) -> u64; in sys_rt_sigreturn()
|