From: Simon Glass <sjg@chromium.org>
Date: Mon, 22 Mar 2021 05:01:42 +0000 (+1300)
Subject: patman: Continue on if warnings are found outside a commit
X-Git-Tag: v2025.01-rc5-pxa1908~1939^2~18
X-Git-Url: http://git.dujemihanovic.xyz/img/html/%7B%7B%20%28.OutputFormats.Get?a=commitdiff_plain;h=42bc156f803995ca749f88a435706e3c8fb5f557;p=u-boot.git

patman: Continue on if warnings are found outside a commit

While we cannot know which commit the warning relates to, this should not
be fatal. Print the warning and carry on.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

diff --git a/tools/patman/patchstream.py b/tools/patman/patchstream.py
index cdcd50a849..a44cd861af 100644
--- a/tools/patman/patchstream.py
+++ b/tools/patman/patchstream.py
@@ -133,8 +133,8 @@ class PatchStream:
             ValueError: Warning is generated with no commit associated
         """
         if not self.commit:
-            raise ValueError('Warning outside commit: %s' % warn)
-        if warn not in self.commit.warn:
+            print('Warning outside commit: %s' % warn)
+        elif warn not in self.commit.warn:
             self.commit.warn.append(warn)
 
     def _add_to_series(self, line, name, value):