File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- refs/heads/master: 96a629d2fa5144ccba39cc0e4258b6e0fe2da283
2
+ refs/heads/master: 6657e729de2d4544d4f014091ef05878937895dc
Original file line number Diff line number Diff line change @@ -135,7 +135,9 @@ int rust_kernel::start_task_threads()
135
135
136
136
rust_task *
137
137
rust_kernel::create_task (rust_task *spawner, const char *name) {
138
- return threads[rand (&rctx) % num_threads]->create_task (spawner, name);
138
+ rust_scheduler *thread = threads[rand (&rctx) % num_threads];
139
+ scoped_lock with (thread->lock );
140
+ return thread->create_task (spawner, name);
139
141
}
140
142
141
143
void rust_kernel::wakeup_schedulers () {
Original file line number Diff line number Diff line change @@ -526,7 +526,6 @@ extern "C" CDECL rust_task *
526
526
upcall_new_task (rust_task *spawner, rust_vec *name) {
527
527
// name is a rust string structure.
528
528
LOG_UPCALL_ENTRY (spawner);
529
- scoped_lock with (spawner->sched ->lock );
530
529
rust_task *task =
531
530
spawner->kernel ->create_task (spawner, (const char *)name->data );
532
531
task->ref ();
You can’t perform that action at this time.
0 commit comments