/xen/xen/arch/x86/x86_64/ |
A D | gdbstub.c | 28 GDB_REG64(regs->rax); in gdb_arch_read_reg_array() 29 GDB_REG64(regs->rbx); in gdb_arch_read_reg_array() 30 GDB_REG64(regs->rcx); in gdb_arch_read_reg_array() 37 GDB_REG64(regs->r8); in gdb_arch_read_reg_array() 38 GDB_REG64(regs->r9); in gdb_arch_read_reg_array() 49 GDB_REG32(regs->cs); in gdb_arch_read_reg_array() 50 GDB_REG32(regs->ss); in gdb_arch_read_reg_array() 51 GDB_REG32(regs->ds); in gdb_arch_read_reg_array() 52 GDB_REG32(regs->es); in gdb_arch_read_reg_array() 53 GDB_REG32(regs->fs); in gdb_arch_read_reg_array() [all …]
|
A D | traps.c | 46 regs->ds = read_sreg(ds); in read_registers() 47 regs->es = read_sreg(es); in read_registers() 65 printk("RIP: %04x:[<%016lx>]", regs->cs, regs->rip); in _show_registers() 76 regs->rax, regs->rbx, regs->rcx); in _show_registers() 78 regs->rdx, regs->rsi, regs->rdi); in _show_registers() 80 regs->rbp, regs->rsp, regs->r8); in _show_registers() 82 regs->r9, regs->r10, regs->r11); in _show_registers() 84 regs->r12, regs->r13, regs->r14); in _show_registers() 92 regs->ds, regs->es, regs->fs, in _show_registers() 93 regs->gs, regs->ss, regs->cs); in _show_registers() [all …]
|
/xen/xen/arch/arm/ |
A D | traps.c | 767 regs->r0, regs->r1, regs->r2, regs->r3); in show_registers_32() 769 regs->r4, regs->r5, regs->r6, regs->r7); in show_registers_32() 771 regs->r8, regs->r9, regs->r10, in show_registers_32() 794 regs->r8_fiq, regs->r9_fiq, regs->r10_fiq, regs->r11_fiq, regs->r11_fiq); in show_registers_32() 851 regs->x0, regs->x1, regs->x2); in show_registers_64() 853 regs->x3, regs->x4, regs->x5); in show_registers_64() 855 regs->x6, regs->x7, regs->x8); in show_registers_64() 857 regs->x9, regs->x10, regs->x11); in show_registers_64() 859 regs->x12, regs->x13, regs->x14); in show_registers_64() 861 regs->x15, regs->x16, regs->x17); in show_registers_64() [all …]
|
A D | vsmc.c | 56 set_user_reg(regs, n, r); in fill_uid() 71 set_user_reg(regs, 0, major); in fill_revision() 72 set_user_reg(regs, 1, minor); in fill_revision() 83 set_user_reg(regs, 0, cnt); in fill_function_call_count() 129 set_user_reg(regs, 0, ret); in handle_arch() 186 return do_vpsci_0_1_call(regs, fid); in handle_existing_apis() 194 if ( do_vpsci_0_2_call(regs, fid) ) in handle_sssc() 304 advance_pc(regs, hsr); in do_trap_smc() 322 if ( vsmccc_handle_call(regs) ) in do_trap_smc() 323 advance_pc(regs, hsr); in do_trap_smc() [all …]
|
A D | vcpreg.c | 166 advance_pc(regs, hsr); 191 if ( psr_mode_is_user(regs) ) 263 if ( psr_mode_is_user(regs) ) 328 advance_pc(regs, hsr); 335 advance_pc(regs, hsr); in do_cp15_64() 398 advance_pc(regs, hsr); in do_cp15_64() 408 advance_pc(regs, hsr); in do_cp14_32() 529 advance_pc(regs, hsr); in do_cp14_32() 538 advance_pc(regs, hsr); in do_cp14_64() 576 advance_pc(regs, hsr); in do_cp14_dbg() [all …]
|
A D | vm_event.c | 26 const struct cpu_user_regs *regs = guest_cpu_user_regs(); in vm_event_fill_regs() local 28 req->data.regs.arm.cpsr = regs->cpsr; in vm_event_fill_regs() 29 req->data.regs.arm.pc = regs->pc; in vm_event_fill_regs() 30 req->data.regs.arm.ttbcr = READ_SYSREG(TCR_EL1); in vm_event_fill_regs() 31 req->data.regs.arm.ttbr0 = READ_SYSREG64(TTBR0_EL1); in vm_event_fill_regs() 32 req->data.regs.arm.ttbr1 = READ_SYSREG64(TTBR1_EL1); in vm_event_fill_regs() 37 struct cpu_user_regs *regs = &v->arch.cpu_info->guest_cpu_user_regs; in vm_event_set_registers() local 42 regs->pc = rsp->data.regs.arm.pc; in vm_event_set_registers()
|
A D | vpsci.c | 250 switch ( (uint32_t)get_user_reg(regs, 0) ) in do_vpsci_0_1_call() 254 uint32_t pstate = PSCI_ARG32(regs, 1); in do_vpsci_0_1_call() 262 uint32_t vcpuid = PSCI_ARG32(regs, 1); in do_vpsci_0_1_call() 263 register_t epoint = PSCI_ARG(regs, 2); in do_vpsci_0_1_call() 317 register_t vcpuid = PSCI_ARG(regs, 1); in do_vpsci_0_2_call() 318 register_t epoint = PSCI_ARG(regs, 2); in do_vpsci_0_2_call() 319 register_t cid = PSCI_ARG(regs, 3); in do_vpsci_0_2_call() 329 uint32_t pstate = PSCI_ARG32(regs, 1); in do_vpsci_0_2_call() 331 register_t cid = PSCI_ARG(regs, 3); in do_vpsci_0_2_call() 341 register_t taff = PSCI_ARG(regs, 1); in do_vpsci_0_2_call() [all …]
|
/xen/xen/arch/x86/pv/ |
A D | iret.c | 114 regs->rsp = (u32)regs->rsp; in compat_iret() 117 if ( unlikely(__get_user(regs->eax, (u32 *)regs->rsp)) ) in compat_iret() 124 if ( unlikely(__get_user(regs->eip, (u32 *)regs->rsp + 1)) || in compat_iret() 125 unlikely(__get_user(regs->cs, (u32 *)regs->rsp + 2)) ) in compat_iret() 184 regs->esp = ksp; in compat_iret() 198 regs->cs = ti->cs; in compat_iret() 205 else if ( ring_1(regs) ) in compat_iret() 206 regs->esp += 16; in compat_iret() 208 else if ( __get_user(regs->ss, (u32 *)regs->rsp + 5) || in compat_iret() 209 __get_user(regs->esp, (u32 *)regs->rsp + 4) ) in compat_iret() [all …]
|
A D | emul-inv-op.c | 33 eip = regs->rip; in emulate_forced_invalid_op() 56 !guest_kernel_mode(current, regs) ) in emulate_forced_invalid_op() 58 regs->rip = eip; in emulate_forced_invalid_op() 65 guest_cpuid(current, regs->eax, regs->ecx, &res); in emulate_forced_invalid_op() 67 regs->rax = res.a; in emulate_forced_invalid_op() 68 regs->rbx = res.b; in emulate_forced_invalid_op() 69 regs->rcx = res.c; in emulate_forced_invalid_op() 70 regs->rdx = res.d; in emulate_forced_invalid_op() 72 pv_emul_instruction_done(regs, eip); in emulate_forced_invalid_op() 79 bool pv_emulate_invalid_op(struct cpu_user_regs *regs) in pv_emulate_invalid_op() argument [all …]
|
A D | emul-gate-op.c | 126 sel = ctxt->regs->ss; in read_mem() 170 struct gate_op_ctxt ctxt = { .ctxt.regs = regs, .insn_fetch = true }; in pv_emulate_gate_op() 339 push(regs->ss); in pv_emulate_gate_op() 340 push(regs->rsp); in pv_emulate_gate_op() 378 esp = regs->rsp; in pv_emulate_gate_op() 379 ss = regs->ss; in pv_emulate_gate_op() 398 push(regs->cs); in pv_emulate_gate_op() 401 regs->rsp = esp; in pv_emulate_gate_op() 402 regs->ss = ss; in pv_emulate_gate_op() 405 sel |= (regs->cs & 3); in pv_emulate_gate_op() [all …]
|
A D | hypercall.c | 106 eax = is_pv_32bit_vcpu(curr) ? regs->eax : regs->rax; in pv_hypercall() 113 regs->rax = -ENOSYS; in pv_hypercall() 121 regs->rax = -ENOSYS; in pv_hypercall() 133 unsigned long r8 = regs->r8; in pv_hypercall() 134 unsigned long r9 = regs->r9; in pv_hypercall() 175 unsigned int ebx = regs->ebx; in pv_hypercall() 176 unsigned int ecx = regs->ecx; in pv_hypercall() 177 unsigned int edx = regs->edx; in pv_hypercall() 178 unsigned int esi = regs->esi; in pv_hypercall() 179 unsigned int edi = regs->edi; in pv_hypercall() [all …]
|
/xen/xen/arch/x86/ |
A D | traps.c | 133 #define ESP_BEFORE_EXCEPTION(regs) ((unsigned long *)regs->rsp) argument 203 _p(regs->rip), _p(regs->rip), in show_code() 668 regs->rip, guest_mode(regs) ? NULL : _p(regs->rip)); in nmi_show_execution_state() 810 if ( ptr[0] == regs->rip && ptr[1] == regs->cs ) in extable_shstk_fixup() 840 vec_name(regs->entry_vector), regs->error_code, in extable_fixup() 841 _p(regs->rip), _p(regs->rip), _p(fixup)); in extable_fixup() 1203 _p(regs->rip), _p(regs->rip)); in do_int3() 1574 regs->cs, _p(regs->rip), _p(cr2), regs->error_code); in do_early_page_fault() 1947 regs->cs, _p(regs->rip), _p(regs->rip), in do_debug() 1948 regs->ss, _p(regs->rsp), dr6); in do_debug() [all …]
|
A D | vm_event.c | 209 req->data.regs.x86.rax = regs->rax; in vm_event_fill_regs() 210 req->data.regs.x86.rcx = regs->rcx; in vm_event_fill_regs() 211 req->data.regs.x86.rdx = regs->rdx; in vm_event_fill_regs() 212 req->data.regs.x86.rbx = regs->rbx; in vm_event_fill_regs() 213 req->data.regs.x86.rsp = regs->rsp; in vm_event_fill_regs() 214 req->data.regs.x86.rbp = regs->rbp; in vm_event_fill_regs() 215 req->data.regs.x86.rsi = regs->rsi; in vm_event_fill_regs() 216 req->data.regs.x86.rdi = regs->rdi; in vm_event_fill_regs() 218 req->data.regs.x86.r8 = regs->r8; in vm_event_fill_regs() 219 req->data.regs.x86.r9 = regs->r9; in vm_event_fill_regs() [all …]
|
A D | hypercall.c | 122 regs->rax = op; in hypercall_create_continuation() 131 case 0: regs->rdi = arg; break; in hypercall_create_continuation() 176 regs->rax = res; in arch_hypercall_tasklet_result() 184 struct cpu_user_regs *regs; in hypercall_xlat_continuation() local 231 regs = guest_cpu_user_regs(); in hypercall_xlat_continuation() 238 case 0: reg = ®s->rbx; break; in hypercall_xlat_continuation() 239 case 1: reg = ®s->rcx; break; in hypercall_xlat_continuation() 240 case 2: reg = ®s->rdx; break; in hypercall_xlat_continuation() 241 case 3: reg = ®s->rsi; break; in hypercall_xlat_continuation() 242 case 4: reg = ®s->rdi; break; in hypercall_xlat_continuation() [all …]
|
A D | gdbstub.c | 24 gdb_arch_signal_num(struct cpu_user_regs *regs, unsigned long cookie) in gdb_arch_signal_num() argument 46 gdb_arch_print_state(struct cpu_user_regs *regs) in gdb_arch_print_state() argument 52 gdb_arch_enter(struct cpu_user_regs *regs) in gdb_arch_enter() argument 58 gdb_arch_exit(struct cpu_user_regs *regs) in gdb_arch_exit() argument 64 gdb_arch_resume(struct cpu_user_regs *regs, in gdb_arch_resume() argument 69 regs->rip = addr; in gdb_arch_resume() 71 regs->eflags &= ~X86_EFLAGS_TF; in gdb_arch_resume() 74 regs->eflags |= X86_EFLAGS_RF; in gdb_arch_resume() 78 regs->eflags |= X86_EFLAGS_TF; in gdb_arch_resume()
|
/xen/tools/tests/x86_emulator/ |
A D | test_x86_emulator.c | 51 regs->eax = 2; in blowfish_set_regs() 52 regs->edx = 1; in blowfish_set_regs() 57 return regs->eax == 2 && regs->edx == 1; in blowfish_check_regs() 886 ctxt.regs = ®s; in main() 1766 regs.esi = 0; in main() 2060 regs.ebx != (*res << (regs.edx & 0x1f)) || in main() 2080 regs.ebx != (*res >> (regs.edx & 0x1f)) || in main() 2136 regs.eax != 0xffffffff || regs.ecx || regs.edx != 0xffffffff || in main() 3996 regs.eax = regs.edx = 12; in main() 5023 for ( regs.edx = 0; regs.edx < 4; ++regs.edx ) in main() [all …]
|
/xen/xen/arch/arm/arm32/ |
A D | traps.c | 27 void do_trap_reset(struct cpu_user_regs *regs) in do_trap_reset() argument 29 do_unexpected_trap("Reset", regs); in do_trap_reset() 34 uint32_t pc = regs->pc; in do_trap_undefined_instruction() 42 if ( regs->pc & 0x3 ) in do_trap_undefined_instruction() 49 if ( do_bug_frame(regs, pc) ) in do_trap_undefined_instruction() 52 regs->pc += 4; in do_trap_undefined_instruction() 61 do_unexpected_trap("Hypervisor Call", regs); in do_trap_hypervisor_call() 66 do_unexpected_trap("Prefetch Abort", regs); in do_trap_prefetch_abort() 79 if ( VABORT_GEN_BY_GUEST(regs) ) in do_trap_data_abort() 80 do_trap_guest_serror(regs); in do_trap_data_abort() [all …]
|
/xen/xen/arch/x86/hvm/ |
A D | domain.c | 149 rc = SEG(cs, regs); in arch_set_info_hvm_guest() 150 rc |= SEG(ds, regs); in arch_set_info_hvm_guest() 151 rc |= SEG(ss, regs); in arch_set_info_hvm_guest() 152 rc |= SEG(es, regs); in arch_set_info_hvm_guest() 153 rc |= SEG(tr, regs); in arch_set_info_hvm_guest() 163 if ( regs->eip > limit ) in arch_set_info_hvm_guest() 191 if ( (regs->efer & EFER_LMA) && !(regs->efer & EFER_LME) ) in arch_set_info_hvm_guest() 194 regs->efer); in arch_set_info_hvm_guest() 224 regs->rip); in arch_set_info_hvm_guest() 231 regs->cr0); in arch_set_info_hvm_guest() [all …]
|
A D | hypercall.c | 170 unsigned long eax = regs->eax; in hvm_hypercall() 176 eax = regs->rax; in hvm_hypercall() 182 (mode == 8 ? regs->rdi : regs->ebx) == HVMOP_guest_request_vm_event ) in hvm_hypercall() 188 regs->rax = -EPERM; in hvm_hypercall() 214 regs->rax = -ENOSYS; in hvm_hypercall() 222 regs->rax = -ENOSYS; in hvm_hypercall() 240 unsigned long r8 = regs->r8; in hvm_hypercall() 241 unsigned long r9 = regs->r9; in hvm_hypercall() 280 unsigned int ebx = regs->ebx; in hvm_hypercall() 281 unsigned int ecx = regs->ecx; in hvm_hypercall() [all …]
|
A D | vm_event.c | 37 regs->rax = v->arch.vm_event->gprs.rax; in hvm_vm_event_set_registers() 38 regs->rbx = v->arch.vm_event->gprs.rbx; in hvm_vm_event_set_registers() 39 regs->rcx = v->arch.vm_event->gprs.rcx; in hvm_vm_event_set_registers() 40 regs->rdx = v->arch.vm_event->gprs.rdx; in hvm_vm_event_set_registers() 41 regs->rsp = v->arch.vm_event->gprs.rsp; in hvm_vm_event_set_registers() 42 regs->rbp = v->arch.vm_event->gprs.rbp; in hvm_vm_event_set_registers() 43 regs->rsi = v->arch.vm_event->gprs.rsi; in hvm_vm_event_set_registers() 44 regs->rdi = v->arch.vm_event->gprs.rdi; in hvm_vm_event_set_registers() 46 regs->r8 = v->arch.vm_event->gprs.r8; in hvm_vm_event_set_registers() 47 regs->r9 = v->arch.vm_event->gprs.r9; in hvm_vm_event_set_registers() [all …]
|
/xen/xen/include/asm-arm/ |
A D | traps.h | 39 void advance_pc(struct cpu_user_regs *regs, const union hsr hsr); 60 void do_cp15_32(struct cpu_user_regs *regs, const union hsr hsr); 61 void do_cp15_64(struct cpu_user_regs *regs, const union hsr hsr); 62 void do_cp14_32(struct cpu_user_regs *regs, const union hsr hsr); 63 void do_cp14_64(struct cpu_user_regs *regs, const union hsr hsr); 64 void do_cp14_dbg(struct cpu_user_regs *regs, const union hsr hsr); 65 void do_cp(struct cpu_user_regs *regs, const union hsr hsr); 69 void do_trap_hvc_smccc(struct cpu_user_regs *regs); 71 int do_bug_frame(const struct cpu_user_regs *regs, vaddr_t pc); 82 return ((unsigned long)abort_guest_exit_start == regs->pc) || in VABORT_GEN_BY_GUEST() [all …]
|
A D | vreg.h | 25 r = get_user_reg(regs, cp32.reg); in vreg_emulate_cp32() 27 ret = fn(regs, &r, cp32.read); in vreg_emulate_cp32() 30 set_user_reg(regs, cp32.reg, r); in vreg_emulate_cp32() 55 ret = fn(regs, &x, cp64.read); in vreg_emulate_cp64() 60 set_user_reg(regs, cp64.reg2, x >> 32); in vreg_emulate_cp64() 75 r = get_user_reg(regs, sysreg.reg); in vreg_emulate_sysreg32() 77 ret = fn(regs, &r, sysreg.read); in vreg_emulate_sysreg32() 80 set_user_reg(regs, sysreg.reg, r); in vreg_emulate_sysreg32() 98 x = get_user_reg(regs, sysreg.reg); in vreg_emulate_sysreg64() 100 ret = fn(regs, &x, sysreg.read); in vreg_emulate_sysreg64() [all …]
|
/xen/tools/xentrace/ |
A D | xenctx.c | 374 printf("cs:eip: %04x:%08x", regs->cs, regs->eip); in print_ctx_32() 376 print_flags(regs->eflags); in print_ctx_32() 377 printf("ss:esp: %04x:%08x\n", regs->ss, regs->esp); in print_ctx_32() 403 printf("cs:eip: %04x:%08x", regs->cs, (uint32_t)regs->eip); in print_ctx_32on64() 406 printf("ss:esp: %04x:%08x\n", regs->ss, (uint32_t)regs->esp); in print_ctx_32on64() 561 regs->sp_usr, regs->lr_usr); in print_ctx_32() 563 regs->spsr_svc, regs->sp_svc, regs->lr_svc); in print_ctx_32() 565 regs->spsr_fiq, regs->sp_fiq, regs->lr_fiq); in print_ctx_32() 567 regs->spsr_irq, regs->sp_irq, regs->lr_irq); in print_ctx_32() 569 regs->spsr_abt, regs->sp_abt, regs->lr_abt); in print_ctx_32() [all …]
|
/xen/xen/arch/arm/arm64/ |
A D | vsysreg.c | 72 void do_sysreg(struct cpu_user_regs *regs, 86 if ( psr_mode_is_user(regs) ) 87 return inject_undef_exception(regs, hsr); 89 set_user_reg(regs, regidx, v->arch.actlr); 201 if ( psr_mode_is_user(regs) ) 231 if ( !vtimer_emulate(regs, hsr) ) 232 return inject_undef_exception(regs, hsr); 244 if ( !vgic_emulate(regs, hsr) ) 288 sysreg.reg, regs->pc); 291 inject_undef_exception(regs, hsr); [all …]
|
/xen/xen/arch/arm/platforms/ |
A D | xilinx-zynqmp-eemi.c | 52 bool zynqmp_eemi(struct cpu_user_regs *regs) in zynqmp_eemi() argument 55 uint32_t fid = get_user_reg(regs, 0); in zynqmp_eemi() 56 uint32_t nodeid = get_user_reg(regs, 1); in zynqmp_eemi() 190 arm_smccc_1_1_smc(get_user_reg(regs, 0), in zynqmp_eemi() 191 get_user_reg(regs, 1), in zynqmp_eemi() 192 get_user_reg(regs, 2), in zynqmp_eemi() 200 set_user_reg(regs, 0, res.a0); in zynqmp_eemi() 201 set_user_reg(regs, 1, res.a1); in zynqmp_eemi() 202 set_user_reg(regs, 2, res.a2); in zynqmp_eemi() 203 set_user_reg(regs, 3, res.a3); in zynqmp_eemi() [all …]
|