Changeset 72c8f77 in mainline for uspace/srv/sysman/job.h
- Timestamp:
- 2019-08-06T18:30:29Z (5 years ago)
- Children:
- 63a3276
- Parents:
- c2d50c8
- git-author:
- Michal Koutný <xm.koutny+hos@…> (2015-05-26 16:15:58)
- git-committer:
- Matthieu Riolo <matthieu.riolo@…> (2019-08-06 18:30:29)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/sysman/job.h
rc2d50c8 r72c8f77 37 37 #include "unit.h" 38 38 39 // TODO simplify queue states40 39 /** Run state of job */ 41 40 typedef enum { 42 JOB_ UNQUEUED, /**< Job not in queue yet*/43 JOB_ QUEUED,44 JOB_ DEQUEUED, /**< Job not in queue already*/41 JOB_EMBRYO, /**< Job after creation */ 42 JOB_CLOSURED, /**< Intermmediate when closure is evaluated */ 43 JOB_PENDING, /**< Job is queued */ 45 44 JOB_RUNNING, 46 45 JOB_FINISHED … … 54 53 } job_retval_t; 55 54 55 struct job; 56 typedef struct job job_t; 57 56 58 struct job { 57 59 link_t job_queue; … … 63 65 /** Jobs that this job is preventing from running */ 64 66 dyn_array_t blocked_jobs; 67 /** No. of jobs that the job is actually blocking (may differ from size 68 * of blocked_jobs for not fully merged job */ 69 size_t blocked_jobs_count; 65 70 /** No. of jobs that must finish before this job */ 66 71 size_t blocking_jobs; 67 72 /** Any of blocking jobs failed */ 68 73 bool blocking_job_failed; 74 /** Job that this job was merged to */ 75 job_t *merged_into; 69 76 70 77 /** See job_state_t */ … … 74 81 }; 75 82 76 typedef struct job job_t;77 typedef job_t *job_ptr_t;78 79 83 extern void job_queue_init(void); 80 extern int job_queue_add_ jobs(dyn_array_t *);84 extern int job_queue_add_closure(dyn_array_t *); 81 85 extern void job_queue_process(void); 82 86
Note:
See TracChangeset
for help on using the changeset viewer.