From d97a37008532b93102b937a8a28129f0f43d8022 Mon Sep 17 00:00:00 2001 From: Ksawlii Date: Sun, 24 Nov 2024 00:23:04 +0100 Subject: [PATCH] Revert "ext4: fix incorrect tid assumption in __jbd2_log_wait_for_space()" This reverts commit 12dbad509919025e575a8ada0f8e04846d72ea08. --- fs/jbd2/checkpoint.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/fs/jbd2/checkpoint.c b/fs/jbd2/checkpoint.c index 35bd2752f..7898983c9 100755 --- a/fs/jbd2/checkpoint.c +++ b/fs/jbd2/checkpoint.c @@ -115,12 +115,9 @@ __releases(&journal->j_state_lock) if (space_left < nblocks) { int chkpt = journal->j_checkpoint_transactions != NULL; tid_t tid = 0; - bool has_transaction = false; - if (journal->j_committing_transaction) { + if (journal->j_committing_transaction) tid = journal->j_committing_transaction->t_tid; - has_transaction = true; - } spin_unlock(&journal->j_list_lock); write_unlock(&journal->j_state_lock); if (chkpt) { @@ -128,7 +125,7 @@ __releases(&journal->j_state_lock) } else if (jbd2_cleanup_journal_tail(journal) == 0) { /* We were able to recover space; yay! */ ; - } else if (has_transaction) { + } else if (tid) { /* * jbd2_journal_commit_transaction() may want * to take the checkpoint_mutex if JBD2_FLUSHED