+struct workqueue_work {
+ struct flist_head list;
+};
+
+struct submit_worker {
+ pthread_t thread;
+ pthread_mutex_t lock;
+ pthread_cond_t cond;
+ struct flist_head work_list;
+ unsigned int flags;
+ unsigned int index;
+ uint64_t seq;
+ struct workqueue *wq;
+ void *priv;
+ struct sk_out *sk_out;
+};
+
+typedef int (workqueue_work_fn)(struct submit_worker *, struct workqueue_work *);
+typedef bool (workqueue_pre_sleep_flush_fn)(struct submit_worker *);
+typedef void (workqueue_pre_sleep_fn)(struct submit_worker *);
+typedef int (workqueue_alloc_worker_fn)(struct submit_worker *);
+typedef void (workqueue_free_worker_fn)(struct submit_worker *);
+typedef int (workqueue_init_worker_fn)(struct submit_worker *);
+typedef void (workqueue_exit_worker_fn)(struct submit_worker *, unsigned int *);
+typedef void (workqueue_update_acct_fn)(struct submit_worker *);
+
+struct workqueue_ops {
+ workqueue_work_fn *fn;
+ workqueue_pre_sleep_flush_fn *pre_sleep_flush_fn;
+ workqueue_pre_sleep_fn *pre_sleep_fn;
+
+ workqueue_update_acct_fn *update_acct_fn;
+
+ workqueue_alloc_worker_fn *alloc_worker_fn;
+ workqueue_free_worker_fn *free_worker_fn;
+
+ workqueue_init_worker_fn *init_worker_fn;
+ workqueue_exit_worker_fn *exit_worker_fn;
+
+ unsigned int nice;
+};