From 4b34e3ad83588602834c05c0d59a0d2973e9f48c Mon Sep 17 00:00:00 2001 From: liguang Date: Tue, 28 May 2013 16:20:59 +0800 Subject: target-i386/helper: remove EAX macro MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: liguang Reviewed-by: Andreas Färber Reviewed-by: Richard Henderson Signed-off-by: Blue Swirl --- target-i386/misc_helper.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'target-i386/misc_helper.c') diff --git a/target-i386/misc_helper.c b/target-i386/misc_helper.c index ec834fc67e..a6a787fbc9 100644 --- a/target-i386/misc_helper.c +++ b/target-i386/misc_helper.c @@ -122,8 +122,8 @@ void helper_cpuid(CPUX86State *env) cpu_svm_check_intercept_param(env, SVM_EXIT_CPUID, 0); - cpu_x86_cpuid(env, (uint32_t)EAX, (uint32_t)ECX, &eax, &ebx, &ecx, &edx); - EAX = eax; + cpu_x86_cpuid(env, (uint32_t)env->regs[R_EAX], (uint32_t)ECX, &eax, &ebx, &ecx, &edx); + env->regs[R_EAX] = eax; EBX = ebx; ECX = ecx; EDX = edx; @@ -234,7 +234,7 @@ void helper_rdtsc(CPUX86State *env) cpu_svm_check_intercept_param(env, SVM_EXIT_RDTSC, 0); val = cpu_get_tsc(env) + env->tsc_offset; - EAX = (uint32_t)(val); + env->regs[R_EAX] = (uint32_t)(val); EDX = (uint32_t)(val >> 32); } @@ -271,7 +271,7 @@ void helper_wrmsr(CPUX86State *env) cpu_svm_check_intercept_param(env, SVM_EXIT_MSR, 1); - val = ((uint32_t)EAX) | ((uint64_t)((uint32_t)EDX) << 32); + val = ((uint32_t)env->regs[R_EAX]) | ((uint64_t)((uint32_t)EDX) << 32); switch ((uint32_t)ECX) { case MSR_IA32_SYSENTER_CS: @@ -548,7 +548,7 @@ void helper_rdmsr(CPUX86State *env) val = 0; break; } - EAX = (uint32_t)(val); + env->regs[R_EAX] = (uint32_t)(val); EDX = (uint32_t)(val >> 32); } #endif -- cgit v1.2.1