Received: from eggs.gnu.org ([208.118.235.92]:43756) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TfpXK-00071R-8l for qemu-devel@nongnu.org; Tue, 04 Dec 2012 05:16:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tfnjf-00031j-ED for qemu-devel@nongnu.org; Tue, 04 Dec 2012 03:20:17 -0500 Received: from [222.73.24.84] (port=12755 helo=song.cn.fujitsu.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tfndp-0001uS-Ly for qemu-devel@nongnu.org; Tue, 04 Dec 2012 03:14:10 -0500 From: liguang Date: Tue, 4 Dec 2012 16:11:34 +0800 Message-Id: <1354608695-3232-2-git-send-email-lig.fnst@cn.fujitsu.com> In-Reply-To: <1354608695-3232-1-git-send-email-lig.fnst@cn.fujitsu.com> References: <1354608695-3232-1-git-send-email-lig.fnst@cn.fujitsu.com> Subject: [Qemu-devel] [PATCH 2/3] target-i386:make hw_breakpoint_enabled return bool type List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: afaerber@suse.de, ehabkost@redhat.com, imammedo@redhat.com, blauwirbel@gmail.com, jan.kiszka@siemens.com, qemu-devel@nongnu.org Cc: liguang Signed-off-by: liguang --- target-i386/cpu.h | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/target-i386/cpu.h b/target-i386/cpu.h index 9abec3e..8ca25c8 100644 --- a/target-i386/cpu.h +++ b/target-i386/cpu.h @@ -996,9 +996,9 @@ int cpu_x86_handle_mmu_fault(CPUX86State *env, target_ulong addr, #define cpu_handle_mmu_fault cpu_x86_handle_mmu_fault void cpu_x86_set_a20(CPUX86State *env, int a20_state); -static inline int hw_breakpoint_enabled(unsigned long dr7, int index) +static inline bool hw_breakpoint_enabled(unsigned long dr7, int index) { - return (dr7 >> (index * 2)) & 3; + return !!((dr7 >> (index * 2)) & 3); } static inline int hw_breakpoint_type(unsigned long dr7, int index) -- 1.7.2.5