+ kthread-work-could-not-be-queued-when-worker-being-destroyed.patch added to -mm tree

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

 



The patch titled
     Subject: kthread: work could not be queued when worker being destroyed
has been added to the -mm tree.  Its filename is
     kthread-work-could-not-be-queued-when-worker-being-destroyed.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/kthread-work-could-not-be-queued-when-worker-being-destroyed.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/kthread-work-could-not-be-queued-when-worker-being-destroyed.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Zhang Qiang <qiang.zhang@xxxxxxxxxxxxx>
Subject: kthread: work could not be queued when worker being destroyed

The "queuing_blocked" func should print warning message and returns true
when the worker being destroyed.

Link: http://lkml.kernel.org/r/20200702070156.5862-1-qiang.zhang@xxxxxxxxxxxxx
Signed-off-by: Zhang Qiang <qiang.zhang@xxxxxxxxxxxxx>
Suggested-by: Petr Mladek <pmladek@xxxxxxxx>
Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 kernel/kthread.c |    3 +++
 1 file changed, 3 insertions(+)

--- a/kernel/kthread.c~kthread-work-could-not-be-queued-when-worker-being-destroyed
+++ a/kernel/kthread.c
@@ -814,6 +814,9 @@ static inline bool queuing_blocked(struc
 {
 	lockdep_assert_held(&worker->lock);
 
+	if (WARN_ON(!worker->task))
+		return true;
+
 	return !list_empty(&work->node) || work->canceling;
 }
 
_

Patches currently in -mm which might be from qiang.zhang@xxxxxxxxxxxxx are

kthread-work-could-not-be-queued-when-worker-being-destroyed.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux