Re: [Qemu-devel] [PATCH qom-next 02/12] target-xtensa: use global prev_debug_excp_handler instead of local one

2012-05-30 Thread Andreas Färber
Am 30.05.2012 00:10, schrieb Igor Mammedov:
 Signed-off-by: Igor Mammedov imamm...@redhat.com
 ---
  target-xtensa/helper.c |5 +
  1 files changed, 1 insertions(+), 4 deletions(-)
 
 diff --git a/target-xtensa/helper.c b/target-xtensa/helper.c
 index 5e7e72e..e2ab83c 100644
 --- a/target-xtensa/helper.c
 +++ b/target-xtensa/helper.c
 @@ -54,8 +54,6 @@ static uint32_t check_hw_breakpoints(CPUXtensaState *env)
  return 0;
  }
  
 -static CPUDebugExcpHandler *prev_debug_excp_handler;
 -
  static void breakpoint_handler(CPUXtensaState *env)
  {
  if (env-watchpoint_hit) {
 @@ -105,8 +103,7 @@ XtensaCPU *cpu_xtensa_init(const char *cpu_model)
  
  if (!debug_handler_inited  tcg_enabled()) {
  debug_handler_inited = 1;
 -prev_debug_excp_handler =
 -cpu_set_debug_excp_handler(breakpoint_handler);

This would've been broken by patch 01/12.

Andreas

 +cpu_set_debug_excp_handler(breakpoint_handler);
  }
  
  xtensa_irq_init(env);

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg



[Qemu-devel] [PATCH qom-next 02/12] target-xtensa: use global prev_debug_excp_handler instead of local one

2012-05-29 Thread Igor Mammedov
Signed-off-by: Igor Mammedov imamm...@redhat.com
---
 target-xtensa/helper.c |5 +
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/target-xtensa/helper.c b/target-xtensa/helper.c
index 5e7e72e..e2ab83c 100644
--- a/target-xtensa/helper.c
+++ b/target-xtensa/helper.c
@@ -54,8 +54,6 @@ static uint32_t check_hw_breakpoints(CPUXtensaState *env)
 return 0;
 }
 
-static CPUDebugExcpHandler *prev_debug_excp_handler;
-
 static void breakpoint_handler(CPUXtensaState *env)
 {
 if (env-watchpoint_hit) {
@@ -105,8 +103,7 @@ XtensaCPU *cpu_xtensa_init(const char *cpu_model)
 
 if (!debug_handler_inited  tcg_enabled()) {
 debug_handler_inited = 1;
-prev_debug_excp_handler =
-cpu_set_debug_excp_handler(breakpoint_handler);
+cpu_set_debug_excp_handler(breakpoint_handler);
 }
 
 xtensa_irq_init(env);
-- 
1.7.7.6