summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_exec.c
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2016-08-28 05:18:39 +0000
committeralc <alc@FreeBSD.org>2016-08-28 05:18:39 +0000
commitee96ae8977c1a30b6bd6d5368ea3ecaa02c86ff3 (patch)
tree29f486087062371cdb54a32a0a03c35d3d04297c /sys/kern/kern_exec.c
parentc50b56b0205a3d9a30ed5af9a67710e872324be7 (diff)
downloadFreeBSD-src-ee96ae8977c1a30b6bd6d5368ea3ecaa02c86ff3.zip
FreeBSD-src-ee96ae8977c1a30b6bd6d5368ea3ecaa02c86ff3.tar.gz
MFC r304050
Eliminate two calls to vm_page_xunbusy() that are both unnecessary and incorrect from the error cases in exec_map_first_page(). They are unnecessary because we automatically unbusy the page in vm_page_free() when we remove it from the object. The calls are incorrect because they happen after the page is freed, so we might actually unbusy the page after it has been reallocated to a different object. (This error was introduced in r292373.)
Diffstat (limited to 'sys/kern/kern_exec.c')
-rw-r--r--sys/kern/kern_exec.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c
index df8e903..3873c5a 100644
--- a/sys/kern/kern_exec.c
+++ b/sys/kern/kern_exec.c
@@ -990,7 +990,6 @@ exec_map_first_page(imgp)
vm_page_lock(ma[0]);
vm_page_free(ma[0]);
vm_page_unlock(ma[0]);
- vm_page_xunbusy(ma[0]);
VM_OBJECT_WUNLOCK(object);
return (EIO);
}
@@ -1018,7 +1017,6 @@ exec_map_first_page(imgp)
vm_page_lock(ma[i]);
vm_page_free(ma[i]);
vm_page_unlock(ma[i]);
- vm_page_xunbusy(ma[i]);
}
VM_OBJECT_WUNLOCK(object);
return (EIO);
OpenPOWER on IntegriCloud