From bf94adb3e102749108abd5cf6923f9f4f97be8ee Mon Sep 17 00:00:00 2001 From: Konstantin Belousov Date: Thu, 14 Feb 2013 19:22:15 +0000 Subject: [PATCH] Print slightly more useful information on the 'bad pte' panic. No objections from: alc MFC after: 1 week --- sys/amd64/amd64/pmap.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index 4bdf38226e46..f30a071d6304 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -4446,8 +4446,10 @@ pmap_remove_pages(pmap_t pmap) pte = &pte[pmap_pte_index(pv->pv_va)]; tpte = *pte & ~PG_PTE_PAT; } - if ((tpte & PG_V) == 0) - panic("bad pte"); + if ((tpte & PG_V) == 0) { + panic("bad pte va %lx pte %lx", + pv->pv_va, tpte); + } /* * We cannot remove wired pages from a process' mapping at this time