proc: load/store p_cowgen using atomic primitives

This commit is contained in:
Mateusz Guzik
2022-02-12 19:33:34 +00:00
parent 29ee49f66b
commit b53133a778
7 changed files with 9 additions and 8 deletions
+1 -1
View File
@@ -418,7 +418,7 @@ abort_handler(struct trapframe *tf, int prefetch)
p = td->td_proc;
if (usermode) {
td->td_pticks = 0;
if (td->td_cowgen != p->p_cowgen)
if (td->td_cowgen != atomic_load_int(&p->p_cowgen))
thread_cow_update(td);
}