Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 23 Aug 2004 21:44:37 +0100
From:      Peter Edwards <peadar@freebsd.org>
To:        Marco Molteni <molter@tin.it>
Cc:        freebsd-current@freebsd.org
Subject:   Re: ddb problems
Message-ID:  <412A5735.8070607@freebsd.org>
In-Reply-To: <20040823200547.1b51bbce.molter@tin.it>
References:  <Pine.GSO.4.61.0408230854440.964@brakkenstein.nijmegen.internl.net> <20040823155141.GD77326@green.homeunix.org> <20040823200547.1b51bbce.molter@tin.it>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------010805060609030306080003
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

Marco Molteni wrote:

>On Mon, 23 Aug 2004 11:51:41 -0400
>Brian Fundakowski Feldman <green@freebsd.org> wrote:
>
>  
>
>>On Mon, Aug 23, 2004 at 08:57:43AM +0200, Michiel Boland wrote:
>>    
>>
>>>Hi. I can't seem to get anything useful out of ddb with recent
>>>-CURRENTs. I get things like double faults, page faults, or endless
>>>streams of console messages. Is anyone else seeing this?
>>>      
>>>
>>Yes, I'm seeing exactly that behavior, unfortunately.
>>    
>>
>
>me too, on
>ddb
>gdb in the base system
>gdb53 in the ports
>
>marco
>  
>

DDB hasn't being adjusting the trap frame to skip over breakpoints 
properly since the KDB work. Marcel knows about the issue: in the 
meantime, the attached patch gives me a workable breakpoints for DDB at 
the expense of some incorrect informational messages switching away from 
the active thread (this is Marcel's variant of my inferior band-aid :-))

--------------010805060609030306080003
Content-Type: text/plain;
 name="kdb.txt"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="kdb.txt"

Index: i386/include/db_machdep.h
===================================================================
RCS file: /usr/cvs/FreeBSD-CVS/src/sys/i386/include/db_machdep.h,v
retrieving revision 1.18
diff -u -r1.18 db_machdep.h
--- i386/include/db_machdep.h	10 Jul 2004 23:47:19 -0000	1.18
+++ i386/include/db_machdep.h	23 Jul 2004 00:51:06 -0000
@@ -35,7 +35,7 @@
 typedef	vm_offset_t	db_addr_t;	/* address - unsigned */
 typedef	int		db_expr_t;	/* expression - signed */
 
-#define	PC_REGS()	((db_addr_t)kdb_thrctx->pcb_eip)
+#define	PC_REGS()	((db_addr_t)kdb_frame->tf_eip)
 
 #define	BKPT_INST	0xcc		/* breakpoint instruction */
 #define	BKPT_SIZE	(1)		/* size of breakpoint inst */

--------------010805060609030306080003--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?412A5735.8070607>