Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 365519
b: refs/heads/master
c: 7d19c5c
h: refs/heads/master
i:
  365517: 7dcb31b
  365515: 837aeea
  365511: f519f4b
  365503: 6d2c682
v: v3
  • Loading branch information
Tejun Heo committed Mar 14, 2013
1 parent 8af47e9 commit 0bc4787
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 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: cd549687a7ee5e619a26f55af4059c4ae585811c
refs/heads/master: 7d19c5ce6682fd0390049b5340d4b6bb6065d677
38 changes: 19 additions & 19 deletions trunk/kernel/workqueue.c
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,21 @@ struct workqueue_struct {

static struct kmem_cache *pwq_cache;

/* Serializes the accesses to the list of workqueues. */
static DEFINE_SPINLOCK(workqueue_lock);
static LIST_HEAD(workqueues);
static bool workqueue_freezing; /* W: have wqs started freezing? */

/* the per-cpu worker pools */
static DEFINE_PER_CPU_SHARED_ALIGNED(struct worker_pool [NR_STD_WORKER_POOLS],
cpu_worker_pools);

/*
* R: idr of all pools. Modifications are protected by workqueue_lock.
* Read accesses are protected by sched-RCU protected.
*/
static DEFINE_IDR(worker_pool_idr);

/* W: hash of all unbound pools keyed by pool->attrs */
static DEFINE_HASHTABLE(unbound_pool_hash, UNBOUND_POOL_HASH_ORDER);

Expand All @@ -265,6 +280,10 @@ EXPORT_SYMBOL_GPL(system_unbound_wq);
struct workqueue_struct *system_freezable_wq __read_mostly;
EXPORT_SYMBOL_GPL(system_freezable_wq);

static int worker_thread(void *__worker);
static void copy_workqueue_attrs(struct workqueue_attrs *to,
const struct workqueue_attrs *from);

#define CREATE_TRACE_POINTS
#include <trace/events/workqueue.h>

Expand Down Expand Up @@ -431,25 +450,6 @@ static inline void debug_work_activate(struct work_struct *work) { }
static inline void debug_work_deactivate(struct work_struct *work) { }
#endif

/* Serializes the accesses to the list of workqueues. */
static DEFINE_SPINLOCK(workqueue_lock);
static LIST_HEAD(workqueues);
static bool workqueue_freezing; /* W: have wqs started freezing? */

/* the per-cpu worker pools */
static DEFINE_PER_CPU_SHARED_ALIGNED(struct worker_pool [NR_STD_WORKER_POOLS],
cpu_worker_pools);

/*
* R: idr of all pools. Modifications are protected by workqueue_lock.
* Read accesses are protected by sched-RCU protected.
*/
static DEFINE_IDR(worker_pool_idr);

static int worker_thread(void *__worker);
static void copy_workqueue_attrs(struct workqueue_attrs *to,
const struct workqueue_attrs *from);

/* allocate ID and assign it to @pool */
static int worker_pool_assign_id(struct worker_pool *pool)
{
Expand Down

0 comments on commit 0bc4787

Please sign in to comment.