• Home
  • Raw
  • Download

Lines Matching refs:w

83 	struct bt_work *w;  in __insert_pending()  local
87 w = container_of(*new, struct bt_work, node); in __insert_pending()
90 cmp = cmp_oblock(w->work.oblock, nw->work.oblock); in __insert_pending()
112 struct bt_work *w; in __find_pending() local
116 w = container_of(*new, struct bt_work, node); in __find_pending()
118 cmp = cmp_oblock(w->work.oblock, oblock); in __find_pending()
129 return *new ? w : NULL; in __find_pending()
133 static void update_stats(struct background_tracker *b, struct policy_work *w, int delta) in update_stats() argument
135 switch (w->op) { in update_stats()
181 struct bt_work *w; in btracker_queue() local
186 w = alloc_work(b); in btracker_queue()
187 if (!w) in btracker_queue()
190 memcpy(&w->work, work, sizeof(*work)); in btracker_queue()
192 if (!__insert_pending(b, w)) { in btracker_queue()
197 kmem_cache_free(b->work_cache, w); in btracker_queue()
202 *pwork = &w->work; in btracker_queue()
203 list_add(&w->list, &b->issued); in btracker_queue()
205 list_add(&w->list, &b->queued); in btracker_queue()
206 update_stats(b, &w->work, 1); in btracker_queue()
217 struct bt_work *w; in btracker_issue() local
222 w = list_first_entry(&b->queued, struct bt_work, list); in btracker_issue()
223 list_move(&w->list, &b->issued); in btracker_issue()
224 *work = &w->work; in btracker_issue()
233 struct bt_work *w = container_of(op, struct bt_work, work); in btracker_complete() local
235 update_stats(b, &w->work, -1); in btracker_complete()
236 rb_erase(&w->node, &b->pending); in btracker_complete()
237 list_del(&w->list); in btracker_complete()
238 kmem_cache_free(b->work_cache, w); in btracker_complete()