Lines Matching refs:th
1034 static char prepare_for_delete_or_cut(struct reiserfs_transaction_handle *th, in prepare_for_delete_or_cut() argument
1053 BUG_ON(!th->t_trans_id); in prepare_for_delete_or_cut()
1112 reiserfs_transaction_free_space(th) < JOURNAL_FOR_FREE_BLOCK_AND_UPDATE_SD) in prepare_for_delete_or_cut()
1121 journal_mark_dirty(th, bh); in prepare_for_delete_or_cut()
1122 reiserfs_free_block(th, inode, block, 1); in prepare_for_delete_or_cut()
1190 static void init_tb_struct(struct reiserfs_transaction_handle *th, in init_tb_struct() argument
1196 BUG_ON(!th->t_trans_id); in init_tb_struct()
1199 tb->transaction_handle = th; in init_tb_struct()
1251 int reiserfs_delete_item(struct reiserfs_transaction_handle *th, in reiserfs_delete_item() argument
1268 BUG_ON(!th->t_trans_id); in reiserfs_delete_item()
1270 init_tb_struct(th, &s_del_balance, sb, path, in reiserfs_delete_item()
1280 prepare_for_delete_or_cut(th, inode, path, in reiserfs_delete_item()
1404 void reiserfs_delete_solid_item(struct reiserfs_transaction_handle *th, in reiserfs_delete_solid_item() argument
1407 struct super_block *sb = th->t_super; in reiserfs_delete_solid_item()
1416 BUG_ON(!th->t_trans_id); in reiserfs_delete_solid_item()
1421 retval = search_item(th->t_super, &cpu_key, &path); in reiserfs_delete_solid_item()
1423 reiserfs_error(th->t_super, "vs-5350", in reiserfs_delete_solid_item()
1443 reiserfs_warning(th->t_super, "vs-5355", in reiserfs_delete_solid_item()
1450 init_tb_struct(th, &tb, th->t_super, &path, in reiserfs_delete_solid_item()
1457 PROC_INFO_INC(th->t_super, delete_solid_item_restarted); in reiserfs_delete_solid_item()
1470 reiserfs_debug(th->t_super, REISERFS_DEBUG_CODE, in reiserfs_delete_solid_item()
1484 reiserfs_warning(th->t_super, "vs-5360", in reiserfs_delete_solid_item()
1494 int reiserfs_delete_object(struct reiserfs_transaction_handle *th, in reiserfs_delete_object() argument
1499 BUG_ON(!th->t_trans_id); in reiserfs_delete_object()
1503 reiserfs_do_truncate(th, inode, NULL, 0 /*no timestamp updates */ ); in reiserfs_delete_object()
1508 if (!old_format_only(th->t_super)) { in reiserfs_delete_object()
1512 &REISERFS_SB(th->t_super)->s_rs->s_inode_generation; in reiserfs_delete_object()
1517 reiserfs_delete_solid_item(th, inode, INODE_PKEY(inode)); in reiserfs_delete_object()
1557 static int maybe_indirect_to_direct(struct reiserfs_transaction_handle *th, in maybe_indirect_to_direct() argument
1567 BUG_ON(!th->t_trans_id); in maybe_indirect_to_direct()
1587 return indirect2direct(th, inode, page, path, item_key, in maybe_indirect_to_direct()
1597 static void indirect_to_direct_roll_back(struct reiserfs_transaction_handle *th, in indirect_to_direct_roll_back() argument
1603 BUG_ON(!th->t_trans_id); in indirect_to_direct_roll_back()
1622 reiserfs_delete_item(th, path, &tail_key, inode, in indirect_to_direct_roll_back()
1639 int reiserfs_cut_from_item(struct reiserfs_transaction_handle *th, in reiserfs_cut_from_item() argument
1664 BUG_ON(!th->t_trans_id); in reiserfs_cut_from_item()
1666 init_tb_struct(th, &s_cut_balance, inode->i_sb, path, in reiserfs_cut_from_item()
1682 prepare_for_delete_or_cut(th, inode, path, in reiserfs_cut_from_item()
1694 maybe_indirect_to_direct(th, inode, page, in reiserfs_cut_from_item()
1766 indirect_to_direct_roll_back(th, inode, path); in reiserfs_cut_from_item()
1860 static void truncate_directory(struct reiserfs_transaction_handle *th, in truncate_directory() argument
1863 BUG_ON(!th->t_trans_id); in truncate_directory()
1869 reiserfs_delete_solid_item(th, inode, INODE_PKEY(inode)); in truncate_directory()
1870 reiserfs_update_sd(th, inode); in truncate_directory()
1879 int reiserfs_do_truncate(struct reiserfs_transaction_handle *th, in reiserfs_do_truncate() argument
1900 BUG_ON(!th->t_trans_id); in reiserfs_do_truncate()
1908 truncate_directory(th, inode); in reiserfs_do_truncate()
1973 reiserfs_cut_from_item(th, &s_search_path, &s_item_key, in reiserfs_do_truncate()
2003 if (journal_transaction_should_end(th, 0) || in reiserfs_do_truncate()
2004 reiserfs_transaction_free_space(th) <= JOURNAL_FOR_FREE_BLOCK_AND_UPDATE_SD) { in reiserfs_do_truncate()
2011 reiserfs_update_sd(th, inode); in reiserfs_do_truncate()
2013 err = journal_end(th); in reiserfs_do_truncate()
2016 err = journal_begin(th, inode->i_sb, in reiserfs_do_truncate()
2036 reiserfs_update_sd(th, inode); in reiserfs_do_truncate()
2082 int reiserfs_paste_into_item(struct reiserfs_transaction_handle *th, in reiserfs_paste_into_item() argument
2100 BUG_ON(!th->t_trans_id); in reiserfs_paste_into_item()
2118 init_tb_struct(th, &s_paste_balance, th->t_super, search_path, in reiserfs_paste_into_item()
2134 PROC_INFO_INC(th->t_super, paste_into_item_restarted); in reiserfs_paste_into_item()
2136 search_for_position_by_key(th->t_super, key, in reiserfs_paste_into_item()
2185 int reiserfs_insert_item(struct reiserfs_transaction_handle *th, in reiserfs_insert_item() argument
2195 BUG_ON(!th->t_trans_id); in reiserfs_insert_item()
2226 init_tb_struct(th, &s_ins_balance, th->t_super, path, in reiserfs_insert_item()
2244 PROC_INFO_INC(th->t_super, insert_item_restarted); in reiserfs_insert_item()
2245 retval = search_item(th->t_super, key, path); in reiserfs_insert_item()
2251 reiserfs_warning(th->t_super, "PAP-5760", in reiserfs_insert_item()
2271 reiserfs_debug(th->t_super, REISERFS_DEBUG_CODE, in reiserfs_insert_item()