Lines Matching refs:nthreads
1388 long nthreads = (long)prev; in nthreads_gen_params() local
1390 if (nthreads < 0 || nthreads >= 32) in nthreads_gen_params()
1391 nthreads = 0; /* stop */ in nthreads_gen_params()
1392 else if (!nthreads) in nthreads_gen_params()
1393 nthreads = 2; /* initial value */ in nthreads_gen_params()
1394 else if (nthreads < 5) in nthreads_gen_params()
1395 nthreads++; in nthreads_gen_params()
1396 else if (nthreads == 5) in nthreads_gen_params()
1397 nthreads = 8; in nthreads_gen_params()
1399 nthreads *= 2; in nthreads_gen_params()
1414 nthreads = 0; in nthreads_gen_params()
1415 } else if (nthreads >= num_online_cpus() - min_unused_cpus) { in nthreads_gen_params()
1417 nthreads = -(num_online_cpus() - min_unused_cpus); in nthreads_gen_params()
1419 -nthreads, num_online_cpus()); in nthreads_gen_params()
1423 snprintf(desc, KUNIT_PARAM_DESC_SIZE, "threads=%ld", abs(nthreads)); in nthreads_gen_params()
1424 return (void *)nthreads; in nthreads_gen_params()
1514 int nthreads; in test_init() local
1537 nthreads = abs((long)test->param_value); in test_init()
1538 if (WARN_ON(!nthreads)) in test_init()
1541 threads = kcalloc(nthreads + 1, sizeof(struct task_struct *), GFP_KERNEL); in test_init()
1545 threads[nthreads] = NULL; in test_init()
1546 for (i = 0; i < nthreads; ++i) { in test_init()