From: Rodrigo Vivi <rodrigo.vivi@intel.com>
To: Anshuman Gupta <anshuman.gupta@intel.com>
Cc: igt-dev@lists.freedesktop.org, badal.nilawar@intel.com,
Chris Wilson <chris.p.wilson@intel.com>
Subject: Re: [igt-dev] [PATCH i-g-t 1/9] test/i915_pm_rpm: Add placement to gem-{mmap-type, execbuf}
Date: Fri, 22 Apr 2022 05:26:40 -0400 [thread overview]
Message-ID: <YmJ00H6aMy13sF6o@intel.com> (raw)
In-Reply-To: <20220418125048.7969-2-anshuman.gupta@intel.com>
On Mon, Apr 18, 2022 at 06:20:40PM +0530, Anshuman Gupta wrote:
> Add memory region placement to gem-{mmap-type, execbuf} subtest.
> This will be useful to extend these sub-test for D3Cold.
>
> Cc: Chris Wilson <chris.p.wilson@intel.com>
> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
> Signed-off-by: Anshuman Gupta <anshuman.gupta@intel.com>
> ---
> tests/i915/i915_pm_rpm.c | 23 +++++++++++++++--------
> 1 file changed, 15 insertions(+), 8 deletions(-)
>
> diff --git a/tests/i915/i915_pm_rpm.c b/tests/i915/i915_pm_rpm.c
> index 461730e8a..d2bce5826 100644
> --- a/tests/i915/i915_pm_rpm.c
> +++ b/tests/i915/i915_pm_rpm.c
> @@ -1069,7 +1069,8 @@ static void debugfs_forcewake_user_subtest(void)
> igt_assert(wait_for_suspended());
> }
>
> -static void gem_mmap_args(const struct mmap_offset *t)
> +static void gem_mmap_args(const struct mmap_offset *t,
> + struct drm_i915_gem_memory_class_instance *mem_regions)
> {
> int i;
> uint32_t handle;
> @@ -1079,7 +1080,7 @@ static void gem_mmap_args(const struct mmap_offset *t)
> /* Create, map and set data while the device is active. */
> enable_one_screen_and_wait(&ms_data);
>
> - handle = gem_create(drm_fd, buf_size);
> + handle = gem_create_in_memory_region_list(drm_fd, buf_size, mem_regions, 1);
>
> gem_buf = __gem_mmap_offset(drm_fd, handle, 0, buf_size,
> PROT_READ | PROT_WRITE, t->type);
> @@ -1290,7 +1291,7 @@ static void submit_blt_cmd(uint32_t dst_handle, int dst_size,
> }
>
> /* Make sure we can submit a batch buffer and verify its result. */
> -static void gem_execbuf_subtest(void)
> +static void gem_execbuf_subtest(struct drm_i915_gem_memory_class_instance *mem_regions)
> {
> int x, y;
> uint32_t handle;
> @@ -1308,7 +1309,7 @@ static void gem_execbuf_subtest(void)
> /* Create and set data while the device is active. */
> enable_one_screen_and_wait(&ms_data);
>
> - handle = gem_create(drm_fd, dst_size);
> + handle = gem_create_in_memory_region_list(drm_fd, dst_size, mem_regions, 1);
>
> cpu_buf = malloc(dst_size);
> igt_assert(cpu_buf);
> @@ -2083,15 +2084,21 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
> /* GEM */
> igt_subtest_with_dynamic("gem-mmap-type") {
> for_each_mmap_offset_type(drm_fd, t) {
> - igt_dynamic_f("%s", t->name)
> - gem_mmap_args(t);
> + for_each_memory_region(r, drm_fd) {
> + igt_dynamic_f("%s-%s", t->name, r->name)
> + gem_mmap_args(t, &r->ci);
> + }
> }
> }
>
> igt_subtest("gem-pread")
> gem_pread_subtest();
> - igt_subtest("gem-execbuf")
> - gem_execbuf_subtest();
> + igt_subtest_with_dynamic("gem-execbuf") {
> + for_each_memory_region(r, drm_fd) {
> + igt_dynamic_f("%s", r->name)
> + gem_execbuf_subtest(&r->ci);
> + }
> + }
I believe for D3Cold the only ones that matters are the lmem ones,
but I don't believe it hurts to try more.
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> igt_subtest("gem-idle")
> gem_idle_subtest();
> igt_subtest("gem-evict-pwrite") {
> --
> 2.26.2
>
next prev parent reply other threads:[~2022-04-22 9:26 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-18 12:50 [igt-dev] [PATCH i-g-t 0/9] D3Cold Tool & IGT Anshuman Gupta
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 1/9] test/i915_pm_rpm: Add placement to gem-{mmap-type, execbuf} Anshuman Gupta
2022-04-22 9:26 ` Rodrigo Vivi [this message]
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 2/9] lib/igt_device: Get gfx PCI card root port Anshuman Gupta
2022-04-22 9:29 ` Rodrigo Vivi
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 3/9] lib/igt_pm: D3Cold runtime pm infrastructure Anshuman Gupta
2022-04-22 10:16 ` Rodrigo Vivi
2022-04-26 12:23 ` Gupta, Anshuman
2022-04-26 13:22 ` Rodrigo Vivi
2022-04-26 16:06 ` Kamil Konieczny
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 4/9] lib/intel_device_info: Add IS_DGFX() support Anshuman Gupta
2022-04-22 10:17 ` Rodrigo Vivi
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 5/9] tools: Add intel_pm_rpm tool Anshuman Gupta
2022-04-22 10:22 ` Rodrigo Vivi
2022-04-22 12:07 ` Rodrigo Vivi
2022-04-28 6:59 ` Gupta, Anshuman
2022-04-28 8:38 ` Vivi, Rodrigo
2022-04-29 8:58 ` Gupta, Anshuman
2022-04-22 12:08 ` Gupta, Anshuman
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 6/9] i915_pm_rpm: Add D3Cold basic subtest Anshuman Gupta
2022-04-22 12:01 ` Rodrigo Vivi
2022-04-22 14:22 ` Kamil Konieczny
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 7/9] i915_pm_rpm: Test D3Cold with gem_exec_stress Anshuman Gupta
2022-04-22 12:03 ` Rodrigo Vivi
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 8/9] i915_pm_rpm: Extend gem_execbuf test with D3Cold Anshuman Gupta
2022-04-22 12:04 ` Rodrigo Vivi
2022-04-18 12:50 ` [igt-dev] [PATCH i-g-t 9/9] i915_pm_rpm: Extend gem-mmap-type " Anshuman Gupta
2022-04-22 12:05 ` Rodrigo Vivi
2022-04-18 13:01 ` [igt-dev] ✗ GitLab.Pipeline: warning for D3Cold Tool & IGT Patchwork
2022-04-22 9:35 ` Rodrigo Vivi
2022-04-22 11:19 ` Petri Latvala
2022-04-18 13:34 ` [igt-dev] ✗ Fi.CI.BAT: failure " 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=YmJ00H6aMy13sF6o@intel.com \
--to=rodrigo.vivi@intel.com \
--cc=anshuman.gupta@intel.com \
--cc=badal.nilawar@intel.com \
--cc=chris.p.wilson@intel.com \
--cc=igt-dev@lists.freedesktop.org \
/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