journal.c (eea86b637a15bc4d4bd518b11330ac96baa6b73d) | journal.c (c52c47e4b4fbe4284602fc2ccbfc4a4d8dc05b49) |
---|---|
1/* 2 * linux/fs/jbd2/journal.c 3 * 4 * Written by Stephen C. Tweedie <sct@redhat.com>, 1998 5 * 6 * Copyright 1998 Red Hat corp --- All Rights Reserved 7 * 8 * This file is part of the Linux kernel and is made available under --- 677 unchanged lines hidden (view full) --- 686/* 687 * Wait for a specified commit to complete. 688 * The caller may not hold the journal lock. 689 */ 690int jbd2_log_wait_commit(journal_t *journal, tid_t tid) 691{ 692 int err = 0; 693 | 1/* 2 * linux/fs/jbd2/journal.c 3 * 4 * Written by Stephen C. Tweedie <sct@redhat.com>, 1998 5 * 6 * Copyright 1998 Red Hat corp --- All Rights Reserved 7 * 8 * This file is part of the Linux kernel and is made available under --- 677 unchanged lines hidden (view full) --- 686/* 687 * Wait for a specified commit to complete. 688 * The caller may not hold the journal lock. 689 */ 690int jbd2_log_wait_commit(journal_t *journal, tid_t tid) 691{ 692 int err = 0; 693 |
694 jbd2_might_wait_for_commit(journal); | |
695 read_lock(&journal->j_state_lock); | 694 read_lock(&journal->j_state_lock); |
695#ifdef CONFIG_PROVE_LOCKING 696 /* 697 * Some callers make sure transaction is already committing and in that 698 * case we cannot block on open handles anymore. So don't warn in that 699 * case. 700 */ 701 if (tid_gt(tid, journal->j_commit_sequence) && 702 (!journal->j_committing_transaction || 703 journal->j_committing_transaction->t_tid != tid)) { 704 read_unlock(&journal->j_state_lock); 705 jbd2_might_wait_for_commit(journal); 706 read_lock(&journal->j_state_lock); 707 } 708#endif |
|
696#ifdef CONFIG_JBD2_DEBUG 697 if (!tid_geq(journal->j_commit_request, tid)) { 698 printk(KERN_ERR 699 "%s: error: j_commit_request=%d, tid=%d\n", 700 __func__, journal->j_commit_request, tid); 701 } 702#endif 703 while (tid_gt(tid, journal->j_commit_sequence)) { --- 1976 unchanged lines hidden --- | 709#ifdef CONFIG_JBD2_DEBUG 710 if (!tid_geq(journal->j_commit_request, tid)) { 711 printk(KERN_ERR 712 "%s: error: j_commit_request=%d, tid=%d\n", 713 __func__, journal->j_commit_request, tid); 714 } 715#endif 716 while (tid_gt(tid, journal->j_commit_sequence)) { --- 1976 unchanged lines hidden --- |