In task_per_thread[] we now have current_queue which is a pointer to
the current tasklet_list entry being evaluated. This will be used to
know the class under which the current task/tasklet is currently
running.
int task_list_size; /* Number of tasks among the tasklets */
int rqueue_size; /* Number of elements in the per-thread run queue */
struct task *current; /* current task (not tasklet) */
+ struct list *current_queue; /* points to current tasklet list being run */
__attribute__((aligned(64))) char end[0];
};
void *ctx;
int done = 0;
+ sched->current_queue = list;
while (done < max && !LIST_ISEMPTY(list)) {
t = (struct task *)LIST_ELEM(list->n, struct tasklet *, list);
state = (t->state & (TASK_SHARED_WQ|TASK_SELF_WAKING));
}
done++;
}
+
+ sched->current_queue = NULL;
return done;
}