Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern better debugging messages.



details:   https://anonhg.NetBSD.org/src/rev/24023ae318d2
branches:  trunk
changeset: 762866:24023ae318d2
user:      christos <christos%NetBSD.org@localhost>
date:      Fri Mar 04 04:17:12 2011 +0000

description:
better debugging messages.

diffstat:

 sys/kern/kern_exec.c |  19 ++++++++++++++-----
 1 files changed, 14 insertions(+), 5 deletions(-)

diffs (41 lines):

diff -r b048325562e4 -r 24023ae318d2 sys/kern/kern_exec.c
--- a/sys/kern/kern_exec.c      Fri Mar 04 03:34:24 2011 +0000
+++ b/sys/kern/kern_exec.c      Fri Mar 04 04:17:12 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_exec.c,v 1.309 2011/03/01 18:53:10 joerg Exp $    */
+/*     $NetBSD: kern_exec.c,v 1.310 2011/03/04 04:17:12 christos Exp $ */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -59,7 +59,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_exec.c,v 1.309 2011/03/01 18:53:10 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_exec.c,v 1.310 2011/03/04 04:17:12 christos Exp $");
 
 #include "opt_ktrace.h"
 #include "opt_modular.h"
@@ -823,10 +823,19 @@
                if (error) {
                        size_t j;
                        struct exec_vmcmd *vp = &pack.ep_vmcmds.evs_cmds[0];
+                       uprintf("vmcmds %zu/%u, error %d\n", i, 
+                           pack.ep_vmcmds.evs_used, error);
                        for (j = 0; j <= i; j++)
-                               uprintf(
-                       "vmcmd[%zu] = %#"PRIxVADDR"/%#"PRIxVSIZE" fd@%#"PRIxVSIZE" prot=0%o flags=%d\n",
-                                   j, vp[j].ev_addr, vp[j].ev_len,
+                               uprintf("vmcmd[%zu] = vmcmd_map_%s %#"
+                                   PRIxVADDR"/%#"PRIxVSIZE" fd@%#"
+                                   PRIxVSIZE" prot=0%o flags=%d\n", j,
+                                   vp[j].ev_proc == vmcmd_map_pagedvn ?
+                                   "pagedvn" :
+                                   vp[j].ev_proc == vmcmd_map_readvn ?
+                                   "readvn" :
+                                   vp[j].ev_proc == vmcmd_map_zero ?
+                                   "zero" : "*unknown*",
+                                   vp[j].ev_addr, vp[j].ev_len,
                                    vp[j].ev_offset, vp[j].ev_prot,
                                    vp[j].ev_flags);
                }



Home | Main Index | Thread Index | Old Index