Lines Matching refs:nthreads
1375 long nthreads = (long)prev; in nthreads_gen_params() local
1377 if (nthreads < 0 || nthreads >= 32) in nthreads_gen_params()
1378 nthreads = 0; /* stop */ in nthreads_gen_params()
1379 else if (!nthreads) in nthreads_gen_params()
1380 nthreads = 2; /* initial value */ in nthreads_gen_params()
1381 else if (nthreads < 5) in nthreads_gen_params()
1382 nthreads++; in nthreads_gen_params()
1383 else if (nthreads == 5) in nthreads_gen_params()
1384 nthreads = 8; in nthreads_gen_params()
1386 nthreads *= 2; in nthreads_gen_params()
1401 nthreads = 0; in nthreads_gen_params()
1402 } else if (nthreads >= num_online_cpus() - min_unused_cpus) { in nthreads_gen_params()
1404 nthreads = -(num_online_cpus() - min_unused_cpus); in nthreads_gen_params()
1406 -nthreads, num_online_cpus()); in nthreads_gen_params()
1410 snprintf(desc, KUNIT_PARAM_DESC_SIZE, "threads=%ld", abs(nthreads)); in nthreads_gen_params()
1411 return (void *)nthreads; in nthreads_gen_params()
1500 int nthreads; in test_init() local
1523 nthreads = abs((long)test->param_value); in test_init()
1524 if (WARN_ON(!nthreads)) in test_init()
1527 threads = kcalloc(nthreads + 1, sizeof(struct task_struct *), GFP_KERNEL); in test_init()
1531 threads[nthreads] = NULL; in test_init()
1532 for (i = 0; i < nthreads; ++i) { in test_init()