summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-09-13 21:46:09 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2010-09-13 21:46:09 +0200
commit2bb3a259d8205e5779d59343994828376b0e2d96 (patch)
tree08abada555c8e4ebcd40eac9c041f4556a6a43a4 /include
parentMerge branch 'next-spi' of git://git.secretlab.ca/git/linux-2.6 (diff)
parentdquot: do full inode dirty in allocating space (diff)
downloadlinux-2bb3a259d8205e5779d59343994828376b0e2d96.tar.xz
linux-2bb3a259d8205e5779d59343994828376b0e2d96.zip
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs-2.6
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs-2.6: dquot: do full inode dirty in allocating space
Diffstat (limited to 'include')
-rw-r--r--include/linux/quotaops.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/include/linux/quotaops.h b/include/linux/quotaops.h
index d50ba858cfe0..d1a9193960f1 100644
--- a/include/linux/quotaops.h
+++ b/include/linux/quotaops.h
@@ -274,8 +274,14 @@ static inline int dquot_alloc_space(struct inode *inode, qsize_t nr)
int ret;
ret = dquot_alloc_space_nodirty(inode, nr);
- if (!ret)
- mark_inode_dirty_sync(inode);
+ if (!ret) {
+ /*
+ * Mark inode fully dirty. Since we are allocating blocks, inode
+ * would become fully dirty soon anyway and it reportedly
+ * reduces inode_lock contention.
+ */
+ mark_inode_dirty(inode);
+ }
return ret;
}