Content-Type: multipart/mixed; boundary="===============4276627877898087097==" MIME-Version: 1.0 From: Julia Lawall To: kbuild-all@lists.01.org Subject: [block:for-5.5/io_uring-wq 11/11] fs/io-wq.c:291:2-11: second lock on line 291 (fwd) Date: Thu, 24 Oct 2019 10:12:56 +0200 Message-ID: List-Id: --===============4276627877898087097== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hello, This is actually complaining about the continues on lines 295 and 298. I guess the calls to io_wq_run_queue and __io_worker_idle release the lock in the case of success? julia ---------- Forwarded message ---------- Date: Thu, 24 Oct 2019 16:03:20 +0800 From: kbuild test robot To: kbuild(a)lists.01.org Cc: Julia Lawall Subject: [block:for-5.5/io_uring-wq 11/11] fs/io-wq.c:291:2-11: second lock= on line 291 CC: kbuild-all(a)lists.01.org TO: Jens Axboe tree: https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.g= it for-5.5/io_uring-wq head: f27f11bf017ca5918ab91b63aa146fbb053c7558 commit: f27f11bf017ca5918ab91b63aa146fbb053c7558 [11/11] io_uring: replace = workqueue with io-wq :::::: branch date: 8 hours ago :::::: commit date: 8 hours ago If you fix the issue, kindly add following tag Reported-by: kbuild test robot Reported-by: Julia Lawall >> fs/io-wq.c:291:2-11: second lock on line 291 fs/io-wq.c:291:2-11: second lock on line 313 # https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git/com= mit/?id=3Df27f11bf017ca5918ab91b63aa146fbb053c7558 git remote add block https://git.kernel.org/pub/scm/linux/kernel/git/axboe/= linux-block.git git remote update block git checkout f27f11bf017ca5918ab91b63aa146fbb053c7558 vim +291 fs/io-wq.c f27f11bf017ca5 Jens Axboe 2019-10-22 279 f27f11bf017ca5 Jens Axboe 2019-10-22 280 static int io_wq_worker(void *da= ta) f27f11bf017ca5 Jens Axboe 2019-10-22 281 { f27f11bf017ca5 Jens Axboe 2019-10-22 282 struct io_worker *worker =3D da= ta; f27f11bf017ca5 Jens Axboe 2019-10-22 283 struct io_wq *wq =3D worker->wq; f27f11bf017ca5 Jens Axboe 2019-10-22 284 DEFINE_WAIT(wait); f27f11bf017ca5 Jens Axboe 2019-10-22 285 f27f11bf017ca5 Jens Axboe 2019-10-22 286 io_worker_start(wq, worker); f27f11bf017ca5 Jens Axboe 2019-10-22 287 f27f11bf017ca5 Jens Axboe 2019-10-22 288 while (!test_bit(IO_WQ_BIT_EXIT= , &wq->state)) { f27f11bf017ca5 Jens Axboe 2019-10-22 289 prepare_to_wait(&worker->wait,= &wait, TASK_INTERRUPTIBLE); f27f11bf017ca5 Jens Axboe 2019-10-22 290 f27f11bf017ca5 Jens Axboe 2019-10-22 @291 spin_lock(&wq->lock); f27f11bf017ca5 Jens Axboe 2019-10-22 292 if (io_wq_run_queue(wq)) { f27f11bf017ca5 Jens Axboe 2019-10-22 293 __set_current_state(TASK_RUNN= ING); f27f11bf017ca5 Jens Axboe 2019-10-22 294 io_worker_handle_work(worker); f27f11bf017ca5 Jens Axboe 2019-10-22 295 continue; f27f11bf017ca5 Jens Axboe 2019-10-22 296 } f27f11bf017ca5 Jens Axboe 2019-10-22 297 if (__io_worker_idle(wq, worke= r)) f27f11bf017ca5 Jens Axboe 2019-10-22 298 continue; f27f11bf017ca5 Jens Axboe 2019-10-22 299 spin_unlock(&wq->lock); f27f11bf017ca5 Jens Axboe 2019-10-22 300 if (signal_pending(current)) f27f11bf017ca5 Jens Axboe 2019-10-22 301 flush_signals(current); f27f11bf017ca5 Jens Axboe 2019-10-22 302 if (schedule_timeout(WORKER_ID= LE_TIMEOUT)) f27f11bf017ca5 Jens Axboe 2019-10-22 303 continue; f27f11bf017ca5 Jens Axboe 2019-10-22 304 /* timed out, exit unless we'r= e the fixed worker */ f27f11bf017ca5 Jens Axboe 2019-10-22 305 if (test_bit(IO_WQ_BIT_EXIT, &= wq->state) || f27f11bf017ca5 Jens Axboe 2019-10-22 306 !(worker->flags & IO_WORKE= R_F_FIXED)) f27f11bf017ca5 Jens Axboe 2019-10-22 307 break; f27f11bf017ca5 Jens Axboe 2019-10-22 308 } f27f11bf017ca5 Jens Axboe 2019-10-22 309 f27f11bf017ca5 Jens Axboe 2019-10-22 310 finish_wait(&worker->wait, &wai= t); f27f11bf017ca5 Jens Axboe 2019-10-22 311 f27f11bf017ca5 Jens Axboe 2019-10-22 312 if (test_bit(IO_WQ_BIT_EXIT, &w= q->state)) { f27f11bf017ca5 Jens Axboe 2019-10-22 313 spin_lock(&wq->lock); f27f11bf017ca5 Jens Axboe 2019-10-22 314 if (!list_empty(&wq->work_list= )) f27f11bf017ca5 Jens Axboe 2019-10-22 315 io_worker_handle_work(worker); f27f11bf017ca5 Jens Axboe 2019-10-22 316 else f27f11bf017ca5 Jens Axboe 2019-10-22 317 spin_unlock(&wq->lock); f27f11bf017ca5 Jens Axboe 2019-10-22 318 } f27f11bf017ca5 Jens Axboe 2019-10-22 319 f27f11bf017ca5 Jens Axboe 2019-10-22 320 io_worker_exit(worker); f27f11bf017ca5 Jens Axboe 2019-10-22 321 return 0; f27f11bf017ca5 Jens Axboe 2019-10-22 322 } f27f11bf017ca5 Jens Axboe 2019-10-22 323 --- 0-DAY kernel test infrastructure Open Source Technology Cent= er https://lists.01.org/pipermail/kbuild-all Intel Corporati= on --===============4276627877898087097==--