summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
authorpraks <none@none>2007-05-14 19:53:19 -0700
committerpraks <none@none>2007-05-14 19:53:19 -0700
commitb5dcc7df5f27c97121911f525de281e77e52dcec (patch)
treee922c4258e9f04d5b46b244910c0758e402c0131 /usr/src
parent12324110900922d0b1d90282680898ccbe4224dc (diff)
downloadillumos-joyent-b5dcc7df5f27c97121911f525de281e77e52dcec.tar.gz
6509627 filling up /tmp hangs s10+ systems
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/uts/common/fs/tmpfs/tmp_vnops.c21
1 files changed, 3 insertions, 18 deletions
diff --git a/usr/src/uts/common/fs/tmpfs/tmp_vnops.c b/usr/src/uts/common/fs/tmpfs/tmp_vnops.c
index 236d2bfd4b..8932732a29 100644
--- a/usr/src/uts/common/fs/tmpfs/tmp_vnops.c
+++ b/usr/src/uts/common/fs/tmpfs/tmp_vnops.c
@@ -268,32 +268,20 @@ wrtmp(
}
/*
- * We have to drop the contents lock to prevent the VM
- * system from trying to reaquire it in tmp_getpage()
- * should the uiomove cause a pagefault. If we're doing
- * a pagecreate segmap creates the page without calling
- * the filesystem so we need to hold onto the lock until
- * the page is created.
+ * We have to drop the contents lock to allow the VM
+ * system to reaquire it in tmp_getpage()
*/
- if (!pagecreate)
- rw_exit(&tp->tn_contents);
+ rw_exit(&tp->tn_contents);
newpage = 0;
if (vpm_enable) {
/*
- * XXX Why do we need to hold the contents lock?
- * The kpm mappings will not cause a fault.
- *
* Copy data. If new pages are created, part of
* the page that is not written will be initizliazed
* with zeros.
*/
error = vpm_data_copy(vp, offset, bytes, uio,
!pagecreate, &newpage, 1, S_WRITE);
-
- if (pagecreate) {
- rw_exit(&tp->tn_contents);
- }
} else {
/* Get offset within the segmap mapping */
segmap_offset = (offset & PAGEMASK) & MAXBOFFSET;
@@ -304,15 +292,12 @@ wrtmp(
if (!vpm_enable && pagecreate) {
- rw_downgrade(&tp->tn_contents);
-
/*
* segmap_pagecreate() returns 1 if it calls
* page_create_va() to allocate any pages.
*/
newpage = segmap_pagecreate(segkmap,
base + segmap_offset, (size_t)PAGESIZE, 0);
- rw_exit(&tp->tn_contents);
/*
* Clear from the beginning of the page to the starting
* offset of the data.