Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Oct 2010 07:49:06 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r213553 - stable/8/sys/kern
Message-ID:  <201010080749.o987n6iC083243@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Fri Oct  8 07:49:05 2010
New Revision: 213553
URL: http://svn.freebsd.org/changeset/base/213553

Log:
  MFC r212994: kdb_backtrace: use stack_print_ddb instead of stack_print

Modified:
  stable/8/sys/kern/kern_linker.c
  stable/8/sys/kern/subr_kdb.c
  stable/8/sys/kern/subr_stack.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/kern/kern_linker.c
==============================================================================
--- stable/8/sys/kern/kern_linker.c	Fri Oct  8 07:38:44 2010	(r213552)
+++ stable/8/sys/kern/kern_linker.c	Fri Oct  8 07:49:05 2010	(r213553)
@@ -919,7 +919,6 @@ linker_debug_search_symbol_name(caddr_t 
 	return (0);
 }
 
-#ifdef DDB
 /*
  * DDB Helpers.  DDB has to look across multiple files with their own symbol
  * tables and string tables.
@@ -928,12 +927,14 @@ linker_debug_search_symbol_name(caddr_t 
  * DDB to hang because somebody's got the lock held.  We'll take the chance
  * that the files list is inconsistant instead.
  */
+#ifdef DDB
 int
 linker_ddb_lookup(const char *symstr, c_linker_sym_t *sym)
 {
 
 	return (linker_debug_lookup(symstr, sym));
 }
+#endif
 
 int
 linker_ddb_search_symbol(caddr_t value, c_linker_sym_t *sym, long *diffp)
@@ -956,7 +957,6 @@ linker_ddb_search_symbol_name(caddr_t va
 
 	return (linker_debug_search_symbol_name(value, buf, buflen, offset));
 }
-#endif
 
 /*
  * stack(9) helper for non-debugging environemnts.  Unlike DDB helpers, we do

Modified: stable/8/sys/kern/subr_kdb.c
==============================================================================
--- stable/8/sys/kern/subr_kdb.c	Fri Oct  8 07:38:44 2010	(r213552)
+++ stable/8/sys/kern/subr_kdb.c	Fri Oct  8 07:49:05 2010	(r213553)
@@ -308,7 +308,7 @@ kdb_backtrace(void)
 
 		printf("KDB: stack backtrace:\n");
 		stack_save(&st);
-		stack_print(&st);
+		stack_print_ddb(&st);
 	}
 #endif
 }

Modified: stable/8/sys/kern/subr_stack.c
==============================================================================
--- stable/8/sys/kern/subr_stack.c	Fri Oct  8 07:38:44 2010	(r213552)
+++ stable/8/sys/kern/subr_stack.c	Fri Oct  8 07:49:05 2010	(r213553)
@@ -44,9 +44,7 @@ static MALLOC_DEFINE(M_STACK, "stack", "
 
 static int stack_symbol(vm_offset_t pc, char *namebuf, u_int buflen,
 	    long *offset);
-#ifdef DDB
 static int stack_symbol_ddb(vm_offset_t pc, const char **name, long *offset);
-#endif
 
 struct stack *
 stack_create(void)
@@ -125,7 +123,6 @@ stack_print_short(struct stack *st)
 	printf("\n");
 }
 
-#ifdef DDB
 void
 stack_print_ddb(struct stack *st)
 {
@@ -141,6 +138,7 @@ stack_print_ddb(struct stack *st)
 	}
 }
 
+#ifdef DDB
 void
 stack_print_short_ddb(struct stack *st)
 {
@@ -255,7 +253,6 @@ stack_symbol(vm_offset_t pc, char *nameb
 		return (0);
 }
 
-#ifdef DDB
 static int
 stack_symbol_ddb(vm_offset_t pc, const char **name, long *offset)
 {
@@ -275,4 +272,3 @@ stack_symbol_ddb(vm_offset_t pc, const c
 	*name = "??";
 	return (ENOENT);
 }
-#endif



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