[igt-dev] [PATCH i-g-t] runner: sync writes to aborted.txt

Petri Latvala petri.latvala at intel.com
Tue Jul 26 05:31:44 UTC 2022


We have a couple of cases of aborted.txt existing but empty, try to
hunt down the cause.

Signed-off-by: Petri Latvala <petri.latvala at intel.com>
---
 runner/executor.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/runner/executor.c b/runner/executor.c
index 6e6ca9cc..a104e52d 100644
--- a/runner/executor.c
+++ b/runner/executor.c
@@ -1668,6 +1668,7 @@ static void write_abort_file(int resdirfd,
 		dprintf(abortfd, "Previous test: %s\n", testbefore);
 		dprintf(abortfd, "Next test: %s\n\n", testafter);
 		write(abortfd, reason, strlen(reason));
+		fdatasync(abortfd);
 		close(abortfd);
 	}
 }
-- 
2.30.2



More information about the igt-dev mailing list