[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] x86/hypercall: switch away from temporary 32-bit register names
commit ca8cdc176a3f1785f907ed7fcf410412036f77a4 Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Wed Mar 8 15:15:19 2017 +0100 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Wed Mar 8 15:15:19 2017 +0100 x86/hypercall: switch away from temporary 32-bit register names Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> --- xen/arch/x86/hvm/hypercall.c | 14 +++++++------- xen/arch/x86/pv/hypercall.c | 28 ++++++++++++++-------------- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/xen/arch/x86/hvm/hypercall.c b/xen/arch/x86/hvm/hypercall.c index 6499caa..9d6eca5 100644 --- a/xen/arch/x86/hvm/hypercall.c +++ b/xen/arch/x86/hvm/hypercall.c @@ -146,7 +146,7 @@ int hvm_hypercall(struct cpu_user_regs *regs) struct vcpu *curr = current; struct domain *currd = curr->domain; int mode = hvm_guest_x86_mode(curr); - unsigned long eax = regs->_eax; + unsigned long eax = regs->eax; switch ( mode ) { @@ -226,12 +226,12 @@ int hvm_hypercall(struct cpu_user_regs *regs) } else { - unsigned int ebx = regs->_ebx; - unsigned int ecx = regs->_ecx; - unsigned int edx = regs->_edx; - unsigned int esi = regs->_esi; - unsigned int edi = regs->_edi; - unsigned int ebp = regs->_ebp; + unsigned int ebx = regs->ebx; + unsigned int ecx = regs->ecx; + unsigned int edx = regs->edx; + unsigned int esi = regs->esi; + unsigned int edi = regs->edi; + unsigned int ebp = regs->ebp; HVM_DBG_LOG(DBG_LEVEL_HCALL, "hcall%lu(%x, %x, %x, %x, %x, %x)", eax, ebx, ecx, edx, esi, edi, ebp); diff --git a/xen/arch/x86/pv/hypercall.c b/xen/arch/x86/pv/hypercall.c index 9144f2e..9d29d2f 100644 --- a/xen/arch/x86/pv/hypercall.c +++ b/xen/arch/x86/pv/hypercall.c @@ -94,7 +94,7 @@ void pv_hypercall(struct cpu_user_regs *regs) ASSERT(guest_kernel_mode(curr, regs)); - eax = is_pv_32bit_vcpu(curr) ? regs->_eax : regs->rax; + eax = is_pv_32bit_vcpu(curr) ? regs->eax : regs->rax; BUILD_BUG_ON(ARRAY_SIZE(pv_hypercall_table) > ARRAY_SIZE(hypercall_args_table)); @@ -156,12 +156,12 @@ void pv_hypercall(struct cpu_user_regs *regs) } else { - unsigned int ebx = regs->_ebx; - unsigned int ecx = regs->_ecx; - unsigned int edx = regs->_edx; - unsigned int esi = regs->_esi; - unsigned int edi = regs->_edi; - unsigned int ebp = regs->_ebp; + unsigned int ebx = regs->ebx; + unsigned int ecx = regs->ecx; + unsigned int edx = regs->edx; + unsigned int esi = regs->esi; + unsigned int edi = regs->edi; + unsigned int ebp = regs->ebp; #ifndef NDEBUG /* Deliberately corrupt parameter regs not used by this hypercall. */ @@ -184,7 +184,7 @@ void pv_hypercall(struct cpu_user_regs *regs) } curr->hcall_compat = true; - regs->_eax = pv_hypercall_table[eax].compat(ebx, ecx, edx, esi, edi, ebp); + regs->eax = pv_hypercall_table[eax].compat(ebx, ecx, edx, esi, edi, ebp); curr->hcall_compat = false; #ifndef NDEBUG @@ -193,12 +193,12 @@ void pv_hypercall(struct cpu_user_regs *regs) /* Deliberately corrupt parameter regs used by this hypercall. */ switch ( hypercall_args_table[eax].compat ) { - case 6: regs->_ebp = 0xdeadf00d; - case 5: regs->_edi = 0xdeadf00d; - case 4: regs->_esi = 0xdeadf00d; - case 3: regs->_edx = 0xdeadf00d; - case 2: regs->_ecx = 0xdeadf00d; - case 1: regs->_ebx = 0xdeadf00d; + case 6: regs->ebp = 0xdeadf00d; + case 5: regs->edi = 0xdeadf00d; + case 4: regs->esi = 0xdeadf00d; + case 3: regs->edx = 0xdeadf00d; + case 2: regs->ecx = 0xdeadf00d; + case 1: regs->ebx = 0xdeadf00d; } } #endif -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |