Module Name:    src
Committed By:   christos
Date:           Sat Oct 19 15:20:52 UTC 2013

Modified Files:
        src/sys/ddb: db_command.c

Log Message:
fix userland build, by moving all the unused stuff inside ifdef _KERNEL


To generate a diff of this commit:
cvs rdiff -u -r1.142 -r1.143 src/sys/ddb/db_command.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/ddb/db_command.c
diff -u src/sys/ddb/db_command.c:1.142 src/sys/ddb/db_command.c:1.143
--- src/sys/ddb/db_command.c:1.142	Sat Jan  5 23:17:27 2013
+++ src/sys/ddb/db_command.c	Sat Oct 19 11:20:52 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: db_command.c,v 1.142 2013/01/06 04:17:27 christos Exp $	*/
+/*	$NetBSD: db_command.c,v 1.143 2013/10/19 15:20:52 christos Exp $	*/
 
 /*
  * Copyright (c) 1996, 1997, 1998, 1999, 2002, 2009 The NetBSD Foundation, Inc.
@@ -60,7 +60,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_command.c,v 1.142 2013/01/06 04:17:27 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_command.c,v 1.143 2013/10/19 15:20:52 christos Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_aio.h"
@@ -969,6 +969,7 @@ static void
 db_map_print_cmd(db_expr_t addr, bool have_addr, db_expr_t count,
     const char *modif)
 {
+#ifdef _KERNEL
 	bool full = false;
 
 	if (modif[0] == 'f')
@@ -977,7 +978,6 @@ db_map_print_cmd(db_expr_t addr, bool ha
 	if (have_addr == false)
 		addr = (db_expr_t)(uintptr_t)db_read_ptr("kernel_map");
 
-#ifdef _KERNEL
 	uvm_map_printit((struct vm_map *)(uintptr_t) addr, full, db_printf);
 #endif	/* XXX CRASH(8) */
 }
@@ -987,12 +987,12 @@ static void
 db_object_print_cmd(db_expr_t addr, bool have_addr,
     db_expr_t count, const char *modif)
 {
+#ifdef _KERNEL /* XXX CRASH(8) */
 	bool full = false;
 
 	if (modif[0] == 'f')
 		full = true;
 
-#ifdef _KERNEL /* XXX CRASH(8) */
 	uvm_object_printit((struct uvm_object *)(uintptr_t) addr, full,
 	    db_printf);
 #endif
@@ -1003,12 +1003,12 @@ static void
 db_page_print_cmd(db_expr_t addr, bool have_addr,
     db_expr_t count, const char *modif)
 {
+#ifdef _KERNEL /* XXX CRASH(8) */
 	bool full = false;
 
 	if (modif[0] == 'f')
 		full = true;
 
-#ifdef _KERNEL /* XXX CRASH(8) */
 	uvm_page_printit((struct vm_page *)(uintptr_t) addr, full, db_printf);
 #endif
 }
@@ -1029,12 +1029,12 @@ static void
 db_buf_print_cmd(db_expr_t addr, bool have_addr,
     db_expr_t count, const char *modif)
 {
+#ifdef _KERNEL /* XXX CRASH(8) */
 	bool full = false;
 
 	if (modif[0] == 'f')
 		full = true;
 
-#ifdef _KERNEL /* XXX CRASH(8) */
 	vfs_buf_print((struct buf *)(uintptr_t) addr, full, db_printf);
 #endif
 }
@@ -1102,12 +1102,12 @@ static void
 db_vnode_print_cmd(db_expr_t addr, bool have_addr,
     db_expr_t count, const char *modif)
 {
+#ifdef _KERNEL /* XXX CRASH(8) */
 	bool full = false;
 
 	if (modif[0] == 'f')
 		full = true;
 
-#ifdef _KERNEL /* XXX CRASH(8) */
 	vfs_vnode_print((struct vnode *)(uintptr_t) addr, full, db_printf);
 #endif
 }
@@ -1127,12 +1127,12 @@ static void
 db_mount_print_cmd(db_expr_t addr, bool have_addr,
     db_expr_t count, const char *modif)
 {
+#ifdef _KERNEL	/* XXX CRASH(8) */
 	bool full = false;
 
 	if (modif[0] == 'f')
 		full = true;
 
-#ifdef _KERNEL	/* XXX CRASH(8) */
 	vfs_mount_print((struct mount *)(uintptr_t) addr, full, db_printf);
 #endif
 }

Reply via email to