summaryrefslogtreecommitdiff
path: root/io_uring/sqpoll.h
diff options
context:
space:
mode:
authorLeon Romanovsky <leon@kernel.org>2025-06-25 03:57:23 -0400
committerLeon Romanovsky <leon@kernel.org>2025-06-25 03:57:23 -0400
commit4aa765af7983d51eafa13d76398045a5e687b73d (patch)
treea3da8fece8eb8caf6143bb160f2ec3ce8019f219 /io_uring/sqpoll.h
parentb5eeb8365d196c95dbb0fd0a5b5a69a44832f16f (diff)
parent52931f55159ea5c27ad4fe66fc0cb8ad75ab795b (diff)
Add multiple priorities support to mlx5 RDMA TRANSPORT tables
From Patrisious: This short series from Patrisious extends mlx5 flow steering logic to allow creation rule creation with priorities in RDMA TRANSPORT tables. Thanks Link: https://lore.kernel.org/all/cover.1750148083.git.leon@kernel.org Signed-off-by: Leon Romanovsky <leon@kernel.org> * mlx5-next: (200 commits) net/mlx5: fs, add multiple prios to RDMA TRANSPORT steering domain Linux 6.16-rc2 ...
Diffstat (limited to 'io_uring/sqpoll.h')
-rw-r--r--io_uring/sqpoll.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/io_uring/sqpoll.h b/io_uring/sqpoll.h
index 4171666b1cf4..b83dcdec9765 100644
--- a/io_uring/sqpoll.h
+++ b/io_uring/sqpoll.h
@@ -8,7 +8,7 @@ struct io_sq_data {
/* ctx's that are using this sqd */
struct list_head ctx_list;
- struct task_struct *thread;
+ struct task_struct __rcu *thread;
struct wait_queue_head wait;
unsigned sq_thread_idle;
@@ -29,3 +29,9 @@ void io_sq_thread_unpark(struct io_sq_data *sqd);
void io_put_sq_data(struct io_sq_data *sqd);
void io_sqpoll_wait_sq(struct io_ring_ctx *ctx);
int io_sqpoll_wq_cpu_affinity(struct io_ring_ctx *ctx, cpumask_var_t mask);
+
+static inline struct task_struct *sqpoll_task_locked(struct io_sq_data *sqd)
+{
+ return rcu_dereference_protected(sqd->thread,
+ lockdep_is_held(&sqd->lock));
+}