From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43379) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WkGPI-0001XL-CH for qemu-devel@nongnu.org; Tue, 13 May 2014 13:22:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WkGPC-00026X-DL for qemu-devel@nongnu.org; Tue, 13 May 2014 13:22:24 -0400 Received: from mail-qg0-x231.google.com ([2607:f8b0:400d:c04::231]:57547) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WkGPC-00025l-9t for qemu-devel@nongnu.org; Tue, 13 May 2014 13:22:18 -0400 Received: by mail-qg0-f49.google.com with SMTP id a108so805951qge.22 for ; Tue, 13 May 2014 10:22:18 -0700 (PDT) Sender: Richard Henderson From: Richard Henderson Date: Tue, 13 May 2014 10:21:41 -0700 Message-Id: <1400001701-23211-2-git-send-email-rth@twiddle.net> In-Reply-To: <1400001701-23211-1-git-send-email-rth@twiddle.net> References: <1400001701-23211-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PULL] exec-all.h: Use stl_le_p instead of stl_p patching x86 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org We got the wrong version of stl_p, the one that bswaps as appropriate for the target. Since x86 is always little-endian, the "_le_" routine will resolve to what we want. Signed-off-by: Richard Henderson --- include/exec/exec-all.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h index 0766e24..444b4d9 100644 --- a/include/exec/exec-all.h +++ b/include/exec/exec-all.h @@ -229,7 +229,7 @@ void ppc_tb_set_jmp_target(unsigned long jmp_addr, unsigned long addr); static inline void tb_set_jmp_target1(uintptr_t jmp_addr, uintptr_t addr) { /* patch the branch destination */ - stl_p((void*)jmp_addr, addr - (jmp_addr + 4)); + stl_le_p((void*)jmp_addr, addr - (jmp_addr + 4)); /* no need to flush icache explicitly */ } #elif defined(__aarch64__) -- 1.9.0