diff options
| author | Wenwen Chen <[email protected]> | 2023-05-25 08:26:26 +0000 |
|---|---|---|
| committer | Jens Axboe <[email protected]> | 2023-05-25 15:30:13 +0000 |
| commit | 533ab73f5b5c95dcb4152b52d5482abcc824c690 (patch) | |
| tree | 8214f20ed59dc84edeef2f7cf54c7b218c9b3cd4 /drivers/usb/cdns3/cdns3-trace.h | |
| parent | io_uring: make io_uring_sqe_cmd() unconditionally available (diff) | |
| download | kernel-533ab73f5b5c95dcb4152b52d5482abcc824c690.tar.gz kernel-533ab73f5b5c95dcb4152b52d5482abcc824c690.zip | |
io_uring: unlock sqd->lock before sq thread release CPU
The sq thread actively releases CPU resources by calling the
cond_resched() and schedule() interfaces when it is idle. Therefore,
more resources are available for other threads to run.
There exists a problem in sq thread: it does not unlock sqd->lock before
releasing CPU resources every time. This makes other threads pending on
sqd->lock for a long time. For example, the following interfaces all
require sqd->lock: io_sq_offload_create(), io_register_iowq_max_workers()
and io_ring_exit_work().
Before the sq thread releases CPU resources, unlocking sqd->lock will
provide the user a better experience because it can respond quickly to
user requests.
Signed-off-by: Kanchan Joshi<[email protected]>
Signed-off-by: Wenwen Chen<[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-trace.h')
0 files changed, 0 insertions, 0 deletions
