Turn off cache if there's more than one kernel mapping, and one is writable.

Submitted by:   Mark Tinguely
This commit is contained in:
Olivier Houchard 2010-06-15 22:16:02 +00:00
parent 96c170aa1a
commit 8b1f99cdd4

View File

@ -1368,7 +1368,7 @@ pmap_fix_cache(struct vm_page *pg, pmap_t pm, vm_offset_t va)
* check for kernel uncachable conditions
* kernel writable or kernel readable with writable user entry
*/
if ((kwritable && entries) ||
if ((kwritable && (entries || kentries > 1)) ||
(kwritable > 1) ||
((kwritable != writable) && kentries &&
(pv->pv_pmap == pmap_kernel() ||