Grab Giant around fault handling at the top level for now.
This commit is contained in:
parent
cc8833dfe9
commit
3c7ad73470
@ -523,6 +523,7 @@ trap(a0, a1, a2, entry, framep)
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mtx_lock(&Giant);
|
||||||
/*
|
/*
|
||||||
* It is only a kernel address space fault iff:
|
* It is only a kernel address space fault iff:
|
||||||
* 1. !user and
|
* 1. !user and
|
||||||
@ -629,9 +630,11 @@ trap(a0, a1, a2, entry, framep)
|
|||||||
rv = KERN_INVALID_ADDRESS;
|
rv = KERN_INVALID_ADDRESS;
|
||||||
}
|
}
|
||||||
if (rv == KERN_SUCCESS) {
|
if (rv == KERN_SUCCESS) {
|
||||||
|
mtx_unlock(&Giant);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mtx_unlock(&Giant);
|
||||||
if (!user) {
|
if (!user) {
|
||||||
/* Check for copyin/copyout fault */
|
/* Check for copyin/copyout fault */
|
||||||
if (p != NULL &&
|
if (p != NULL &&
|
||||||
|
Loading…
x
Reference in New Issue
Block a user