Remove lock/simplelock cruft.

This commit is contained in:
ad 2008-01-30 14:11:33 +00:00
parent 664eeccc0e
commit 90e58d8323
2 changed files with 4 additions and 70 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: db_interface.c,v 1.77 2008/01/05 22:45:22 martin Exp $ */
/* $NetBSD: db_interface.c,v 1.78 2008/01/30 14:11:33 ad Exp $ */
/*
* Mach Operating System
@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.77 2008/01/05 22:45:22 martin Exp $");
__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.78 2008/01/30 14:11:33 ad Exp $");
#include "opt_ddb.h"
#include "opt_kgdb.h"
@ -199,8 +199,6 @@ void kdb_kbd_trap(struct trapframe *);
void db_prom_cmd(db_expr_t, bool, db_expr_t, const char *);
void db_proc_cmd(db_expr_t, bool, db_expr_t, const char *);
void db_dump_pcb(db_expr_t, bool, db_expr_t, const char *);
void db_lock_cmd(db_expr_t, bool, db_expr_t, const char *);
void db_simple_lock_cmd(db_expr_t, bool, db_expr_t, const char *);
void db_uvmhistdump(db_expr_t, bool, db_expr_t, const char *);
#ifdef MULTIPROCESSOR
void db_cpu_cmd(db_expr_t, bool, db_expr_t, const char *);
@ -449,39 +447,6 @@ db_page_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
PHYS_TO_VM_PAGE(addr));
}
void
db_lock_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
{
struct lock *l;
if (!have_addr) {
db_printf("What lock address?\n");
return;
}
l = (struct lock *)addr;
db_printf("flags=%x\n waitcount=%x sharecount=%x "
"exclusivecount=%x\n wmesg=%s recurselevel=%x\n",
l->lk_flags, l->lk_waitcount,
l->lk_sharecount, l->lk_exclusivecount, l->lk_wmesg,
l->lk_recurselevel);
}
void
db_simple_lock_cmd(db_expr_t addr, bool have_addr, db_expr_t count,
const char *modif)
{
struct simplelock *l;
if (!have_addr) {
db_printf("What lock address?\n");
return;
}
l = (struct simplelock *)addr;
db_printf("lock_data=%d\n", l->lock_data);
}
#if defined(MULTIPROCESSOR)
extern void cpu_debug_dump(void); /* XXX */
@ -539,8 +504,6 @@ const struct db_command db_machine_command_table[] = {
{ DDB_ADD_CMD("prom", db_prom_cmd, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("proc", db_proc_cmd, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("pcb", db_dump_pcb, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("lock", db_lock_cmd, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("slock", db_simple_lock_cmd, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("page", db_page_cmd, 0, NULL,NULL,NULL) },
{ DDB_ADD_CMD("uvmdump", db_uvmhistdump, 0, NULL,NULL,NULL) },
#ifdef MULTIPROCESSOR

View File

@ -1,4 +1,4 @@
/* $NetBSD: db_interface.c,v 1.105 2007/11/05 20:43:05 ad Exp $ */
/* $NetBSD: db_interface.c,v 1.106 2008/01/30 14:11:33 ad Exp $ */
/*
* Copyright (c) 1996-2002 Eduardo Horvath. All rights reserved.
@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.105 2007/11/05 20:43:05 ad Exp $");
__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.106 2008/01/30 14:11:33 ad Exp $");
#include "opt_ddb.h"
@ -285,7 +285,6 @@ void db_dump_itsb(db_expr_t, bool, db_expr_t, const char *);
void db_pmap_kernel(db_expr_t, bool, db_expr_t, const char *);
void db_pload_cmd(db_expr_t, bool, db_expr_t, const char *);
void db_pmap_cmd(db_expr_t, bool, db_expr_t, const char *);
/* void db_lock_cmd(db_expr_t, bool, db_expr_t, const char *); */
void db_traptrace(db_expr_t, bool, db_expr_t, const char *);
void db_watch(db_expr_t, bool, db_expr_t, const char *);
void db_pm_extract(db_expr_t, bool, db_expr_t, const char *);
@ -736,31 +735,6 @@ db_pmap_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
}
}
#if 0
void
db_lock_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
{
#if 0
struct lock *l;
if (!have_addr) {
db_printf("What lock address?\n");
return;
}
l = (struct lock *)addr;
db_printf("interlock=%x flags=%x\n waitcount=%x sharecount=%x "
"exclusivecount=%x\n wmesg=%s recurselevel=%x\n",
l->lk_interlock.lock_data, l->lk_flags, l->lk_waitcount,
l->lk_sharecount, l->lk_exclusivecount, l->lk_wmesg,
l->lk_recurselevel);
#else
db_printf("locks unsupported\n");
#endif
}
#endif
#define TSBENTS (512 << tsbsize)
extern pte_t *tsb_dmmu, *tsb_immu;
extern int tsbsize;
@ -1231,9 +1205,6 @@ const struct db_command db_machine_command_table[] = {
"[/f] [address]",
" address:\tdisplay the mapping for this virtual address\n"
" /f:\tif no address is given, display a full dump of the pmap") },
#if 0
{ DDB_ADD_CMD("lock", db_lock_cmd, 0, NULL,NULL,NULL) },
#endif
{ DDB_ADD_CMD("lwp", db_lwp_cmd, 0,
"Display a struct lwp",
"[address]",