On today's kernels masking with ~KERNBASE is turning out to be less

than useful.  It still hits at least 8 digits. Adjust for reality.

This is still not satisfactory for the alpha if you add "-O paddr".
This commit is contained in:
Peter Wemm 2001-08-24 09:56:44 +00:00
parent fbb75ab833
commit 7d1192a784
2 changed files with 4 additions and 4 deletions

View File

@ -125,11 +125,11 @@ VAR var[] = {
NULL, USER, rvar, NULL, 4, ROFF(ru_nswap), LONG, "ld"},
{"nvcsw", "NVCSW",
NULL, USER, rvar, NULL, 5, ROFF(ru_nvcsw), LONG, "ld"},
{"nwchan", "WCHAN", NULL, 0, kvar, NULL, 6, KOFF(ki_wchan), KPTR, "lx"},
{"nwchan", "WCHAN", NULL, 0, kvar, NULL, 8, KOFF(ki_wchan), KPTR, "lx"},
{"oublk", "OUBLK",
NULL, USER, rvar, NULL, 4, ROFF(ru_oublock), LONG, "ld"},
{"oublock", "", "oublk"},
{"paddr", "PADDR", NULL, 0, kvar, NULL, 6, KOFF(ki_paddr), KPTR, "lx"},
{"paddr", "PADDR", NULL, 0, kvar, NULL, 8, KOFF(ki_paddr), KPTR, "lx"},
{"pagein", "PAGEIN", NULL, USER, pagein, NULL, 6},
{"pcpu", "", "%cpu"},
{"pending", "", "sig"},

View File

@ -432,7 +432,7 @@ wchan(k, ve)
k->ki_p->ki_wmesg);
else
(void)printf("%-*lx", v->width,
(long)k->ki_p->ki_wchan &~ KERNBASE);
(long)k->ki_p->ki_wchan);
} else
(void)printf("%-*s", v->width, "-");
}
@ -696,7 +696,7 @@ printval(bp, v)
(void)printf(ofmt, v->width, *(u_long *)bp);
break;
case KPTR:
(void)printf(ofmt, v->width, *(u_long *)bp &~ KERNBASE);
(void)printf(ofmt, v->width, *(u_long *)bp);
break;
default:
errx(1, "unknown type %d", v->type);