mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 21:09:28 +00:00
MFi386 r1.369. Clear the PG_WRITEABLE flag in pmap_clear_write; return
immediately if its already clear. Suggested by: alc
This commit is contained in:
parent
84b427ce23
commit
7446769caf
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=106994
@ -1822,7 +1822,8 @@ pmap_clear_write(vm_page_t m)
|
||||
{
|
||||
struct tte *tp;
|
||||
|
||||
if ((m->flags & (PG_FICTITIOUS | PG_UNMANAGED)) != 0)
|
||||
if ((m->flags & (PG_FICTITIOUS | PG_UNMANAGED)) != 0 ||
|
||||
(m->flags & PG_WRITEABLE) == 0)
|
||||
return;
|
||||
STAILQ_FOREACH(tp, &m->md.tte_list, tte_link) {
|
||||
if ((tp->tte_data & TD_PV) == 0)
|
||||
@ -1836,6 +1837,7 @@ pmap_clear_write(vm_page_t m)
|
||||
tlb_page_demap(TTE_GET_PMAP(tp), TTE_GET_VA(tp));
|
||||
}
|
||||
}
|
||||
vm_page_flag_clear(m, PG_WRITEABLE);
|
||||
}
|
||||
|
||||
int
|
||||
|
Loading…
Reference in New Issue
Block a user