/fs/jbd2/ |
D | journal.c | 107 static void __journal_abort_soft (journal_t *journal, int errno); 195 journal_t *journal = arg; in kjournald2() local 202 setup_timer(&journal->j_commit_timer, commit_timeout, in kjournald2() 208 journal->j_task = current; in kjournald2() 209 wake_up(&journal->j_wait_done_commit); in kjournald2() 222 write_lock(&journal->j_state_lock); in kjournald2() 225 if (journal->j_flags & JBD2_UNMOUNT) in kjournald2() 229 journal->j_commit_sequence, journal->j_commit_request); in kjournald2() 231 if (journal->j_commit_sequence != journal->j_commit_request) { in kjournald2() 233 write_unlock(&journal->j_state_lock); in kjournald2() [all …]
|
D | commit.c | 119 static int journal_submit_commit_record(journal_t *journal, in journal_submit_commit_record() argument 131 if (is_journal_aborted(journal)) in journal_submit_commit_record() 143 if (jbd2_has_feature_checksum(journal)) { in journal_submit_commit_record() 148 jbd2_commit_block_csum_set(journal, bh); in journal_submit_commit_record() 156 if (journal->j_flags & JBD2_BARRIER && in journal_submit_commit_record() 157 !jbd2_has_feature_async_commit(journal)) in journal_submit_commit_record() 171 static int journal_wait_on_commit_record(journal_t *journal, in journal_wait_on_commit_record() argument 215 static int journal_submit_data_buffers(journal_t *journal, in journal_submit_data_buffers() argument 222 spin_lock(&journal->j_list_lock); in journal_submit_data_buffers() 231 spin_unlock(&journal->j_list_lock); in journal_submit_data_buffers() [all …]
|
D | checkpoint.c | 111 void __jbd2_log_wait_for_space(journal_t *journal) in __jbd2_log_wait_for_space() argument 116 nblocks = jbd2_space_needed(journal); in __jbd2_log_wait_for_space() 117 while (jbd2_log_space_left(journal) < nblocks) { in __jbd2_log_wait_for_space() 118 write_unlock(&journal->j_state_lock); in __jbd2_log_wait_for_space() 119 mutex_lock(&journal->j_checkpoint_mutex); in __jbd2_log_wait_for_space() 132 write_lock(&journal->j_state_lock); in __jbd2_log_wait_for_space() 133 if (journal->j_flags & JBD2_ABORT) { in __jbd2_log_wait_for_space() 134 mutex_unlock(&journal->j_checkpoint_mutex); in __jbd2_log_wait_for_space() 137 spin_lock(&journal->j_list_lock); in __jbd2_log_wait_for_space() 138 nblocks = jbd2_space_needed(journal); in __jbd2_log_wait_for_space() [all …]
|
D | revoke.c | 134 static inline int hash(journal_t *journal, unsigned long long block) in hash() argument 136 return hash_64(block, journal->j_revoke->hash_shift); in hash() 139 static int insert_revoke_hash(journal_t *journal, unsigned long long blocknr, in insert_revoke_hash() argument 154 hash_list = &journal->j_revoke->hash_table[hash(journal, blocknr)]; in insert_revoke_hash() 155 spin_lock(&journal->j_revoke_lock); in insert_revoke_hash() 157 spin_unlock(&journal->j_revoke_lock); in insert_revoke_hash() 163 static struct jbd2_revoke_record_s *find_revoke_record(journal_t *journal, in find_revoke_record() argument 169 hash_list = &journal->j_revoke->hash_table[hash(journal, blocknr)]; in find_revoke_record() 171 spin_lock(&journal->j_revoke_lock); in find_revoke_record() 175 spin_unlock(&journal->j_revoke_lock); in find_revoke_record() [all …]
|
D | transaction.c | 84 jbd2_get_transaction(journal_t *journal, transaction_t *transaction) in jbd2_get_transaction() argument 86 transaction->t_journal = journal; in jbd2_get_transaction() 89 transaction->t_tid = journal->j_transaction_sequence++; in jbd2_get_transaction() 90 transaction->t_expires = jiffies + journal->j_commit_interval; in jbd2_get_transaction() 94 atomic_read(&journal->j_reserved_credits)); in jbd2_get_transaction() 100 journal->j_commit_timer.expires = round_jiffies_up(transaction->t_expires); in jbd2_get_transaction() 101 add_timer(&journal->j_commit_timer); in jbd2_get_transaction() 103 J_ASSERT(journal->j_running_transaction == NULL); in jbd2_get_transaction() 104 journal->j_running_transaction = transaction; in jbd2_get_transaction() 150 static void wait_transaction_locked(journal_t *journal) in wait_transaction_locked() argument [all …]
|
D | recovery.c | 42 static int do_one_pass(journal_t *journal, 70 static int do_readahead(journal_t *journal, unsigned int start) in do_readahead() argument 80 max = start + (128 * 1024 / journal->j_blocksize); in do_readahead() 81 if (max > journal->j_maxlen) in do_readahead() 82 max = journal->j_maxlen; in do_readahead() 90 err = jbd2_journal_bmap(journal, next, &blocknr); in do_readahead() 98 bh = __getblk(journal->j_dev, blocknr, journal->j_blocksize); in do_readahead() 132 static int jread(struct buffer_head **bhp, journal_t *journal, in jread() argument 141 if (offset >= journal->j_maxlen) { in jread() 146 err = jbd2_journal_bmap(journal, offset, &blocknr); in jread() [all …]
|
D | Makefile | 7 jbd2-objs := transaction.o commit.o recovery.o checkpoint.o revoke.o journal.o
|
D | Kconfig | 10 journal support to other file systems or block devices such
|
/fs/reiserfs/ |
D | journal.c | 96 struct reiserfs_journal *journal); 117 struct reiserfs_journal *journal = SB_JOURNAL(sb); in init_journal_hash() local 118 memset(journal->j_hash_table, 0, in init_journal_hash() 159 struct reiserfs_journal *journal = SB_JOURNAL(sb); in get_bitmap_node() local 161 struct list_head *entry = journal->j_bitmap_nodes.next; in get_bitmap_node() 163 journal->j_used_bitmap_nodes++; in get_bitmap_node() 166 if (entry != &journal->j_bitmap_nodes) { in get_bitmap_node() 170 journal->j_free_bitmap_nodes--; in get_bitmap_node() 183 struct reiserfs_journal *journal = SB_JOURNAL(sb); in free_bitmap_node() local 184 journal->j_used_bitmap_nodes--; in free_bitmap_node() [all …]
|
D | super.c | 730 struct reiserfs_journal *journal = SB_JOURNAL(s); in reiserfs_show_options() local 770 if (journal->j_max_commit_age != journal->j_default_max_commit_age) in reiserfs_show_options() 771 seq_printf(seq, ",commit=%d", journal->j_max_commit_age); in reiserfs_show_options() 1445 struct reiserfs_journal *journal = SB_JOURNAL(s); in reiserfs_remount() local 1511 journal->j_max_commit_age = commit_max_age; in reiserfs_remount() 1512 journal->j_max_trans_age = commit_max_age; in reiserfs_remount() 1515 journal->j_max_commit_age = journal->j_default_max_commit_age; in reiserfs_remount() 1516 journal->j_max_trans_age = JOURNAL_MAX_TRANS_AGE; in reiserfs_remount() 1561 if (reiserfs_is_journal_aborted(journal)) { in reiserfs_remount() 1562 err = journal->j_errno; in reiserfs_remount()
|
D | Makefile | 10 hashes.o tail_conversion.o journal.o resize.o \
|
/fs/ocfs2/ |
D | journal.c | 77 static void ocfs2_queue_recovery_completion(struct ocfs2_journal *journal, 170 ocfs2_queue_recovery_completion(osb->journal, i, NULL, in ocfs2_queue_replay_slots() 312 struct ocfs2_journal *journal = NULL; in ocfs2_commit_cache() local 314 journal = osb->journal; in ocfs2_commit_cache() 317 down_write(&journal->j_trans_barrier); in ocfs2_commit_cache() 319 flushed = atomic_read(&journal->j_num_trans); in ocfs2_commit_cache() 322 up_write(&journal->j_trans_barrier); in ocfs2_commit_cache() 326 jbd2_journal_lock_updates(journal->j_journal); in ocfs2_commit_cache() 327 status = jbd2_journal_flush(journal->j_journal); in ocfs2_commit_cache() 328 jbd2_journal_unlock_updates(journal->j_journal); in ocfs2_commit_cache() [all …]
|
D | journal.h | 94 static inline void ocfs2_set_ci_lock_trans(struct ocfs2_journal *journal, in ocfs2_set_ci_lock_trans() argument 98 ci->ci_last_trans = journal->j_trans_id; in ocfs2_set_ci_lock_trans() 110 struct ocfs2_journal *journal = in ocfs2_ci_fully_checkpointed() local 111 OCFS2_SB(ocfs2_metadata_cache_get_super(ci))->journal; in ocfs2_ci_fully_checkpointed() 114 ret = time_after(journal->j_trans_id, ci->ci_last_trans); in ocfs2_ci_fully_checkpointed() 126 struct ocfs2_journal *journal = in ocfs2_ci_is_new() local 127 OCFS2_SB(ocfs2_metadata_cache_get_super(ci))->journal; in ocfs2_ci_is_new() 130 ret = !(time_after(journal->j_trans_id, ci->ci_created_trans)); in ocfs2_ci_is_new() 153 ci->ci_created_trans = osb->journal->j_trans_id; in ocfs2_ci_set_new() 187 int ocfs2_journal_init(struct ocfs2_journal *journal, [all …]
|
D | super.c | 302 "Journal", osb->journal->j_state, in ocfs2_osb_dump() 303 osb->journal->j_trans_id, in ocfs2_osb_dump() 304 atomic_read(&osb->journal->j_num_trans)); in ocfs2_osb_dump() 426 if (jbd2_journal_start_commit(OCFS2_SB(sb)->journal->j_journal, in ocfs2_sync_fs() 429 jbd2_log_wait_commit(OCFS2_SB(sb)->journal->j_journal, in ocfs2_sync_fs() 2018 jbd2_journal_check_used_features(osb->journal->j_journal, 0, 0, in ocfs2_journal_addressable() 2039 struct ocfs2_journal *journal; in ocfs2_initialize_super() local 2223 journal = kzalloc(sizeof(struct ocfs2_journal), GFP_KERNEL); in ocfs2_initialize_super() 2224 if (!journal) { in ocfs2_initialize_super() 2229 osb->journal = journal; in ocfs2_initialize_super() [all …]
|
D | inode.c | 143 journal_t *journal = OCFS2_SB(sb)->journal->j_journal; in ocfs2_iget() local 190 if (journal) { in ocfs2_iget() 195 read_lock(&journal->j_state_lock); in ocfs2_iget() 196 if (journal->j_running_transaction) in ocfs2_iget() 197 transaction = journal->j_running_transaction; in ocfs2_iget() 199 transaction = journal->j_committing_transaction; in ocfs2_iget() 203 tid = journal->j_commit_sequence; in ocfs2_iget() 204 read_unlock(&journal->j_state_lock); in ocfs2_iget() 1225 jbd2_journal_release_jbd_inode(OCFS2_SB(inode->i_sb)->journal->j_journal, in ocfs2_clear_inode()
|
D | Makefile | 25 journal.o \
|
/fs/ext4/ |
D | ext4_jbd2.c | 44 journal_t *journal; in ext4_journal_check_start() local 54 journal = EXT4_SB(sb)->s_journal; in ext4_journal_check_start() 60 if (journal && is_journal_aborted(journal)) { in ext4_journal_check_start() 70 journal_t *journal; in __ext4_journal_start_sb() local 78 journal = EXT4_SB(sb)->s_journal; in __ext4_journal_start_sb() 79 if (!journal) in __ext4_journal_start_sb() 81 return jbd2__journal_start(journal, blocks, rsv_blocks, GFP_NOFS, in __ext4_journal_start_sb()
|
D | fsync.c | 99 journal_t *journal = EXT4_SB(inode->i_sb)->s_journal; in ext4_sync_file() local 119 if (!journal) { in ext4_sync_file() 151 if (journal->j_flags & JBD2_BARRIER && in ext4_sync_file() 152 !jbd2_trans_will_send_data_barrier(journal, commit_tid)) in ext4_sync_file() 154 ret = jbd2_complete_transaction(journal, commit_tid); in ext4_sync_file()
|
D | super.c | 391 static void ext4_journal_commit_callback(journal_t *journal, transaction_t *txn) in ext4_journal_commit_callback() argument 393 struct super_block *sb = journal->j_private; in ext4_journal_commit_callback() 395 int error = is_journal_aborted(journal); in ext4_journal_commit_callback() 435 journal_t *journal = EXT4_SB(sb)->s_journal; in ext4_handle_error() local 438 if (journal) in ext4_handle_error() 439 jbd2_journal_abort(journal, -EIO); in ext4_handle_error() 1183 journal_t *journal = EXT4_SB(sb)->s_journal; in bdev_try_to_free_page() local 1188 if (journal) in bdev_try_to_free_page() 1189 return jbd2_journal_try_to_free_buffers(journal, page, in bdev_try_to_free_page() 4585 static void ext4_init_journal_params(struct super_block *sb, journal_t *journal) in ext4_init_journal_params() argument [all …]
|
D | inode.c | 232 journal_t *journal = EXT4_SB(inode->i_sb)->s_journal; in ext4_evict_inode() local 235 jbd2_complete_transaction(journal, commit_tid); in ext4_evict_inode() 3302 journal_t *journal; in ext4_bmap() local 3342 journal = EXT4_JOURNAL(inode); in ext4_bmap() 3343 jbd2_journal_lock_updates(journal); in ext4_bmap() 3344 err = jbd2_journal_flush(journal); in ext4_bmap() 3345 jbd2_journal_unlock_updates(journal); in ext4_bmap() 3398 journal_t *journal = EXT4_JOURNAL(page->mapping->host); in __ext4_journalled_invalidatepage() local 3408 return jbd2_journal_invalidatepage(journal, page, offset, length); in __ext4_journalled_invalidatepage() 3421 journal_t *journal = EXT4_JOURNAL(page->mapping->host); in ext4_releasepage() local [all …]
|
D | ext4_jbd2.h | 359 static inline int ext4_journal_force_commit(journal_t *journal) in ext4_journal_force_commit() argument 361 if (journal) in ext4_journal_force_commit() 362 return jbd2_journal_force_commit(journal); in ext4_journal_force_commit()
|
D | fsmap.c | 269 journal_t *journal = EXT4_SB(sb)->s_journal; in ext4_getfsmap_logdev() local 292 irec.fmr_physical = journal->j_blk_offset; in ext4_getfsmap_logdev() 293 irec.fmr_length = journal->j_maxlen; in ext4_getfsmap_logdev()
|
/fs/f2fs/ |
D | segment.c | 2320 memcpy(&dst->journal, curseg->journal, SUM_JOURNAL_SIZE); in write_current_sum_page() 3376 memcpy(seg_i->journal, kaddr, SUM_JOURNAL_SIZE); in read_compacted_summaries() 3380 memcpy(seg_i->journal, kaddr + SUM_JOURNAL_SIZE, SUM_JOURNAL_SIZE); in read_compacted_summaries() 3480 memcpy(curseg->journal, &sum->journal, SUM_JOURNAL_SIZE); in read_normal_summaries() 3497 struct f2fs_journal *sit_j = CURSEG_I(sbi, CURSEG_COLD_DATA)->journal; in restore_curseg_summaries() 3498 struct f2fs_journal *nat_j = CURSEG_I(sbi, CURSEG_HOT_DATA)->journal; in restore_curseg_summaries() 3549 memcpy(kaddr, seg_i->journal, SUM_JOURNAL_SIZE); in write_compacted_summaries() 3554 memcpy(kaddr + written_size, seg_i->journal, SUM_JOURNAL_SIZE); in write_compacted_summaries() 3618 int f2fs_lookup_journal_in_cursum(struct f2fs_journal *journal, int type, in f2fs_lookup_journal_in_cursum() argument 3624 for (i = 0; i < nats_in_cursum(journal); i++) { in f2fs_lookup_journal_in_cursum() [all …]
|
D | node.c | 522 struct f2fs_journal *journal = curseg->journal; in f2fs_get_node_info() local 548 i = f2fs_lookup_journal_in_cursum(journal, NAT_JOURNAL, nid, 0); in f2fs_get_node_info() 550 ne = nat_in_journal(journal, i); in f2fs_get_node_info() 2194 struct f2fs_journal *journal = curseg->journal; in scan_curseg_cache() local 2198 for (i = 0; i < nats_in_cursum(journal); i++) { in scan_curseg_cache() 2202 addr = le32_to_cpu(nat_in_journal(journal, i).block_addr); in scan_curseg_cache() 2203 nid = le32_to_cpu(nid_in_journal(journal, i)); in scan_curseg_cache() 2641 struct f2fs_journal *journal = curseg->journal; in remove_nats_in_journal() local 2645 for (i = 0; i < nats_in_cursum(journal); i++) { in remove_nats_in_journal() 2648 nid_t nid = le32_to_cpu(nid_in_journal(journal, i)); in remove_nats_in_journal() [all …]
|
/fs/ubifs/ |
D | Makefile | 4 ubifs-y += shrinker.o journal.o file.o dir.o super.o sb.o io.o
|