add patch fix-ext4_show_options-for-fs-wo-journal
[ext4-patch-queue.git] / remove-repeated-assignments-in-jbd2_log_wait_for_space
blobf95eb5018e7117950fe061b401ca11b2fe3e2866
1 jbd2: remove repeated assignments in __jbd2_log_wait_for_space()
3 From: Liu Song <liu.song11@zte.com.cn>
5 At the beginning, nblocks has been assigned. There is no need
6 to repeat the assignment in the while loop, and remove it.
8 Signed-off-by: Liu Song <liu.song11@zte.com.cn>
9 Signed-off-by: Theodore Ts'o <tytso@mit.edu>
10 Reviewed-by: Jan Kara <jack@suse.cz>
11 ---
12  fs/jbd2/checkpoint.c | 1 -
13  1 file changed, 1 deletion(-)
15 diff --git a/fs/jbd2/checkpoint.c b/fs/jbd2/checkpoint.c
16 index 26f8d7e46462..23053de5e999 100644
17 --- a/fs/jbd2/checkpoint.c
18 +++ b/fs/jbd2/checkpoint.c
19 @@ -132,7 +132,6 @@ void __jbd2_log_wait_for_space(journal_t *journal)
20                         return;
21                 }
22                 spin_lock(&journal->j_list_lock);
23 -               nblocks = jbd2_space_needed(journal);
24                 space_left = jbd2_log_space_left(journal);
25                 if (space_left < nblocks) {
26                         int chkpt = journal->j_checkpoint_transactions != NULL;
27 -- 
28 2.19.1