bitbake-devel.lists.openembedded.org archive mirror
 help / color / mirror / Atom feed
From: "Anuj Mittal" <anuj.mittal@intel.com>
To: bitbake-devel@lists.openembedded.org
Subject: [1.50][PATCH 1/5] runqueue: Avoid deadlock avoidance task graph corruption
Date: Thu, 16 Sep 2021 07:19:34 +0800	[thread overview]
Message-ID: <0c95a8724b1b8d69b5c93aea4dbd1830cf161690.1631747835.git.anuj.mittal@intel.com> (raw)
In-Reply-To: <cover.1631747835.git.anuj.mittal@intel.com>

From: Richard Purdie <richard.purdie@linuxfoundation.org>

If the deferred task deadlock avoidance code triggers, it could mark an executed
task as failed which leads to "covered and not covered" error messages. Improve
the logic so if the deadlock code is triggered, it doesn't cause the errors.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 51bdd6cb3bd9e2c02e261fb578bb945b86b82c75)
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
---
 lib/bb/runqueue.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/bb/runqueue.py b/lib/bb/runqueue.py
index 6c41fe6d4..014ee37bf 100644
--- a/lib/bb/runqueue.py
+++ b/lib/bb/runqueue.py
@@ -2180,7 +2180,8 @@ class RunQueueExecute:
         if self.sq_deferred:
             tid = self.sq_deferred.pop(list(self.sq_deferred.keys())[0])
             logger.warning("Runqeueue deadlocked on deferred tasks, forcing task %s" % tid)
-            self.sq_task_failoutright(tid)
+            if tid not in self.runq_complete:
+                self.sq_task_failoutright(tid)
             return True
 
         if len(self.failed_tids) != 0:
-- 
2.31.1


  reply	other threads:[~2021-09-15 23:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-15 23:19 [1.50][PATCH 0/5] Review request Anuj Mittal
2021-09-15 23:19 ` Anuj Mittal [this message]
2021-09-15 23:19 ` [1.50][PATCH 2/5] runqueue: Fix issues with multiconfig deferred task deadlock messages Anuj Mittal
2021-09-15 23:19 ` [1.50][PATCH 3/5] cooker: Allow upstream for local hash equivalence server Anuj Mittal
2021-09-15 23:19 ` [1.50][PATCH 4/5] runqueue: Improve multiconfig deferred task issues Anuj Mittal
2021-09-15 23:19 ` [1.50][PATCH 5/5] build: Catch and error upon circular task references Anuj Mittal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0c95a8724b1b8d69b5c93aea4dbd1830cf161690.1631747835.git.anuj.mittal@intel.com \
    --to=anuj.mittal@intel.com \
    --cc=bitbake-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).