Re: [syzbot] [kernel?] KASAN: slab-use-after-free Read in thread_group_cputime

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/10/25 14:13, Jens Axboe wrote:
On 1/10/25 7:13 AM, Pavel Begunkov wrote:
On 1/10/25 13:56, Dmitry Vyukov wrote:
On Fri, 10 Jan 2025 at 14:51, syzbot
<syzbot+3d92cfcfa84070b0a470@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
...
#syz set subsystems: io-uring

+maintainers

Thanks. It probably needs something like below.

diff --git a/io_uring/sqpoll.c b/io_uring/sqpoll.c
index 6df5e649c413..5768e31e99b1 100644
--- a/io_uring/sqpoll.c
+++ b/io_uring/sqpoll.c
@@ -268,8 +268,12 @@ static int io_sq_thread(void *data)
         DEFINE_WAIT(wait);

         /* offload context creation failed, just exit */
-       if (!current->io_uring)
+       if (!current->io_uring) {
+               mutex_lock(&sqd->lock);
+               sqd->thread = NULL;
+               mutex_unlock(&sqd->lock);
                 goto err_out;
+       }

         snprintf(buf, sizeof(buf), "iou-sqp-%d", sqd->task_pid);
         set_task_comm(current, buf);

Indeed - can you send that out and I can include it in this weeks pull?

Done

--
Pavel Begunkov





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux