public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] runner: Treat dmesg warnings as pure warnings
@ 2018-11-13 17:25 Chris Wilson
  2018-11-13 18:40 ` [igt-dev] ✗ Fi.CI.BAT: failure for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Chris Wilson @ 2018-11-13 17:25 UTC (permalink / raw)
  To: igt-dev; +Cc: Martin Peres, Petri Latvala

I have whinged on for ages about the dmesg-warnings being an expected
part of kernel testing (where else is the kernel meant to log its
errors?) and should be treated the same as our stderr for the test. That
is if a test fails, it fails and does not need to be conflated with
whether or not there was a dmesg warning (just as the test saying why it
failed on stderr does not need flagging), and that a passing test with a
dmesg warning is simply a warn.

The effect is that we simply remove the "dmesg-" flagging from results
names, as the err/dmesg output is simply collated for the error report
already.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Martin Peres <martin.peres@linux.intel.com>
---
 runner/resultgen.c | 17 +++++------------
 1 file changed, 5 insertions(+), 12 deletions(-)

diff --git a/runner/resultgen.c b/runner/resultgen.c
index a62e400e..394c904f 100644
--- a/runner/resultgen.c
+++ b/runner/resultgen.c
@@ -466,8 +466,8 @@ static bool fill_from_output(int fd, const char *binary, const char *key,
 
 /*
  * This regexp controls the kmsg handling. All kernel log records that
- * have log level of warning or higher convert the result to
- * dmesg-warn/dmesg-fail unless they match this regexp.
+ * have log level of warning or higher convert a passing result to
+ * warn unless they match this regexp.
  *
  * TODO: Move this to external files, i915-suppressions.txt,
  * general-suppressions.txt et al.
@@ -816,14 +816,11 @@ static void override_result_single(struct json_object *obj)
 {
 	const char *errtext = NULL, *result = NULL;
 	struct json_object *textobj;
-	bool dmesgwarns = false;
 
 	if (json_object_object_get_ex(obj, "err", &textobj))
 		errtext = json_object_get_string(textobj);
 	if (json_object_object_get_ex(obj, "result", &textobj))
 		result = json_object_get_string(textobj);
-	if (json_object_object_get_ex(obj, "dmesg-warnings", &textobj))
-		dmesgwarns = true;
 
 	if (!strcmp(result, "pass") &&
 	    count_lines(errtext, errtext + strlen(errtext)) > 2) {
@@ -831,13 +828,9 @@ static void override_result_single(struct json_object *obj)
 		result = "warn";
 	}
 
-	if (dmesgwarns) {
-		if (!strcmp(result, "pass") || !strcmp(result, "warn")) {
-			set_result(obj, "dmesg-warn");
-		} else if (!strcmp(result, "fail")) {
-			set_result(obj, "dmesg-fail");
-		}
-	}
+	if (json_object_object_get_ex(obj, "dmesg-warnings", &textobj) &&
+	    !strcmp(result, "pass"))
+		set_result(obj, "warn");
 }
 
 static void override_results(char *binary,
-- 
2.19.1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2018-11-22 14:26 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-13 17:25 [igt-dev] [PATCH i-g-t] runner: Treat dmesg warnings as pure warnings Chris Wilson
2018-11-13 18:40 ` [igt-dev] ✗ Fi.CI.BAT: failure for " Patchwork
2018-11-14 11:56 ` [igt-dev] [PATCH i-g-t] " Petri Latvala
2018-11-14 13:25   ` Ville Syrjälä
2018-11-14 13:34     ` Chris Wilson
2018-11-14 13:53       ` Ville Syrjälä
2018-11-21  8:07         ` Joonas Lahtinen
2018-11-21  9:18           ` Chris Wilson
2018-11-21 10:05             ` Joonas Lahtinen
2018-11-22  9:41               ` Daniel Vetter
2018-11-22  9:42                 ` Daniel Vetter
2018-11-22 12:59                 ` Joonas Lahtinen
2018-11-22 14:26                   ` Daniel Vetter
2018-11-14 13:04 ` [igt-dev] ✗ Fi.CI.BAT: failure for runner: Treat dmesg warnings as pure warnings (rev2) Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox