Lines Matching full:group
21 * nilfs_palloc_groups_per_desc_block - get the number of groups that a group
63 * Number of blocks in a group including entry blocks in nilfs_palloc_init_blockgroup()
77 * nilfs_palloc_group - get group number and offset from an entry number
80 * @offset: pointer to store offset number in the group
85 __u64 group = nr; in nilfs_palloc_group() local
87 *offset = do_div(group, nilfs_palloc_entries_per_group(inode)); in nilfs_palloc_group()
88 return group; in nilfs_palloc_group()
92 * nilfs_palloc_desc_blkoff - get block offset of a group descriptor block
94 * @group: group number
97 * block which contains a descriptor of the specified group.
100 nilfs_palloc_desc_blkoff(const struct inode *inode, unsigned long group) in nilfs_palloc_desc_blkoff() argument
103 group / nilfs_palloc_groups_per_desc_block(inode); in nilfs_palloc_desc_blkoff()
110 * @group: group number
113 * block used to allocate/deallocate entries in the specified group.
116 nilfs_palloc_bitmap_blkoff(const struct inode *inode, unsigned long group) in nilfs_palloc_bitmap_blkoff() argument
119 group % nilfs_palloc_groups_per_desc_block(inode); in nilfs_palloc_bitmap_blkoff()
120 return nilfs_palloc_desc_blkoff(inode, group) + 1 + in nilfs_palloc_bitmap_blkoff()
125 * nilfs_palloc_group_desc_nfrees - get the number of free entries in a group
126 * @desc: pointer to descriptor structure for the group
143 * @desc: pointer to descriptor structure for the group
168 unsigned long group, group_offset; in nilfs_palloc_entry_blkoff() local
170 group = nilfs_palloc_group(inode, nr, &group_offset); in nilfs_palloc_entry_blkoff()
172 return nilfs_palloc_bitmap_blkoff(inode, group) + 1 + in nilfs_palloc_entry_blkoff()
177 * nilfs_palloc_desc_block_init - initialize buffer of a group descriptor block
254 * nilfs_palloc_get_desc_block - get buffer head of a group descriptor block
256 * @group: group number
261 unsigned long group, in nilfs_palloc_get_desc_block() argument
267 nilfs_palloc_desc_blkoff(inode, group), in nilfs_palloc_get_desc_block()
275 * @group: group number
280 unsigned long group, in nilfs_palloc_get_bitmap_block() argument
286 nilfs_palloc_bitmap_blkoff(inode, group), in nilfs_palloc_get_bitmap_block()
294 * @group: group number
297 unsigned long group) in nilfs_palloc_delete_bitmap_block() argument
303 group), in nilfs_palloc_delete_bitmap_block()
340 * nilfs_palloc_block_get_group_desc - get kernel address of a group descriptor
342 * @group: group number
343 * @bh: buffer head of the buffer storing the group descriptor block
348 unsigned long group, in nilfs_palloc_block_get_group_desc() argument
352 group % nilfs_palloc_groups_per_desc_block(inode); in nilfs_palloc_block_get_group_desc()
375 * nilfs_palloc_find_available_slot - find available slot in a group
376 * @bitmap: bitmap of the group
377 * @target: offset number of an entry in the group (start point)
418 * in a group descriptor block
420 * @curr: current group number
510 unsigned long group, maxgroup, ngroups; in nilfs_palloc_prepare_alloc_entry() local
519 group = nilfs_palloc_group(inode, req->pr_entry_nr, &group_offset); in nilfs_palloc_prepare_alloc_entry()
523 if (group >= ngroups && wrap) { in nilfs_palloc_prepare_alloc_entry()
525 group = 0; in nilfs_palloc_prepare_alloc_entry()
529 ret = nilfs_palloc_get_desc_block(inode, group, 1, &desc_bh); in nilfs_palloc_prepare_alloc_entry()
534 inode, group, desc_bh, desc_kaddr); in nilfs_palloc_prepare_alloc_entry()
535 n = nilfs_palloc_rest_groups_in_desc_block(inode, group, in nilfs_palloc_prepare_alloc_entry()
537 for (j = 0; j < n; j++, desc++, group++, group_offset = 0) { in nilfs_palloc_prepare_alloc_entry()
538 lock = nilfs_mdt_bgl_lock(inode, group); in nilfs_palloc_prepare_alloc_entry()
543 ret = nilfs_palloc_get_bitmap_block(inode, group, 1, in nilfs_palloc_prepare_alloc_entry()
552 inode, group, desc_bh, desc_kaddr); in nilfs_palloc_prepare_alloc_entry()
582 req->pr_entry_nr = entries_per_group * group + pos; in nilfs_palloc_prepare_alloc_entry()
615 unsigned long group, group_offset; in nilfs_palloc_commit_free_entry() local
620 group = nilfs_palloc_group(inode, req->pr_entry_nr, &group_offset); in nilfs_palloc_commit_free_entry()
622 desc = nilfs_palloc_block_get_group_desc(inode, group, in nilfs_palloc_commit_free_entry()
626 lock = nilfs_mdt_bgl_lock(inode, group); in nilfs_palloc_commit_free_entry()
658 unsigned long group, group_offset; in nilfs_palloc_abort_alloc_entry() local
661 group = nilfs_palloc_group(inode, req->pr_entry_nr, &group_offset); in nilfs_palloc_abort_alloc_entry()
663 desc = nilfs_palloc_block_get_group_desc(inode, group, in nilfs_palloc_abort_alloc_entry()
667 lock = nilfs_mdt_bgl_lock(inode, group); in nilfs_palloc_abort_alloc_entry()
697 unsigned long group, group_offset; in nilfs_palloc_prepare_free_entry() local
700 group = nilfs_palloc_group(inode, req->pr_entry_nr, &group_offset); in nilfs_palloc_prepare_free_entry()
701 ret = nilfs_palloc_get_desc_block(inode, group, 1, &desc_bh); in nilfs_palloc_prepare_free_entry()
704 ret = nilfs_palloc_get_bitmap_block(inode, group, 1, &bitmap_bh); in nilfs_palloc_prepare_free_entry()
743 unsigned long group, group_offset; in nilfs_palloc_freev() local
756 group = nilfs_palloc_group(inode, entry_nrs[i], &group_offset); in nilfs_palloc_freev()
757 ret = nilfs_palloc_get_desc_block(inode, group, 0, &desc_bh); in nilfs_palloc_freev()
760 ret = nilfs_palloc_get_bitmap_block(inode, group, 0, in nilfs_palloc_freev()
767 /* Get the first entry number of the group */ in nilfs_palloc_freev()
768 group_min_nr = (__u64)group * epg; in nilfs_palloc_freev()
772 lock = nilfs_mdt_bgl_lock(inode, group); in nilfs_palloc_freev()
832 inode, group, desc_bh, desc_kaddr); in nilfs_palloc_freev()
840 ret = nilfs_palloc_delete_bitmap_block(inode, group); in nilfs_palloc_freev()
843 "error %d deleting bitmap block of group=%lu, ino=%lu", in nilfs_palloc_freev()
844 ret, group, inode->i_ino); in nilfs_palloc_freev()