Prevent one CPU from getting chosen by concurrent forks
One CPU could be chosen by concurrent forks because CPU selection and runq addition are not done atomicly. So this fix makes the two steps atomic. Change-Id: Ib6b75ad655789385d13207e0a47fa4717dec854a
This commit is contained in:
@@ -74,6 +74,7 @@ struct cpu_local_var {
|
||||
struct thread *current;
|
||||
struct list_head runq;
|
||||
size_t runq_len;
|
||||
size_t runq_reserved; /* Number of threads which are about to be added to runq */
|
||||
|
||||
struct ihk_ikc_channel_desc *ikc2linux;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user