Lines Matching defs:nr_units
2238 * @nr_units: the number of units
2241 * @nr_units units. The returned ai's groups[0].cpu_map points to the
2242 * cpu_map array which is long enough for @nr_units and filled with
2251 int nr_units)
2260 ai_size = base_size + nr_units * sizeof(ai->groups[0].cpu_map[0]);
2270 for (unit = 0; unit < nr_units; unit++)
2327 BUG_ON(gi->nr_units % upa);
2328 for (alloc_end += gi->nr_units / upa;
2482 group_sizes[group] = gi->nr_units * ai->unit_size;
2484 for (i = 0; i < gi->nr_units; i++) {
2673 int nr_groups = 1, nr_units = 0;
2760 nr_units += roundup(group_cnt[group], upa);
2762 ai = pcpu_alloc_alloc_info(nr_groups, nr_units);
2791 gi->cpu_map[gi->nr_units++] = cpu;
2792 gi->nr_units = roundup(gi->nr_units, upa);
2793 unit += gi->nr_units;
2795 BUG_ON(unit != nr_units);
2868 for (i = 0; i < gi->nr_units && cpu == NR_CPUS; i++)
2873 ptr = alloc_fn(cpu, gi->nr_units * ai->unit_size, atom_size);
2887 max_distance += ai->unit_size * ai->groups[highest_group].nr_units;
2909 for (i = 0; i < gi->nr_units; i++, ptr += ai->unit_size) {
2937 ai->groups[group].nr_units * ai->unit_size);
2986 if (WARN_ON(ai->groups[0].nr_units != nr_g0_units)) {
3146 ai->groups[0].nr_units = 1;