From: Anshuman Gupta <anshuman.gupta@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: petri.latvala@intel.com, badal.nilawar@intel.com
Subject: [igt-dev] [PATCH i-g-t v2 2/4] i915_pm_rpm: %s/display_disabled/display_enabled
Date: Wed, 11 May 2022 17:07:32 +0530 [thread overview]
Message-ID: <20220511113734.27776-3-anshuman.gupta@intel.com> (raw)
In-Reply-To: <20220511113734.27776-1-anshuman.gupta@intel.com>
Change var display_disabled to display_enabled, also
modify the passed argument and condition accordingly.
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Signed-off-by: Anshuman Gupta <anshuman.gupta@intel.com>
---
tests/i915/i915_pm_rpm.c | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/tests/i915/i915_pm_rpm.c b/tests/i915/i915_pm_rpm.c
index 2cc89eef2..b836656c2 100644
--- a/tests/i915/i915_pm_rpm.c
+++ b/tests/i915/i915_pm_rpm.c
@@ -784,7 +784,7 @@ static void dump_file(int dir, const char *filename)
free(contents);
}
-static bool setup_environment(bool display_disabled)
+static bool setup_environment(bool display_enabled)
{
if (has_runtime_pm)
goto out;
@@ -798,7 +798,7 @@ static bool setup_environment(bool display_disabled)
ms_data.devid = intel_get_drm_devid(drm_fd);
- if (!display_disabled)
+ if (display_enabled)
init_mode_set_data(&ms_data);
igt_pm_enable_sata_link_power_management();
@@ -812,14 +812,14 @@ static bool setup_environment(bool display_disabled)
igt_require(igt_pm_dmc_loaded(debugfs));
out:
- if (!display_disabled)
+ if (display_enabled)
disable_all_screens(&ms_data);
dump_file(debugfs, "i915_runtime_pm_status");
return wait_for_suspended();
}
-static void teardown_environment(bool display_disabled)
+static void teardown_environment(bool display_enabled)
{
close(msr_fd);
if (has_pc8)
@@ -829,7 +829,7 @@ static void teardown_environment(bool display_disabled)
igt_pm_restore_sata_link_power_management();
- if (!display_disabled)
+ if (display_enabled)
fini_mode_set_data(&ms_data);
close(debugfs);
@@ -2050,7 +2050,7 @@ static struct option long_options[] = {
igt_main_args("", long_options, help_str, opt_handler, NULL)
{
igt_subtest("basic-rte") {
- igt_assert(setup_environment(false));
+ igt_assert(setup_environment(true));
basic_subtest();
}
@@ -2058,7 +2058,7 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
* PC8+. We don't want bug reports from cases where the machine is just
* not properly configured. */
igt_fixture {
- igt_require(setup_environment(false));
+ igt_require(setup_environment(true));
}
if (stay)
@@ -2196,7 +2196,7 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
}
igt_fixture
- teardown_environment(false);
+ teardown_environment(true);
igt_subtest("module-reload") {
igt_debug("Reload w/o display\n");
@@ -2205,9 +2205,9 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
igt_kmsg(KMSG_INFO "Reloading i915 w/o display\n");
igt_assert_eq(igt_i915_driver_load("disable_display=1 mmio_debug=-1"), 0);
- igt_assert(setup_environment(true));
+ igt_assert(setup_environment(false));
igt_assert(igt_wait(device_in_pci_d3(), 2000, 100));
- teardown_environment(true);
+ teardown_environment(false);
igt_debug("Reload as normal\n");
igt_i915_driver_unload();
@@ -2215,11 +2215,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
igt_kmsg(KMSG_INFO "Reloading i915 as normal\n");
igt_assert_eq(igt_i915_driver_load("mmio_debug=-1"), 0);
- igt_assert(setup_environment(false));
+ igt_assert(setup_environment(true));
igt_assert(igt_wait(device_in_pci_d3(), 2000, 100));
if (enable_one_screen_with_type(&ms_data, SCREEN_TYPE_ANY))
drm_resources_equal_subtest();
- teardown_environment(false);
+ teardown_environment(true);
/* Remove our mmio_debugging module */
igt_i915_driver_unload();
--
2.26.2
next prev parent reply other threads:[~2022-05-11 11:37 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-11 11:37 [igt-dev] [PATCH i-g-t v2 0/4] RPM Test on HEADLESS Anshuman Gupta
2022-05-11 11:37 ` [igt-dev] [PATCH i-g-t v2 1/4] test: i915_pm_rpm: init devid in setup_envirnoment Anshuman Gupta
2022-05-11 11:37 ` Anshuman Gupta [this message]
2022-05-17 15:43 ` [igt-dev] [PATCH i-g-t v2 2/4] i915_pm_rpm: %s/display_disabled/display_enabled Dixit, Ashutosh
2022-05-11 11:37 ` [igt-dev] [PATCH i-g-t v2 3/4] test: i915_pm_rpm: conditional initialization of igt_display_t Anshuman Gupta
2022-05-17 15:52 ` Dixit, Ashutosh
2022-05-11 11:37 ` [igt-dev] [PATCH i-g-t v2 4/4] i915_pm_rpm: rpm resume by user forcewake Anshuman Gupta
2022-05-17 17:05 ` Dixit, Ashutosh
2022-05-18 6:28 ` Gupta, Anshuman
2022-05-11 12:17 ` [igt-dev] ✓ Fi.CI.BAT: success for RPM Test on HEADLESS (rev2) Patchwork
2022-05-11 15:39 ` [igt-dev] ✗ Fi.CI.IGT: 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=20220511113734.27776-3-anshuman.gupta@intel.com \
--to=anshuman.gupta@intel.com \
--cc=badal.nilawar@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=petri.latvala@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.