public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: "Zbigniew Kempczyński" <zbigniew.kempczynski@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: "Zbigniew Kempczyński" <zbigniew.kempczynski@intel.com>,
	"Kamil Konieczny" <kamil.konieczny@linux.intel.com>,
	"Ryszard Knop" <ryszard.knop@intel.com>,
	"Krzysztof Karas" <krzysztof.karas@intel.com>
Subject: [PATCH i-g-t v3 1/5] runner: Rename dirfd to avoid clash with dirfd()
Date: Mon, 13 Apr 2026 22:17:24 +0200	[thread overview]
Message-ID: <20260413201722.808673-8-zbigniew.kempczynski@intel.com> (raw)
In-Reply-To: <20260413201722.808673-7-zbigniew.kempczynski@intel.com>

Upcoming change within execute_next_entry() will call dirfd() so
rename local dirfd variable is necessary.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Kamil Konieczny <kamil.konieczny@linux.intel.com>
Cc: Ryszard Knop <ryszard.knop@intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
Reviewed-by: Krzysztof Karas <krzysztof.karas@intel.com>
---
 runner/executor.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/runner/executor.c b/runner/executor.c
index 847abe481a..1485b59d1f 100644
--- a/runner/executor.c
+++ b/runner/executor.c
@@ -1772,7 +1772,7 @@ static int execute_next_entry(struct execute_state *state,
 			      char **abortreason,
 			      bool *abort_already_written)
 {
-	int dirfd;
+	int idirfd;
 	int outputs[_F_LAST];
 	int kmsgfd;
 	int outpipe[2] = { -1, -1 };
@@ -1786,19 +1786,19 @@ static int execute_next_entry(struct execute_state *state,
 
 	snprintf(name, sizeof(name), "%zd", idx);
 	mkdirat(resdirfd, name, 0777);
-	if ((dirfd = openat(resdirfd, name, O_DIRECTORY | O_RDONLY | O_CLOEXEC)) < 0) {
+	if ((idirfd = openat(resdirfd, name, O_DIRECTORY | O_RDONLY | O_CLOEXEC)) < 0) {
 		errf("Error accessing individual test result directory\n");
 		return -1;
 	}
 
-	if (!open_output_files(dirfd, outputs, true)) {
+	if (!open_output_files(idirfd, outputs, true)) {
 		errf("Error opening output files\n");
 		result = -1;
 		goto out_dirfd;
 	}
 
 	if (settings->sync) {
-		fsync(dirfd);
+		fsync(idirfd);
 		fsync(resdirfd);
 	}
 
@@ -1900,8 +1900,8 @@ out_pipe:
 	close_outputs(outputs);
 out_dirfd:
 	if (settings->sync)
-		fsync(dirfd);
-	close(dirfd);
+		fsync(idirfd);
+	close(idirfd);
 	if (settings->sync)
 		fsync(resdirfd);
 
-- 
2.43.0


  reply	other threads:[~2026-04-13 20:18 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-13 20:17 [PATCH i-g-t v3 0/5] RFC: Add attachments support Zbigniew Kempczyński
2026-04-13 20:17 ` Zbigniew Kempczyński [this message]
2026-04-14  7:40   ` [PATCH i-g-t v3 1/5] runner: Rename dirfd to avoid clash with dirfd() Krzysztof Karas
2026-04-13 20:17 ` [PATCH i-g-t v3 2/5] runner: Create attachments directory to use by hooks Zbigniew Kempczyński
2026-04-14  7:34   ` Krzysztof Karas
2026-04-14 19:13     ` Zbigniew Kempczyński
2026-04-14 19:27   ` Gustavo Sousa
2026-04-15  5:34     ` Zbigniew Kempczyński
2026-04-15 13:48       ` Gustavo Sousa
2026-04-15 16:37         ` Zbigniew Kempczyński
2026-04-13 20:17 ` [PATCH i-g-t v3 3/5] scripts/hooks: Example guc log copy script and allowlist Zbigniew Kempczyński
2026-04-14  8:06   ` Krzysztof Karas
2026-04-14 19:34     ` Zbigniew Kempczyński
2026-04-14 20:33   ` Gustavo Sousa
2026-04-15  8:23     ` Zbigniew Kempczyński
2026-04-15 12:51       ` Gustavo Sousa
2026-04-16 18:44         ` Zbigniew Kempczyński
2026-04-16 19:59           ` Gustavo Sousa
2026-04-13 20:17 ` [PATCH i-g-t v3 4/5] runner/resultgen: Add json array create/get helper Zbigniew Kempczyński
2026-04-14  8:31   ` Krzysztof Karas
2026-04-13 20:17 ` [PATCH i-g-t v3 5/5] runner/resultgen: Insert attachments list into results.json Zbigniew Kempczyński
2026-04-14  9:35   ` Krzysztof Karas
2026-04-14 19:39     ` Zbigniew Kempczyński
2026-04-14 21:39   ` Gustavo Sousa
2026-04-15  6:31     ` Zbigniew Kempczyński
2026-04-15 12:16       ` Gustavo Sousa
2026-04-15 16:09         ` Zbigniew Kempczyński
2026-04-15 16:20           ` Gustavo Sousa
2026-04-15 19:56             ` Zbigniew Kempczyński
2026-04-15 20:31               ` Gustavo Sousa
2026-04-14  1:57 ` ✓ i915.CI.BAT: success for RFC: Add attachments support (rev3) Patchwork
2026-04-14  2:03 ` ✓ Xe.CI.BAT: " Patchwork
2026-04-14  5:30 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-04-14  7:59 ` ✓ i915.CI.Full: success " Patchwork

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=20260413201722.808673-8-zbigniew.kempczynski@intel.com \
    --to=zbigniew.kempczynski@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=kamil.konieczny@linux.intel.com \
    --cc=krzysztof.karas@intel.com \
    --cc=ryszard.knop@intel.com \
    /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