diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-21 13:50:28 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-21 13:50:28 -0400 |
commit | 7ce1418f95e918cfc5ad36e3ec3431145c768cd0 (patch) | |
tree | 10fd5bf66a5d0cb71cbf0ffb17b354969a7cc4c4 /fs/jbd/commit.c | |
parent | a6f039869ff87e0a8d621e31d14bbb120c1dfa93 (diff) | |
parent | 1907131bbeabb33db313bad34f3ec1a5faedbd64 (diff) |
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: (31 commits)
dquot: Detect partial write error to quota file in write_blk() and add printk_ratelimit for quota error messages
ocfs2: Fix lock inversion in quotas during umount
ocfs2: Use __dquot_transfer to avoid lock inversion
ocfs2: Fix NULL pointer deref when writing local dquot
ocfs2: Fix estimate of credits needed for quota allocation
ocfs2: Fix quota locking
ocfs2: Avoid unnecessary block mapping when refreshing quota info
ocfs2: Do not map blocks from local quota file on each write
quota: Refactor dquot_transfer code so that OCFS2 can pass in its references
quota: unify quota init condition in setattr
quota: remove sb_has_quota_active in get/set_info
quota: unify ->set_dqblk
quota: unify ->get_dqblk
ext3: make barrier options consistent with ext4
quota: Make quota stat accounting lockless.
suppress warning: "quotatypes" defined but not used
ext3: Fix waiting on transaction during fsync
jbd: Provide function to check whether transaction will issue data barrier
ufs: add ufs speciffic ->setattr call
BKL: Remove BKL from ext2 filesystem
...
Diffstat (limited to 'fs/jbd/commit.c')
-rw-r--r-- | fs/jbd/commit.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/fs/jbd/commit.c b/fs/jbd/commit.c index ecb44c94ba8d..28a9ddaa0c49 100644 --- a/fs/jbd/commit.c +++ b/fs/jbd/commit.c | |||
@@ -786,6 +786,12 @@ wait_for_iobuf: | |||
786 | 786 | ||
787 | jbd_debug(3, "JBD: commit phase 6\n"); | 787 | jbd_debug(3, "JBD: commit phase 6\n"); |
788 | 788 | ||
789 | /* All metadata is written, now write commit record and do cleanup */ | ||
790 | spin_lock(&journal->j_state_lock); | ||
791 | J_ASSERT(commit_transaction->t_state == T_COMMIT); | ||
792 | commit_transaction->t_state = T_COMMIT_RECORD; | ||
793 | spin_unlock(&journal->j_state_lock); | ||
794 | |||
789 | if (journal_write_commit_record(journal, commit_transaction)) | 795 | if (journal_write_commit_record(journal, commit_transaction)) |
790 | err = -EIO; | 796 | err = -EIO; |
791 | 797 | ||
@@ -923,7 +929,7 @@ restart_loop: | |||
923 | 929 | ||
924 | jbd_debug(3, "JBD: commit phase 8\n"); | 930 | jbd_debug(3, "JBD: commit phase 8\n"); |
925 | 931 | ||
926 | J_ASSERT(commit_transaction->t_state == T_COMMIT); | 932 | J_ASSERT(commit_transaction->t_state == T_COMMIT_RECORD); |
927 | 933 | ||
928 | commit_transaction->t_state = T_FINISHED; | 934 | commit_transaction->t_state = T_FINISHED; |
929 | J_ASSERT(commit_transaction == journal->j_committing_transaction); | 935 | J_ASSERT(commit_transaction == journal->j_committing_transaction); |