Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 350299
b: refs/heads/master
c: 54d5b7d
h: refs/heads/master
i:
  350297: fce44b8
  350295: 4f9c2cf
v: v3
  • Loading branch information
Lai Jiangshan authored and Tejun Heo committed Feb 7, 2013
1 parent 5a22ac9 commit 60c19ee
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e19e397a85f33100bfa4210e256bec82fe22e167
refs/heads/master: 54d5b7d079dffa74597715a892473b474babd5b5
8 changes: 6 additions & 2 deletions trunk/kernel/workqueue.c
Original file line number Diff line number Diff line change
Expand Up @@ -611,9 +611,13 @@ static struct worker_pool *get_work_pool(struct work_struct *work)
*/
static int get_work_pool_id(struct work_struct *work)
{
struct worker_pool *pool = get_work_pool(work);
unsigned long data = atomic_long_read(&work->data);

if (data & WORK_STRUCT_CWQ)
return ((struct cpu_workqueue_struct *)
(data & WORK_STRUCT_WQ_DATA_MASK))->pool->id;

return pool ? pool->id : WORK_OFFQ_POOL_NONE;
return data >> WORK_OFFQ_POOL_SHIFT;
}

static void mark_work_canceling(struct work_struct *work)
Expand Down

0 comments on commit 60c19ee

Please sign in to comment.