commit bd86cff51a2f221b6cb10649212e5392aea7bcb7
Author: Srikar Dronamraju <sri...@linux.vnet.ibm.com>
Date:   Wed Aug 19 11:43:53 2009 +0530

We only need to intimate gdb once if we get multiple requests for look

There can be multiple stop requests before gdb gets control. However continue
from gdb can resulting in the process again being stopped because we are just
decrementing the count and not clearing it.

I dont see a reason why gdb should return control after asked to continue unless
there is a new request for stop.

The other way to do this could be to make stop_signals a bool instead of
integer.

    
Signed-off-by: Srikar Dronamraju <sri...@linux.vnet.ibm.com>

diff --git a/kernel/utrace-gdb.c b/kernel/utrace-gdb.c
index 7d32264..5d18759 100644
--- a/kernel/utrace-gdb.c
+++ b/kernel/utrace-gdb.c
@@ -388,7 +388,7 @@ u32 gdb_utrace_report_signal(u32 action,
 
         case UTRACE_SIGNAL_REPORT: /* case 3 */
                if (p->stop_signals > 0) {
-                        p->stop_signals --;
+                       p->stop_signals = 0;
                         snprintf (p->stopcode, GDB_BUFMAX, "S%02x", 2); /* 
SIGINT */
                         push_output_packet (p, p->stopcode);
                         p->at_quiesce_do = UTRACE_STOP;

Reply via email to