Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/ddb more constification fallout
details: https://anonhg.NetBSD.org/src/rev/48fef698b1dc
branches: trunk
changeset: 581399:48fef698b1dc
user: drochner <drochner%NetBSD.org@localhost>
date: Wed Jun 01 12:25:27 2005 +0000
description:
more constification fallout
diffstat:
sys/ddb/db_break.c | 10 +++---
sys/ddb/db_break.h | 8 ++--
sys/ddb/db_command.c | 70 +++++++++++++++++++++++++-------------------------
sys/ddb/db_command.h | 4 +-
sys/ddb/db_examine.c | 10 +++---
sys/ddb/db_extern.h | 12 ++++----
sys/ddb/db_interface.h | 16 +++++-----
sys/ddb/db_print.c | 6 ++--
sys/ddb/db_run.c | 12 ++++----
sys/ddb/db_run.h | 10 +++---
sys/ddb/db_variables.c | 6 ++--
sys/ddb/db_variables.h | 6 ++--
sys/ddb/db_watch.c | 10 +++---
sys/ddb/db_watch.h | 8 ++--
sys/ddb/db_write_cmd.c | 6 ++--
sys/ddb/db_xxx.c | 21 +++++++-------
16 files changed, 108 insertions(+), 107 deletions(-)
diffs (truncated from 748 to 300 lines):
diff -r 9ba0ffc0f7e0 -r 48fef698b1dc sys/ddb/db_break.c
--- a/sys/ddb/db_break.c Wed Jun 01 12:14:53 2005 +0000
+++ b/sys/ddb/db_break.c Wed Jun 01 12:25:27 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_break.c,v 1.18 2003/04/29 17:06:03 scw Exp $ */
+/* $NetBSD: db_break.c,v 1.19 2005/06/01 12:25:27 drochner Exp $ */
/*
* Mach Operating System
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_break.c,v 1.18 2003/04/29 17:06:03 scw Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_break.c,v 1.19 2005/06/01 12:25:27 drochner Exp $");
#include <sys/param.h>
#include <sys/proc.h>
@@ -223,7 +223,7 @@
/* Delete breakpoint */
/*ARGSUSED*/
void
-db_delete_cmd(db_expr_t addr, int have_addr, db_expr_t count, char * modif)
+db_delete_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
db_delete_breakpoint(db_map_addr(addr), (db_addr_t)addr);
@@ -232,7 +232,7 @@
/* Set breakpoint with skip count */
/*ARGSUSED*/
void
-db_breakpoint_cmd(db_expr_t addr, int have_addr, db_expr_t count, char * modif)
+db_breakpoint_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
if (count == -1)
@@ -244,7 +244,7 @@
/* list breakpoints */
/*ARGSUSED*/
void
-db_listbreak_cmd(db_expr_t addr, int have_addr, db_expr_t count, char * modif)
+db_listbreak_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
db_list_breakpoints();
diff -r 9ba0ffc0f7e0 -r 48fef698b1dc sys/ddb/db_break.h
--- a/sys/ddb/db_break.h Wed Jun 01 12:14:53 2005 +0000
+++ b/sys/ddb/db_break.h Wed Jun 01 12:25:27 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_break.h,v 1.16 2002/02/15 07:33:49 simonb Exp $ */
+/* $NetBSD: db_break.h,v 1.17 2005/06/01 12:25:27 drochner Exp $ */
/*
* Mach Operating System
@@ -52,9 +52,9 @@
db_breakpoint_t db_find_breakpoint_here(db_addr_t);
void db_set_breakpoints(void);
void db_clear_breakpoints(void);
-void db_delete_cmd(db_expr_t, int, db_expr_t, char *);
-void db_breakpoint_cmd(db_expr_t, int, db_expr_t, char *);
-void db_listbreak_cmd(db_expr_t, int, db_expr_t, char *);
+void db_delete_cmd(db_expr_t, int, db_expr_t, const char *);
+void db_breakpoint_cmd(db_expr_t, int, db_expr_t, const char *);
+void db_listbreak_cmd(db_expr_t, int, db_expr_t, const char *);
boolean_t db_map_equal(struct vm_map *, struct vm_map *);
boolean_t db_map_current(struct vm_map *);
struct vm_map *db_map_addr(vaddr_t);
diff -r 9ba0ffc0f7e0 -r 48fef698b1dc sys/ddb/db_command.c
--- a/sys/ddb/db_command.c Wed Jun 01 12:14:53 2005 +0000
+++ b/sys/ddb/db_command.c Wed Jun 01 12:25:27 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_command.c,v 1.78 2005/05/29 21:31:05 christos Exp $ */
+/* $NetBSD: db_command.c,v 1.79 2005/06/01 12:25:27 drochner Exp $ */
/*
* Mach Operating System
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_command.c,v 1.78 2005/05/29 21:31:05 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_command.c,v 1.79 2005/06/01 12:25:27 drochner Exp $");
#include "opt_ddb.h"
#include "opt_kgdb.h"
@@ -98,27 +98,27 @@
*/
static boolean_t db_ed_style = TRUE;
-static void db_buf_print_cmd(db_expr_t, int, db_expr_t, char *);
+static void db_buf_print_cmd(db_expr_t, int, db_expr_t, const char *);
static void db_cmd_list(const struct db_command *);
static int db_cmd_search(const char *, const struct db_command *,
const struct db_command **);
static void db_command(const struct db_command **,
const struct db_command *);
-static void db_event_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_fncall(db_expr_t, int, db_expr_t, char *);
-static void db_malloc_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_map_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_namecache_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_object_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_page_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_pool_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_reboot_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_sifting_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_stack_trace_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_sync_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_uvmexp_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_vnode_print_cmd(db_expr_t, int, db_expr_t, char *);
-static void db_mount_print_cmd(db_expr_t, int, db_expr_t, char *);
+static void db_event_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_fncall(db_expr_t, int, db_expr_t, const char *);
+static void db_malloc_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_map_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_namecache_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_object_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_page_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_pool_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_reboot_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_sifting_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_stack_trace_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_sync_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_uvmexp_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_vnode_print_cmd(db_expr_t, int, db_expr_t, const char *);
+static void db_mount_print_cmd(db_expr_t, int, db_expr_t, const char *);
/*
* 'show' commands
@@ -489,7 +489,7 @@
/*ARGSUSED*/
static void
-db_map_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_map_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -504,7 +504,7 @@
/*ARGSUSED*/
static void
-db_malloc_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_malloc_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
#ifdef MALLOC_DEBUG
@@ -519,7 +519,7 @@
/*ARGSUSED*/
static void
-db_object_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_object_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -532,7 +532,7 @@
/*ARGSUSED*/
static void
-db_page_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_page_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -544,7 +544,7 @@
/*ARGSUSED*/
static void
-db_buf_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_buf_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -556,7 +556,7 @@
/*ARGSUSED*/
static void
-db_event_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_event_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -568,7 +568,7 @@
/*ARGSUSED*/
static void
-db_vnode_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_vnode_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -579,7 +579,7 @@
}
static void
-db_mount_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_mount_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
boolean_t full = FALSE;
@@ -591,7 +591,7 @@
/*ARGSUSED*/
static void
-db_pool_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_pool_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
pool_printit((struct pool *)(intptr_t) addr, modif, db_printf);
@@ -600,7 +600,7 @@
/*ARGSUSED*/
static void
db_namecache_print_cmd(db_expr_t addr, int have_addr, db_expr_t count,
- char *modif)
+ const char *modif)
{
namecache_print((struct vnode *)(intptr_t) addr, db_printf);
@@ -608,7 +608,7 @@
/*ARGSUSED*/
static void
-db_uvmexp_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_uvmexp_print_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
uvmexp_print(db_printf);
@@ -620,7 +620,7 @@
*/
/*ARGSUSED*/
static void
-db_fncall(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_fncall(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
db_expr_t fn_addr;
#define MAXARGS 11
@@ -674,7 +674,7 @@
}
static void
-db_reboot_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_reboot_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
db_expr_t bootflags;
@@ -695,7 +695,7 @@
}
static void
-db_sifting_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_sifting_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
int mode, t;
@@ -725,9 +725,9 @@
}
static void
-db_stack_trace_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_stack_trace_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
- register char *cp = modif;
+ register const char *cp = modif;
register char c;
void (*pr)(const char *, ...);
@@ -743,7 +743,7 @@
}
static void
-db_sync_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
+db_sync_cmd(db_expr_t addr, int have_addr, db_expr_t count, const char *modif)
{
/*
diff -r 9ba0ffc0f7e0 -r 48fef698b1dc sys/ddb/db_command.h
--- a/sys/ddb/db_command.h Wed Jun 01 12:14:53 2005 +0000
+++ b/sys/ddb/db_command.h Wed Jun 01 12:25:27 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_command.h,v 1.23 2005/05/29 21:31:05 christos Exp $ */
+/* $NetBSD: db_command.h,v 1.24 2005/06/01 12:25:27 drochner Exp $ */
/*
* Mach Operating System
@@ -51,7 +51,7 @@
struct db_command {
const char *name; /* command name */
/* function to call */
- void (*fcn)(db_expr_t, int, db_expr_t, char *);
+ void (*fcn)(db_expr_t, int, db_expr_t, const char *);
int flag; /* extra info: */
#define CS_OWN 0x1 /* non-standard syntax */
#define CS_MORE 0x2 /* standard syntax, but may have other
diff -r 9ba0ffc0f7e0 -r 48fef698b1dc sys/ddb/db_examine.c
--- a/sys/ddb/db_examine.c Wed Jun 01 12:14:53 2005 +0000
+++ b/sys/ddb/db_examine.c Wed Jun 01 12:25:27 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_examine.c,v 1.26 2003/11/09 20:52:18 scw Exp $ */
+/* $NetBSD: db_examine.c,v 1.27 2005/06/01 12:25:27 drochner Exp $ */
Home |
Main Index |
Thread Index |
Old Index