]> Zhao Yanbai Git Server - minix.git/commitdiff
Prettify scheduling queue prints
authorBen Gras <ben@minix3.org>
Wed, 27 Jul 2005 14:30:17 +0000 (14:30 +0000)
committerBen Gras <ben@minix3.org>
Wed, 27 Jul 2005 14:30:17 +0000 (14:30 +0000)
servers/is/dmp_kernel.c

index b04678b9e8b3b104c65b5344934074ad6217732d..6331ea8205615e2767e2d45f2fe08565e226bfbb 100644 (file)
@@ -212,7 +212,6 @@ PUBLIC void image_dmp()
 PUBLIC void sched_dmp()
 {
   struct proc *rdy_head[NR_SCHED_QUEUES];
-  char *types[] = {"task","higher","high","normal","low","lower","user","idle"};
   struct kinfo kinfo;
   register struct proc *rp;
   vir_bytes ptr_diff;
@@ -244,13 +243,14 @@ PUBLIC void sched_dmp()
   printf("Dumping scheduling queues.\n");
 
   for (r=0;r<NR_SCHED_QUEUES; r++) {
-      printf("* %6s: ", types[r]);
       rp = rdy_head[r];
+      if(!rp) continue;
+      printf("%2d: ", r);
       while (rp != NIL_PROC) {
-          printf("%3d, ", rp->p_nr);
+          printf("%3d ", rp->p_nr);
           rp = rp->p_nextready;
       }
-      printf("NIL\n");
+      printf("\n");
   }
   printf("\n");
 }