projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0b416c3
)
io-wq: re-add io_wq_current_is_worker()
author
Jens Axboe
<axboe@kernel.dk>
Tue, 17 Dec 2019 21:13:37 +0000
(14:13 -0700)
committer
Jens Axboe
<axboe@kernel.dk>
Wed, 18 Dec 2019 02:57:20 +0000
(19:57 -0700)
This reverts commit
8cdda87a4414
, we now have several use csaes for this
helper. Reinstate it.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io-wq.h
patch
|
blob
|
history
diff --git
a/fs/io-wq.h
b/fs/io-wq.h
index fb993b2bd0ef019e76438bc5483b2995ba49fc8a..3f5e356de98050f67503336cfac1db64f455230d 100644
(file)
--- a/
fs/io-wq.h
+++ b/
fs/io-wq.h
@@
-120,6
+120,10
@@
static inline void io_wq_worker_sleeping(struct task_struct *tsk)
static inline void io_wq_worker_running(struct task_struct *tsk)
{
}
-#endif
/* CONFIG_IO_WQ */
+#endif
-#endif /* INTERNAL_IO_WQ_H */
+static inline bool io_wq_current_is_worker(void)
+{
+ return in_task() && (current->flags & PF_IO_WORKER);
+}
+#endif