Lines Matching defs:atom

520 				      struct sched_atom *atom)
524 switch (atom->type) {
526 burn_nsecs(sched, atom->duration);
529 if (atom->wait_sem)
530 ret = sem_wait(atom->wait_sem);
534 if (atom->wait_sem)
535 ret = sem_post(atom->wait_sem);
1043 struct work_atom *atom = zalloc(sizeof(*atom));
1044 if (!atom) {
1049 atom->sched_out_time = timestamp;
1052 atom->state = THREAD_WAIT_CPU;
1053 atom->wake_up_time = atom->sched_out_time;
1056 list_add_tail(&atom->list, &atoms->work_list);
1064 struct work_atom *atom;
1068 atom = list_entry(atoms->work_list.prev, struct work_atom, list);
1070 atom->runtime += delta;
1077 struct work_atom *atom;
1083 atom = list_entry(atoms->work_list.prev, struct work_atom, list);
1085 if (atom->state != THREAD_WAIT_CPU)
1088 if (timestamp < atom->wake_up_time) {
1089 atom->state = THREAD_IGNORE;
1093 atom->state = THREAD_SCHED_IN;
1094 atom->sched_in_time = timestamp;
1096 delta = atom->sched_in_time - atom->wake_up_time;
1100 atoms->max_lat_start = atom->wake_up_time;
1163 * add in an initial atom in runnable state:
1218 struct work_atom *atom;
1241 atom = list_entry(atoms->work_list.prev, struct work_atom, list);
1254 if (sched->profile_cpu == -1 && atom->state != THREAD_SLEEPING)
1258 if (atom->sched_out_time > timestamp) {
1263 atom->state = THREAD_WAIT_CPU;
1264 atom->wake_up_time = timestamp;
1280 struct work_atom *atom;
1309 atom = list_entry(atoms->work_list.prev, struct work_atom, list);
1310 atom->sched_in_time = atom->sched_out_time = atom->wake_up_time = timestamp;
1314 if (atom->sched_out_time > timestamp)