From c17c1b915d3111d18a76bf56ac4f95d6a2cf5c17 Mon Sep 17 00:00:00 2001 From: jchandra Date: Fri, 6 Aug 2010 07:32:33 +0000 Subject: Fix the issue reported by alc: pmap_page_wired_mappings() counts the number of pv entries for the specified page that have the pv entry wired flag set to TRUE. pmap_enter() correctly initializes this flag. However, pmap_change_wiring() doesn't update the corresponding pv entry flag, only the PTE. So, the count returned by pmap_page_wired_mappings() will sometimes be wrong. In the short term, the best fix would be to eliminate the pv entry flag and use only the PTE. That flag is wasting non-trivial memory. Remove pv_wired flag, and use PTE flag to count the wired mappings. Reviewed by: alc --- sys/mips/include/pmap.h | 1 - 1 file changed, 1 deletion(-) (limited to 'sys/mips/include/pmap.h') diff --git a/sys/mips/include/pmap.h b/sys/mips/include/pmap.h index 3e7b937..0b4ef8a 100644 --- a/sys/mips/include/pmap.h +++ b/sys/mips/include/pmap.h @@ -124,7 +124,6 @@ typedef struct pv_entry { TAILQ_ENTRY(pv_entry) pv_list; TAILQ_ENTRY(pv_entry) pv_plist; vm_page_t pv_ptem; /* VM page for pte */ - boolean_t pv_wired; /* whether this entry is wired */ } *pv_entry_t; -- cgit v1.1