Lines Matching refs:th

134 static int scan_bitmap_block (struct reiserfs_transaction_handle *th,  in scan_bitmap_block()  argument
137 struct super_block *s = th->t_super; in scan_bitmap_block()
227 journal_mark_dirty (th, s, bi->bh); in scan_bitmap_block()
232 journal_mark_dirty (th, s, SB_BUFFER_WITH_SB(s)); in scan_bitmap_block()
243 static int scan_bitmap (struct reiserfs_transaction_handle *th, in scan_bitmap() argument
248 struct super_block * s = th->t_super; in scan_bitmap()
268 nr_allocated = scan_bitmap_block(th, bm, &off, off_max, min, max, unfm); in scan_bitmap()
276 nr_allocated = scan_bitmap_block(th, bm, &off, off_max, min, max, unfm); in scan_bitmap()
281 nr_allocated = scan_bitmap_block(th, bm, &off, end_off + 1, min, max, unfm); in scan_bitmap()
289 static void _reiserfs_free_block (struct reiserfs_transaction_handle *th, in _reiserfs_free_block() argument
292 struct super_block * s = th->t_super; in _reiserfs_free_block()
325 journal_mark_dirty (th, s, apbi[nr].bh); in _reiserfs_free_block()
331 journal_mark_dirty (th, s, sbh); in _reiserfs_free_block()
334 void reiserfs_free_block (struct reiserfs_transaction_handle *th, in reiserfs_free_block() argument
336 struct super_block * s = th->t_super; in reiserfs_free_block()
341 journal_mark_freed(th, s, block) ; in reiserfs_free_block()
342 _reiserfs_free_block(th, block) ; in reiserfs_free_block()
346 void reiserfs_free_prealloc_block (struct reiserfs_transaction_handle *th, in reiserfs_free_prealloc_block() argument
348 RFALSE(!th->t_super, "vs-4060: trying to free block on nonexistent device"); in reiserfs_free_prealloc_block()
349 RFALSE(is_reusable (th->t_super, block, 1) == 0, "vs-4070: can not free such block"); in reiserfs_free_prealloc_block()
350 _reiserfs_free_block(th, block) ; in reiserfs_free_prealloc_block()
353 static void __discard_prealloc (struct reiserfs_transaction_handle * th, in __discard_prealloc() argument
359 …reiserfs_warning(th->t_super, "zam-4001:%s: inode has negative prealloc blocks count.\n", __FUNCTI… in __discard_prealloc()
362 reiserfs_free_prealloc_block(th,inode->u.reiserfs_i.i_prealloc_block); in __discard_prealloc()
371 void reiserfs_discard_prealloc (struct reiserfs_transaction_handle *th, in reiserfs_discard_prealloc() argument
375 __discard_prealloc(th, inode); in reiserfs_discard_prealloc()
379 void reiserfs_discard_all_prealloc (struct reiserfs_transaction_handle *th) in reiserfs_discard_all_prealloc() argument
381 struct list_head * plist = &SB_JOURNAL(th->t_super)->j_prealloc_list; in reiserfs_discard_all_prealloc()
388 …reiserfs_warning(th->t_super, "zam-4001:%s: inode is in prealloc list but has no preallocated bloc… in reiserfs_discard_all_prealloc()
391 __discard_prealloc(th, inode); in reiserfs_discard_all_prealloc()
492 if ( TEST_OPTION(displace_based_on_dirid, hint->th->t_super)) in new_hashed_relocation()
549 … b_blocknr_t border = SB_BLOCK_COUNT(hint->th->t_super) / s->u.reiserfs_sb.s_alloc_options.border; in set_border_in_hint()
559 if ( TEST_OPTION(displace_based_on_dirid, hint->th->t_super)) in displace_large_file()
571 else if ( TEST_OPTION(displace_based_on_dirid, hint->th->t_super)) in hash_formatted_node()
581 return hint->block == hint->th->t_super->u.reiserfs_sb.s_alloc_options.large_file_size; in this_blocknr_allocation_would_make_it_a_large_file()
589 hint->th->displace_new_blocks = 0; in displace_new_packing_locality()
640 struct super_block *s = hint->th->t_super; in determine_search_start()
653 && hint->th->displace_new_blocks) { in determine_search_start()
725 …&& hint->inode->i_size >= hint->th->t_super->u.reiserfs_sb.s_alloc_options.preallocmin * hint->ino… in determine_prealloc_size()
726 hint->prealloc_size = hint->th->t_super->u.reiserfs_sb.s_alloc_options.preallocsize - 1; in determine_prealloc_size()
742 nr_allocated = scan_bitmap (hint->th, &start, finish, 1, in allocate_without_wrapping_disk()
759 &SB_JOURNAL(hint->th->t_super)->j_prealloc_list); in allocate_without_wrapping_disk()
772 struct super_block *s = hint->th->t_super; in blocknrs_and_prealloc_arrays_from_search_start()
787 reiserfs_free_block(hint->th, new_blocknrs[nr_allocated]); in blocknrs_and_prealloc_arrays_from_search_start()
834 if ( SB_FREE_BLOCKS(hint->th->t_super) - hint->th->t_super->u.reiserfs_sb.reserved_blocks < in reiserfs_allocate_blocknrs()
865 reiserfs_free_block(hint->th, *(--new_blocknrs)); in reiserfs_allocate_blocknrs()