svn commit: r255849 - head/sys/amd64/amd64
Konstantin Belousov
kib at FreeBSD.org
Tue Sep 24 13:52:48 UTC 2013
Author: kib
Date: Tue Sep 24 13:52:47 2013
New Revision: 255849
URL: http://svnweb.freebsd.org/changeset/base/255849
Log:
In pmap_clear_modify(), initialize pvh even for fictitious managed
page, otherwise the small mappings loop would use uninitialized value.
Note that currently pmap_clear_modify() is not called for fictitious
pages.
Sponsored by: The FreeBSD Foundation
Approved by: re (glebius)
Modified:
head/sys/amd64/amd64/pmap.c
Modified: head/sys/amd64/amd64/pmap.c
==============================================================================
--- head/sys/amd64/amd64/pmap.c Tue Sep 24 13:46:13 2013 (r255848)
+++ head/sys/amd64/amd64/pmap.c Tue Sep 24 13:52:47 2013 (r255849)
@@ -5331,13 +5331,13 @@ pmap_clear_modify(vm_page_t m)
*/
if ((m->aflags & PGA_WRITEABLE) == 0)
return;
+ pvh = pa_to_pvh(VM_PAGE_TO_PHYS(m));
rw_rlock(&pvh_global_lock);
lock = VM_PAGE_TO_PV_LIST_LOCK(m);
rw_wlock(lock);
restart:
if ((m->flags & PG_FICTITIOUS) != 0)
goto small_mappings;
- pvh = pa_to_pvh(VM_PAGE_TO_PHYS(m));
TAILQ_FOREACH_SAFE(pv, &pvh->pv_list, pv_next, next_pv) {
pmap = PV_PMAP(pv);
if (!PMAP_TRYLOCK(pmap)) {
More information about the svn-src-head
mailing list