Lines Matching full:jobs
80 * We maintain four lists of jobs:
82 * i) jobs waiting for pages
83 * ii) jobs that have pages, and are waiting for the io to be issued.
84 * iii) jobs that don't need to do any IO and just run a callback
85 * iv) jobs that have completed.
417 static struct kcopyd_job *pop_io_job(struct list_head *jobs, in pop_io_job() argument
423 * For I/O jobs, pop any read, any write without sequential write in pop_io_job()
426 list_for_each_entry(job, jobs, list) { in pop_io_job()
443 static struct kcopyd_job *pop(struct list_head *jobs, in pop() argument
450 if (!list_empty(jobs)) { in pop()
451 if (jobs == &kc->io_jobs) in pop()
452 job = pop_io_job(jobs, kc); in pop()
454 job = list_entry(jobs->next, struct kcopyd_job, list); in pop()
463 static void push(struct list_head *jobs, struct kcopyd_job *job) in push() argument
469 list_add_tail(&job->list, jobs); in push()
474 static void push_head(struct list_head *jobs, struct kcopyd_job *job) in push_head() argument
479 list_add(&job->list, jobs); in push_head()
503 * If this is the master job, the sub jobs have already in run_complete_job()
609 * of successful jobs.
611 static int process_jobs(struct list_head *jobs, struct dm_kcopyd_client *kc, in process_jobs() argument
617 while ((job = pop(jobs, kc))) { in process_jobs()
637 push_head(jobs, job); in process_jobs()
658 * complete jobs can free some pages for pages jobs. in do_work()
659 * Pages jobs when successful will jump onto the io jobs in do_work()
660 * list. io jobs call wake when they complete and it all in do_work()
677 * jobs.
763 * Create some sub jobs to share the work between them.
786 * Allocate an array of jobs consisting of one master job in dm_kcopyd_copy()
787 * followed by SPLIT_COUNT sub jobs. in dm_kcopyd_copy()
978 /* Wait for completion of all jobs submitted by this client. */ in dm_kcopyd_client_destroy()