From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53683) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBm8Z-00047p-BS for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:15:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YBm8X-0003ft-1B for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:15:07 -0500 Received: from mnementh.archaic.org.uk ([2001:8b0:1d0::1]:54864) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBm8W-0003XX-RN for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:15:04 -0500 From: Peter Maydell Date: Thu, 15 Jan 2015 15:01:50 +0000 Message-Id: <1421334118-3287-8-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1421334118-3287-1-git-send-email-peter.maydell@linaro.org> References: <1421334118-3287-1-git-send-email-peter.maydell@linaro.org> Subject: [Qemu-devel] [PATCH 07/15] linux-user/main.c (m68k): Use get_user_u16 rather than lduw in cpu_loop List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Riku Voipio , Richard Henderson , patches@linaro.org In the m68k cpu_loop() use get_user_u16 to read the immediate for the simcall rahter than lduw, to bring it into line with how other archs do it and to remove another user of the ldl family of functions. Signed-off-by: Peter Maydell --- linux-user/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/main.c b/linux-user/main.c index 67b0231..65b5a36 100644 --- a/linux-user/main.c +++ b/linux-user/main.c @@ -2972,7 +2972,7 @@ void cpu_loop(CPUM68KState *env) { if (ts->sim_syscalls) { uint16_t nr; - nr = lduw(env->pc + 2); + get_user_u16(nr, env->pc + 2); env->pc += 4; do_m68k_simcall(env, nr); } else { -- 1.9.1