bitbake-devel.lists.openembedded.org archive mirror
 help / color / mirror / Atom feed
From: "Fabio Berton" <Fabio.Berton@criticaltechworks.com>
To: bitbake-devel@lists.openembedded.org
Subject: [1.46][PATCH 4/6] runqueue: Avoid deadlock avoidance task graph corruption
Date: Wed, 15 Feb 2023 10:43:19 +0000	[thread overview]
Message-ID: <20230215104321.1665505-5-fabio.berton@criticaltechworks.com> (raw)
In-Reply-To: <20230215104321.1665505-1-fabio.berton@criticaltechworks.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: Fabio Berton <fabio.berton@criticaltechworks.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 9efd1c86..c7f50fde 100644
--- a/lib/bb/runqueue.py
+++ b/lib/bb/runqueue.py
@@ -2234,7 +2234,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.25.1



  parent reply	other threads:[~2023-02-15 10:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-15 10:43 [1.46][PATCH 0/6] Backport multiconfig deferred fixes Fabio Berton
2023-02-15 10:43 ` [1.46][PATCH 1/6] runqueue: Fix multiconfig deferred task sstate validity caching issue Fabio Berton
2023-02-15 10:43 ` [1.46][PATCH 2/6] runqueue: Handle deferred task rehashing in multiconfig builds Fabio Berton
2023-02-15 10:43 ` [1.46][PATCH 3/6] runqueue: Improve multiconfig deferred task issues Fabio Berton
2023-02-15 10:43 ` Fabio Berton [this message]
2023-02-15 10:43 ` [1.46][PATCH 5/6] runqueue: Fix issues with multiconfig deferred task deadlock messages Fabio Berton
2023-02-15 10:43 ` [1.46][PATCH 6/6] runqueue: Ensure deferred tasks are sorted by multiconfig Fabio Berton
2023-02-17 15:08 ` [bitbake-devel] [1.46][PATCH 0/6] Backport multiconfig deferred fixes Richard Purdie

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=20230215104321.1665505-5-fabio.berton@criticaltechworks.com \
    --to=fabio.berton@criticaltechworks.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).