Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: "Zbigniew Kempczyński" <zbigniew.kempczynski@intel.com>
Cc: igt-dev@lists.freedesktop.org,
	Andrzej Turko <andrzej.turko@linux.intel.com>,
	Petri Latvala <petri.latvala@intel.com>
Subject: Re: [igt-dev] [PATCH i-g-t 5/9] tests/gem_exec_capture: Support gens without relocations
Date: Fri, 13 Aug 2021 18:29:28 -0700	[thread overview]
Message-ID: <87tujshkzr.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20210813074703.18778-6-zbigniew.kempczynski@intel.com>

On Fri, 13 Aug 2021 00:46:59 -0700, Zbigniew Kempczyński wrote:
>
> @@ -512,10 +545,13 @@ static void prioinv(int fd, int dir, const intel_ctx_t *ctx,
>		.rsvd1 = ctx->id,
>	};
>	int64_t timeout = NSEC_PER_SEC; /* 1s, feeling generous, blame debug */
> -	uint64_t ram, gtt, size = 4 << 20;
> +	uint64_t ram, gtt, ahnd, size = 4 << 20;
>	unsigned long count;
>	int link[2], dummy;
>
> +	ahnd = get_reloc_ahnd(fd, ctx->id);
> +	obj.offset = get_offset(ahnd, obj.handle, 4096, 0);
> +
>	igt_require(gem_scheduler_enabled(fd));
>	igt_require(igt_params_set(fd, "reset", "%u", -1)); /* engine resets! */
>	igt_require(gem_gpu_reset_type(fd) > 1);
> @@ -544,7 +580,14 @@ static void prioinv(int fd, int dir, const intel_ctx_t *ctx,
>		fd = gem_reopen_driver(fd);
>		igt_debug("Submitting large capture [%ld x %dMiB objects]\n",
>			  count, (int)(size >> 20));
> -		free(__captureN(fd, dir, ring, size, count, ASYNC));
> +
> +		intel_allocator_init();
> +		/* Reopen the allocator in the new process. */
> +		ahnd = get_reloc_ahnd(fd, 0);
> +
> +		free(__captureN(fd, dir, ahnd, ring, size, count, ASYNC));
> +		put_ahnd(ahnd);
> +
>		write(link[1], &fd, sizeof(fd)); /* wake the parent up */
>		igt_force_gpu_reset(fd);
>		write(link[1], &fd, sizeof(fd)); /* wake the parent up */
> @@ -567,19 +610,26 @@ static void prioinv(int fd, int dir, const intel_ctx_t *ctx,
>	close(link[1]);
>
>	gem_quiescent_gpu(fd);
> +	put_offset(ahnd, obj.handle);
> +	put_ahnd(ahnd);
> +	intel_allocator_multiprocess_stop();

Is this asymmetric intel_allocator_multiprocess_stop without a start
needed? Otherwise this is:

Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>

  reply	other threads:[~2021-08-14  1:48 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-13  7:46 [igt-dev] [PATCH i-g-t 0/9] Adopt to use allocator Zbigniew Kempczyński
2021-08-13  7:46 ` [igt-dev] [PATCH i-g-t 1/9] lib/intel_allocator: Fix argument names in declarations Zbigniew Kempczyński
2021-08-13  7:46 ` [igt-dev] [PATCH i-g-t 2/9] tests/gem_ctx_persistence: Adopt to use allocator Zbigniew Kempczyński
2021-08-13 20:43   ` Dixit, Ashutosh
2021-08-16  5:37     ` Zbigniew Kempczyński
2021-08-13  7:46 ` [igt-dev] [PATCH i-g-t 3/9] tests/gem_exec_balancer: " Zbigniew Kempczyński
2021-08-13  7:46 ` [igt-dev] [PATCH i-g-t 4/9] tests/gem_exec_big: Skip relocation part Zbigniew Kempczyński
2021-08-13 22:18   ` Dixit, Ashutosh
2021-08-16  5:42     ` Zbigniew Kempczyński
2021-08-13  7:46 ` [igt-dev] [PATCH i-g-t 5/9] tests/gem_exec_capture: Support gens without relocations Zbigniew Kempczyński
2021-08-14  1:29   ` Dixit, Ashutosh [this message]
2021-08-16  5:44     ` Zbigniew Kempczyński
2021-08-13  7:47 ` [igt-dev] [PATCH i-g-t 7/9] tests/gem_exec_flush: Adopt to no-reloc Zbigniew Kempczyński
2021-08-13 23:31   ` Dixit, Ashutosh
2021-08-13  7:47 ` [igt-dev] [PATCH i-g-t 8/9] tests/gem_exec_schedule: Adopt to use allocator Zbigniew Kempczyński
2021-08-13  7:47 ` [igt-dev] [PATCH i-g-t 9/9] HAX: remove gttfill for tgl ci Zbigniew Kempczyński
2021-08-13 10:34 ` [igt-dev] ✓ Fi.CI.IGT: success for Adopt to use allocator Patchwork
2021-08-15 19:30 ` [igt-dev] ✓ Fi.CI.BAT: success for Adopt to use allocator (rev2) Patchwork
2021-08-15 20:33 ` [igt-dev] ✓ Fi.CI.IGT: " 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=87tujshkzr.wl-ashutosh.dixit@intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=andrzej.turko@linux.intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=petri.latvala@intel.com \
    --cc=zbigniew.kempczynski@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