Lines Matching refs:group

42  * blocks groups.  Each group contains 1 bitmap block for blocks, 1 bitmap
45 * The file system contains group descriptors which are located after the
373 * for a particular block group or flex_bg. If flex_size is 1, then g
374 * is a block group number; otherwise it is flex_bg number.
409 * Otherwise we simply return a random group.
413 * It's OK to put directory into a group unless
417 * Parent's group is preferred, if it doesn't satisfy these
419 * of the groups look good we just look for a group with more
420 * free inodes than average (starting at parent's group).
424 ext4_group_t *group, umode_t mode,
488 *group = grp;
496 * start at 2nd block group of the flexgroup. See
505 *group = grp+i;
519 * Start looking in the flex group where we last allocated an
551 *group = grp;
570 ext4_group_t *group, umode_t mode)
578 * Try to place the inode is the same flex group as its
580 * find another flex group, and store that information in the
582 * group for future allocations.
595 *group = i;
606 * to find a new flex group; we pass in the mode to
609 *group = parent_group + flex_size;
610 if (*group > ngroups)
611 *group = 0;
612 return find_group_orlov(sb, parent, group, mode, NULL);
618 *group = parent_group;
619 desc = ext4_get_group_desc(sb, *group, NULL);
633 *group = (*group + parent->i_ino) % ngroups;
636 * Use a quadratic hash to find a group with a free inode and some free
640 *group += i;
641 if (*group >= ngroups)
642 *group -= ngroups;
643 desc = ext4_get_group_desc(sb, *group, NULL);
650 * That failed: try linear search for a free inode, even if that group
653 *group = parent_group;
655 if (++*group >= ngroups)
656 *group = 0;
657 desc = ext4_get_group_desc(sb, *group, NULL);
674 static int recently_deleted(struct super_block *sb, ext4_group_t group, int ino)
684 gdp = ext4_get_group_desc(sb, group, NULL);
717 static int find_inode_bit(struct super_block *sb, ext4_group_t group,
730 if (check_recently_deleted && recently_deleted(sb, group, *ino)) {
756 ext4_group_t group;
763 group = (ino - 1) / EXT4_INODES_PER_GROUP(sb);
765 inode_bitmap_bh = ext4_read_inode_bitmap(sb, group);
774 gdp = ext4_get_group_desc(sb, group, &group_desc_bh);
799 block_bitmap_bh = ext4_read_block_bitmap(sb, group);
810 ext4_lock_group(sb, group);
815 ext4_free_clusters_after_init(sb, group, gdp));
817 ext4_group_desc_csum_set(sb, group, gdp);
819 ext4_unlock_group(sb, group);
832 ext4_lock_group(sb, group); /* while we modify the bg desc */
842 * relative inode number in this group. if it is greater
849 ext4_lock_group(sb, group);
856 ext4_group_desc_csum_set(sb, group, gdp);
859 ext4_unlock_group(sb, group);
915 * a directory, then a forward search is made for a block group with both
917 * the groups with above-average free space, that group with the fewest
921 * group to find a free inode.
933 ext4_group_t ngroups, group = 0;
1008 group = (goal - 1) / EXT4_INODES_PER_GROUP(sb);
1015 ret2 = find_group_orlov(sb, dir, &group, mode, qstr);
1017 ret2 = find_group_other(sb, dir, &group, mode);
1020 EXT4_I(dir)->i_last_alloc_group = group;
1027 * unless we get unlucky and it turns out the group we selected
1033 gdp = ext4_get_group_desc(sb, group, &group_desc_bh);
1044 grp = ext4_get_group_info(sb, group);
1054 inode_bitmap_bh = ext4_read_inode_bitmap(sb, group);
1064 ret2 = find_inode_bit(sb, group, inode_bitmap_bh, &ino);
1068 if (group == 0 && (ino + 1) < EXT4_FIRST_INO(sb)) {
1071 ext4_mark_group_bitmap_corrupted(sb, group,
1094 ext4_lock_group(sb, group);
1100 ret2 = find_inode_bit(sb, group, inode_bitmap_bh, &ino);
1108 ext4_unlock_group(sb, group);
1116 if (++group == ngroups)
1117 group = 0;
1143 block_bitmap_bh = ext4_read_block_bitmap(sb, group);
1161 ext4_lock_group(sb, group);
1166 ext4_free_clusters_after_init(sb, group, gdp));
1168 ext4_group_desc_csum_set(sb, group, gdp);
1170 ext4_unlock_group(sb, group);
1185 grp = ext4_get_group_info(sb, group);
1195 ext4_lock_group(sb, group); /* while we modify the bg desc */
1204 * relative inode number in this group. if it is greater
1213 ext4_lock_group(sb, group);
1220 ext4_group_t f = ext4_flex_group(sbi, group);
1229 ext4_group_desc_csum_set(sb, group, gdp);
1231 ext4_unlock_group(sb, group);
1245 flex_group = ext4_flex_group(sbi, group);
1250 inode->i_ino = ino + group * EXT4_INODES_PER_GROUP(sb);
1266 ei->i_block_group = group;
1280 ext4_mark_group_bitmap_corrupted(sb, group,
1469 printk(KERN_DEBUG "group %lu: stored = %d, counted = %lu\n",
1511 * inode allocation from the current group, so we take alloc_sem lock, to
1514 int ext4_init_inode_table(struct super_block *sb, ext4_group_t group,
1517 struct ext4_group_info *grp = ext4_get_group_info(sb, group);
1526 gdp = ext4_get_group_desc(sb, group, &group_desc_bh);
1556 ext4_error(sb, "Something is wrong with group %u: "
1559 group, used_blks,
1565 used_inos += group * EXT4_INODES_PER_GROUP(sb);
1572 ext4_error(sb, "Something is wrong with group %u: "
1575 group, ext4_itable_unused_count(sb, gdp),
1599 ext4_debug("going to zero out inode table in group %d\n",
1600 group);
1608 ext4_lock_group(sb, group);
1610 ext4_group_desc_csum_set(sb, group, gdp);
1611 ext4_unlock_group(sb, group);