]> git.baikalelectronics.ru Git - kernel.git/commit
io-wq: Fix io_wq_worker_affinity()
authorPeter Zijlstra <peterz@infradead.org>
Thu, 8 Apr 2021 09:44:50 +0000 (11:44 +0200)
committerJens Axboe <axboe@kernel.dk>
Mon, 12 Apr 2021 01:30:40 +0000 (19:30 -0600)
commit3ddc41952d88c8150d8029b074a28dcdcbcdc652
tree10b9dbeb549c4f60a681525901a725205e127f4c
parenta4caabcdc2eb8aa228ed66ee0a71945ab434efd2
io-wq: Fix io_wq_worker_affinity()

Do not include private headers and do not frob in internals.

On top of that, while the previous code restores the affinity, it
doesn't ensure the task actually moves there if it was running,
leading to the fun situation that it can be observed running outside
of its allowed mask for potentially significant time.

Use the proper API instead.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/YG7QkiUzlEbW85TU@hirez.programming.kicks-ass.net
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io-wq.c