aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-02-15 10:43:19 +0000
committerSteve Sakoman <steve@sakoman.com>2023-02-17 04:41:08 -1000
commit2e1354525217505ce34fe775ee6ec8af46ff5324 (patch)
tree2503150f2308908d97244beb67b69797bf7dc23f
parent4316e9f60ce5fd250a16586a1772dcc0adfeb932 (diff)
downloadbitbake-contrib-2e1354525217505ce34fe775ee6ec8af46ff5324.tar.gz
runqueue: Avoid deadlock avoidance task graph corruption
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> Signed-off-by: Steve Sakoman <steve@sakoman.com>
-rw-r--r--lib/bb/runqueue.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/bb/runqueue.py b/lib/bb/runqueue.py
index 9efd1c86f..c7f50fdeb 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: