diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-21 15:39:53 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-21 15:39:53 -0400 |
| commit | f6f0a6d6a7258eff41fd202fc70df18271a2de79 (patch) | |
| tree | a32040d8cc6e06e056e184e35ed4729e28a244d8 /fs/gfs2/file.c | |
| parent | 2017bd19454ea7cdae19922d15b6930f6c8088a2 (diff) | |
| parent | 33027af637da3f69bd17488cc3e68493c9052a7d (diff) | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-2.6-nmw
* git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-2.6-nmw: (22 commits)
GFS2: fixed typo
GFS2: Fix type mapping for demote_rq interface
GFS2 fatal: filesystem consistency error on rename
GFS2: Improve journal allocation via sysfs
GFS2: Add "norecovery" mount option as a synonym for "spectator"
GFS2: Fix spectator umount issue
GFS2: Fix compiler warning from previous patch
GFS2: reserve more blocks for transactions
GFS2: Fix journal check for spectator mounts
GFS2: Remove upgrade mount option
GFS2: Remove localcaching mount option
GFS2: Remove ignore_local_fs mount argument
GFS2: Make . and .. qstrs constant
GFS2: Use new workqueue scheme
GFS2: Update handling of DLM return codes to match reality
GFS2: Don't enforce min hold time when two demotes occur in rapid succession
GFS2: Fix whitespace in previous patch
GFS2: fallocate support
GFS2: Add a bug trap in allocation code
GFS2: No longer experimental
...
Diffstat (limited to 'fs/gfs2/file.c')
| -rw-r--r-- | fs/gfs2/file.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c index 4edd662c8232..237ee6a940df 100644 --- a/fs/gfs2/file.c +++ b/fs/gfs2/file.c | |||
| @@ -382,8 +382,10 @@ static int gfs2_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf) | |||
| 382 | rblocks = RES_DINODE + ind_blocks; | 382 | rblocks = RES_DINODE + ind_blocks; |
| 383 | if (gfs2_is_jdata(ip)) | 383 | if (gfs2_is_jdata(ip)) |
| 384 | rblocks += data_blocks ? data_blocks : 1; | 384 | rblocks += data_blocks ? data_blocks : 1; |
| 385 | if (ind_blocks || data_blocks) | 385 | if (ind_blocks || data_blocks) { |
| 386 | rblocks += RES_STATFS + RES_QUOTA; | 386 | rblocks += RES_STATFS + RES_QUOTA; |
| 387 | rblocks += gfs2_rg_blocks(al); | ||
| 388 | } | ||
| 387 | ret = gfs2_trans_begin(sdp, rblocks, 0); | 389 | ret = gfs2_trans_begin(sdp, rblocks, 0); |
| 388 | if (ret) | 390 | if (ret) |
| 389 | goto out_trans_fail; | 391 | goto out_trans_fail; |
| @@ -491,7 +493,7 @@ static int gfs2_open(struct inode *inode, struct file *file) | |||
| 491 | goto fail; | 493 | goto fail; |
| 492 | 494 | ||
| 493 | if (!(file->f_flags & O_LARGEFILE) && | 495 | if (!(file->f_flags & O_LARGEFILE) && |
| 494 | ip->i_disksize > MAX_NON_LFS) { | 496 | i_size_read(inode) > MAX_NON_LFS) { |
| 495 | error = -EOVERFLOW; | 497 | error = -EOVERFLOW; |
| 496 | goto fail_gunlock; | 498 | goto fail_gunlock; |
| 497 | } | 499 | } |
