Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

jbd2: remove unused 'JBD2_CHECKPOINT_IO_ERROR' and 'j_atomic_flags'

Since 'JBD2_CHECKPOINT_IO_ERROR' and j_atomic_flags' are not useful
anymore after fs dev's errseq is imported into jbd2, just remove them.

Signed-off-by: Zhihao Cheng <chengzhihao1@huawei.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20231213013224.2100050-4-chengzhihao1@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>

authored by

Zhihao Cheng and committed by
Theodore Ts'o
8a4fd33d 62ec1707

-22
-11
fs/jbd2/checkpoint.c
··· 556 556 struct transaction_chp_stats_s *stats; 557 557 transaction_t *transaction; 558 558 journal_t *journal; 559 - struct buffer_head *bh = jh2bh(jh); 560 559 561 560 JBUFFER_TRACE(jh, "entry"); 562 561 ··· 567 568 journal = transaction->t_journal; 568 569 569 570 JBUFFER_TRACE(jh, "removing from transaction"); 570 - 571 - /* 572 - * If we have failed to write the buffer out to disk, the filesystem 573 - * may become inconsistent. We cannot abort the journal here since 574 - * we hold j_list_lock and we have to be careful about races with 575 - * jbd2_journal_destroy(). So mark the writeback IO error in the 576 - * journal here and we abort the journal later from a better context. 577 - */ 578 - if (buffer_write_io_error(bh)) 579 - set_bit(JBD2_CHECKPOINT_IO_ERROR, &journal->j_atomic_flags); 580 571 581 572 __buffer_unlink(jh); 582 573 jh->b_cp_transaction = NULL;
-11
include/linux/jbd2.h
··· 756 756 unsigned long j_flags; 757 757 758 758 /** 759 - * @j_atomic_flags: Atomic journaling state flags. 760 - */ 761 - unsigned long j_atomic_flags; 762 - 763 - /** 764 759 * @j_errno: 765 760 * 766 761 * Is there an outstanding uncleared error on the journal (from a prior ··· 1400 1405 #define JBD2_JOURNAL_FLUSH_ZEROOUT 0x0002 1401 1406 #define JBD2_JOURNAL_FLUSH_VALID (JBD2_JOURNAL_FLUSH_DISCARD | \ 1402 1407 JBD2_JOURNAL_FLUSH_ZEROOUT) 1403 - 1404 - /* 1405 - * Journal atomic flag definitions 1406 - */ 1407 - #define JBD2_CHECKPOINT_IO_ERROR 0x001 /* Detect io error while writing 1408 - * buffer back to disk */ 1409 1408 1410 1409 /* 1411 1410 * Function declarations for the journaling transaction and buffer