mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-06 11:20:32 +00:00
hv: sched: add pcpu_id in sched_control
To get pcpu_id from sched_control quickly and easier. Tracked-On: #3813 Signed-off-by: Jason Chen CJ <jason.cj.chen@intel.com> Signed-off-by: Yu Wang <yu1.wang@intel.com> Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
This commit is contained in:
@@ -54,6 +54,7 @@ void init_sched(uint16_t pcpu_id)
|
||||
spinlock_init(&ctl->scheduler_lock);
|
||||
ctl->flags = 0UL;
|
||||
ctl->curr_obj = NULL;
|
||||
ctl->pcpu_id = pcpu_id;
|
||||
}
|
||||
|
||||
void get_schedule_lock(uint16_t pcpu_id)
|
||||
|
@@ -41,6 +41,7 @@ struct thread_object {
|
||||
};
|
||||
|
||||
struct sched_control {
|
||||
uint16_t pcpu_id;
|
||||
uint64_t flags;
|
||||
struct thread_object *curr_obj;
|
||||
spinlock_t scheduler_lock; /* to protect sched_control and thread_object */
|
||||
|
Reference in New Issue
Block a user