From: Ben Gras Date: Mon, 21 Sep 2009 14:47:24 +0000 (+0000) Subject: no more scheduling queue dumps (kernel will print this over serial); X-Git-Tag: v3.1.5~122 X-Git-Url: http://zhaoyanbai.com/repos/doxygen-warnings.log?a=commitdiff_plain;h=08d291da5380a0523ac94301f7f3903d2ae5858d;p=minix.git no more scheduling queue dumps (kernel will print this over serial); initial vm stats retrieve support --- diff --git a/servers/is/dmp.c b/servers/is/dmp.c index bc9d1f901..5294de241 100644 --- a/servers/is/dmp.c +++ b/servers/is/dmp.c @@ -8,6 +8,7 @@ */ #include "inc.h" +#include struct hook_entry { int key; @@ -21,7 +22,7 @@ struct hook_entry { { F5, monparams_dmp, "Boot monitor parameters" }, { F6, irqtab_dmp, "IRQ hooks and policies" }, { F7, kmessages_dmp, "Kernel messages" }, - { F9, sched_dmp, "Scheduling queues" }, + { F8, vm_dmp, "VM status" }, { F10, kenv_dmp, "Kernel parameters" }, { F11, timing_dmp, "Timing details (if enabled)" }, { SF1, mproc_dmp, "Process manager process table" }, @@ -100,3 +101,11 @@ PUBLIC void mapping_dmp(void) printf("\n"); } +/*===========================================================================* + * vm_dmp * + *===========================================================================*/ +PUBLIC void vm_dmp(void) +{ + vm_ctl(VCTLP_STATS_MEM, 0); + +} diff --git a/servers/is/dmp_kernel.c b/servers/is/dmp_kernel.c index a5a9c6960..3f01f5112 100644 --- a/servers/is/dmp_kernel.c +++ b/servers/is/dmp_kernel.c @@ -224,54 +224,6 @@ PUBLIC void image_dmp() printf("\n"); } -/*===========================================================================* - * sched_dmp * - *===========================================================================*/ -PUBLIC void sched_dmp() -{ - struct proc *rdy_head[NR_SCHED_QUEUES]; - struct kinfo kinfo; - register struct proc *rp; - vir_bytes ptr_diff; - int r; - - /* First obtain a scheduling information. */ - if ((r = sys_getschedinfo(proc, rdy_head)) != OK) { - report("IS","warning: couldn't get copy of process table", r); - return; - } - /* Then obtain kernel addresses to correct pointer information. */ - if ((r = sys_getkinfo(&kinfo)) != OK) { - report("IS","warning: couldn't get kernel addresses", r); - return; - } - - /* Update all pointers. Nasty pointer algorithmic ... */ - ptr_diff = (vir_bytes) proc - (vir_bytes) kinfo.proc_addr; - for (r=0;rp_nextready != NIL_PROC) - rp->p_nextready = - (struct proc *)((vir_bytes) rp->p_nextready + ptr_diff); - - /* Now show scheduling queues. */ - printf("Dumping scheduling queues.\n"); - - for (r=0;rp_nr); - rp = rp->p_nextready; - } - printf("\n"); - } - printf("\n"); -} /*===========================================================================* * kenv_dmp * @@ -311,9 +263,6 @@ PUBLIC void kenv_dmp() printf("- nr_tasks: %3u\n", kinfo.nr_tasks); printf("- release: %.6s\n", kinfo.release); printf("- version: %.6s\n", kinfo.version); -#if DEBUG_LOCK_CHECK - printf("- relocking: %d\n", kinfo.relocking); -#endif printf("\n"); } @@ -363,7 +312,7 @@ PUBLIC void privileges_dmp() return; } - printf("\n--nr-id-name---- -flags- -traps- grants -ipc_to-- -system calls--\n"); + printf("\n--nr-id-name---- -flags- -traps- grants -ipc_to-- -ipc_sr-- -system calls--\n"); PROCLOOP(rp, oldrp) r = -1; diff --git a/servers/is/proto.h b/servers/is/proto.h index 7b71b2c49..617d9f27f 100644 --- a/servers/is/proto.h +++ b/servers/is/proto.h @@ -6,6 +6,7 @@ _PROTOTYPE( int main, (int argc, char **argv) ); /* dmp.c */ _PROTOTYPE( int do_fkey_pressed, (message *m) ); _PROTOTYPE( void mapping_dmp, (void) ); +_PROTOTYPE( void vm_dmp, (void) ); /* dmp_kernel.c */ _PROTOTYPE( void proctab_dmp, (void) );