Lines Matching refs:threads
484 struct slpc_thread *threads; in live_slpc_tile_interaction() local
487 threads = kcalloc(I915_MAX_GT, sizeof(*threads), GFP_KERNEL); in live_slpc_tile_interaction()
488 if (!threads) in live_slpc_tile_interaction()
492 threads[i].worker = kthread_create_worker(0, "igt/slpc_parallel:%d", gt->info.id); in live_slpc_tile_interaction()
494 if (IS_ERR(threads[i].worker)) { in live_slpc_tile_interaction()
495 ret = PTR_ERR(threads[i].worker); in live_slpc_tile_interaction()
499 threads[i].gt = gt; in live_slpc_tile_interaction()
500 kthread_init_work(&threads[i].work, slpc_spinner_thread); in live_slpc_tile_interaction()
501 kthread_queue_work(threads[i].worker, &threads[i].work); in live_slpc_tile_interaction()
507 if (IS_ERR_OR_NULL(threads[i].worker)) in live_slpc_tile_interaction()
510 kthread_flush_work(&threads[i].work); in live_slpc_tile_interaction()
511 status = READ_ONCE(threads[i].result); in live_slpc_tile_interaction()
516 kthread_destroy_worker(threads[i].worker); in live_slpc_tile_interaction()
519 kfree(threads); in live_slpc_tile_interaction()