Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Sundaresan, Sujaritha" <sujaritha.sundaresan@intel.com>
To: Kamil Konieczny <kamil.konieczny@linux.intel.com>,
	<igt-dev@lists.freedesktop.org>,
	Anshuman Gupta <anshuman.gupta@intel.com>,
	Katarzyna Piecielska <katarzyna.piecielska@intel.com>
Subject: Re: [PATCH i-g-t, v3] tests/intel: Add tests to run suspend without display
Date: Fri, 9 Aug 2024 17:12:17 +0530	[thread overview]
Message-ID: <61358f2a-1739-499c-bb7f-572c469e7a45@intel.com> (raw)
In-Reply-To: <20240809101003.stg7tgdqxh36hj4z@kamilkon-DESK.igk.intel.com>


On 8/9/2024 3:40 PM, Kamil Konieczny wrote:
> Hi Sundaresan,,
> On 2024-08-09 at 14:34:23 +0530, Sundaresan, Sujaritha wrote:
>> On 8/6/2024 6:20 PM, Kamil Konieczny wrote:
>>> Hi Sundaresan,,
>>> On 2024-08-06 at 11:50:46 +0530, Sundaresan, Sujaritha wrote:
>>>> On 8/1/2024 5:15 PM, Kamil Konieczny wrote:
>>>>> Hi Sujaritha,
>>>>> On 2024-07-30 at 17:05:08 +0530, Sujaritha Sundaresan wrote:
>>>>>
>>>>> small nit about subject, you wrote:
>>>>>
>>>>> [PATCH i-g-t, v3] tests/intel: Add tests to run suspend without display
>>>>>
>>>>> imho this should be:
>>>>>
>>>>> [PATCH i-g-t, v3] tests/intel/xe_pm: Add tests for suspend without display
>>>>>
>>>>> More nits below.
>>>> Hey Kamil,
>>>>
>>>> Sure this change I can make.
>>>>
>>>>>> Add tests to validate basic execution suspend/resume cycle
>>>>>> without display module to rule out display related issues
>>>>>> from the suspend/resume stack.
>>>>>>
>>>>>> v2: Add normal reload cycle after running test (Anshuman)
>>>>>>
>>>>>> v3: Rebase
>>>>>>
>>>>>> Signed-off-by: Sujaritha Sundaresan<sujaritha.sundaresan@intel.com>
>>>>>> Reviewed-by: Anshuman Gupta<anshuman.gupta@intel.com>
>>>>>> ---
>>>>>>     tests/intel/xe_pm.c | 34 ++++++++++++++++++++++++++++++++++
>>>>>>     1 file changed, 34 insertions(+)
>>>>>>
>>>>>> diff --git a/tests/intel/xe_pm.c b/tests/intel/xe_pm.c
>>>>>> index 8b115e2f6..03f742265 100644
>>>>>> --- a/tests/intel/xe_pm.c
>>>>>> +++ b/tests/intel/xe_pm.c
>>>>>> @@ -17,6 +17,7 @@
>>>>>>     #include "igt.h"
>>>>>>     #include "lib/igt_device.h"
>>>>>> +#include "lib/igt_kmod.h"
>>>>>>     #include "lib/igt_pm.h"
>>>>>>     #include "lib/igt_sysfs.h"
>>>>>>     #include "lib/igt_syncobj.h"
>>>>>> @@ -229,6 +230,10 @@ static void close_fw_handle(int sig)
>>>>>>      * Description: suspend/autoresume on %arg[1] state and exec after RPM
>>>>>>      * Functionality: pm - %arg[1]
>>>>>>      *
>>>>>> + * SUBTEST: %s-without-display
>>>>>> + * Description: suspend/autoresume on %arg[1] state without display
>>>>>> + * Functionality: pm - %arg[1]
>>>>> I see you copy-pasted it but imho both Description and
>>>>> Functionality documentation fields should be static, here and
>>>>> in other places.
>>>>> +cc Katarzyna Piecielska<katarzyna.piecielska@intel.com>
>> Hi Kamil,
>>
>> Sorry I didn't get this change. This is inline with the rest of the file
>> right ?
> Yes but this looks strange, so I added Katarzyna to discussion.
>
>>>>>> + *
>>>>>>      * arg[1]:
>>>>>>      *
>>>>>>      * @s2idle:	s2idle
>>>>>> @@ -681,6 +686,7 @@ igt_main
>>>>>>     	struct drm_xe_engine_class_instance *hwe;
>>>>>>     	device_t device;
>>>>>>     	uint32_t d3cold_allowed;
>>>>>> +	const char *opts;
>>>>>>     	int sysfs_fd;
>>>>>>     	const struct s_state {
>>>>>> @@ -757,6 +763,34 @@ igt_main
>>>>>>     					  NO_RPM, 0);
>>>>>>     		}
>>>>>> +		igt_subtest_f("%s-without-display", s->name) {
>>>>>> +
>>>>>> +			if (!drmModeGetResources(device.fd_xe))
>>>>>> +				return;
>>>>> Why 'return' here?! Imho this should be checked in fixture
>>>>> or be a skip. Or other way around - what about a headless board
>>>>> or one without any connected display?
>>>>>
>>>>> Regards,
>>>>> Kamil
>>>> I think this patch idea sort stemmed from the cases where we have a display
>>>> connected and
>>>>
>>>> want to make sure that the suspend/resume issues are not being caused by the
>>>> display.
>>>>
>>>> But would you suggest expanding the test to have the headless/no display
>>>> situations? If so what changes are you suggesting for that ?
>>>>
>>>> Thanks,
>>>>
>>>> Suja
>>>>
>>> I would suggest turn this into a igt_skip_on_f(), not a return.
>>>
>>> Regards,
>>> Kamil
>> Sure I will switch this to
>>
>> igt_skip_on(!drmModeGetResources(device.fd_xe))
>>
>> Thanks,
>>
>> Suja
>>
> On the second look - can we just ignore this and proceed with test?
> It should do no harm when you have no display connected?
>
> Regards,
> Kamil

  So just go back to the original return right ?

Yeah I guess that wouldn't cause any problems necessarily.

Thanks,

Suja

>
>>>>>> +
>>>>>> +			xe_for_each_engine(device.fd_xe, hwe) {
>>>>>> +
>>>>>> +				igt_debug("Reload w/o display\n");
>>>>>> +
>>>>>> +				igt_kmsg(KMSG_INFO "Unloading Xe\n");
>>>>>> +				igt_assert_eq(igt_xe_driver_unload(), 0);
>>>>>> +
>>>>>> +				igt_kmsg(KMSG_INFO "Re-loading Xe without display\n");
>>>>>> +				igt_assert_eq(igt_xe_driver_load("enable_display=0"), 0);
>>>>>> +
>>>>>> +				test_exec(device, hwe, 1, 2, s->state,
>>>>>> +					  NO_RPM, 0);
>>>>>> +
>>>>>> +				igt_debug("Reload as normal\n");
>>>>>> +
>>>>>> +				igt_kmsg(KMSG_INFO "Unloading Xe\n");
>>>>>> +				igt_assert_eq(igt_xe_driver_unload(), 0);
>>>>>> +
>>>>>> +				igt_kmsg(KMSG_INFO "Re-loading Xe\n");
>>>>>> +				igt_assert_eq(igt_xe_driver_load(opts), 0);
>>>>>> +			}
>>>>>> +		}
>>>>>> +
>>>>>>     		for (const struct vm_op *op = vm_op; op->name; op++) {
>>>>>>     			igt_subtest_f("%s-vm-bind-%s", s->name, op->name) {
>>>>>>     				xe_for_each_engine(device.fd_xe, hwe)
>>>>>> -- 
>>>>>> 2.34.1
>>>>>>

  reply	other threads:[~2024-08-09 11:42 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-30 11:35 [PATCH i-g-t, v3] tests/intel: Add tests to run suspend without display Sujaritha Sundaresan
2024-07-30 13:54 ` ✓ CI.xeBAT: success for tests/intel: Add tests to run suspend without display (rev3) Patchwork
2024-07-30 14:08 ` ✗ Fi.CI.BAT: failure " Patchwork
2024-08-01  6:52   ` Sundaresan, Sujaritha
2024-08-01  8:12     ` Saarinen, Jani
2024-07-30 15:12 ` ✗ CI.xeFULL: " Patchwork
2024-08-01  8:09   ` Sundaresan, Sujaritha
2024-08-01  8:49 ` [PATCH i-g-t,v3] tests/intel: Add tests to run suspend without display Sundaresan, Sujaritha
2024-08-01  9:41 ` ✗ GitLab.Pipeline: warning for tests/intel: Add tests to run suspend without display (rev4) Patchwork
2024-08-01  9:56 ` ✓ CI.xeBAT: success " Patchwork
2024-08-01 10:11 ` ✓ Fi.CI.BAT: " Patchwork
2024-08-01 10:51 ` ✗ CI.xeFULL: failure " Patchwork
2024-08-01 11:45 ` [PATCH i-g-t, v3] tests/intel: Add tests to run suspend without display Kamil Konieczny
2024-08-06  6:20   ` Sundaresan, Sujaritha
2024-08-06 12:50     ` Kamil Konieczny
2024-08-09  9:04       ` Sundaresan, Sujaritha
2024-08-09 10:10         ` Kamil Konieczny
2024-08-09 11:42           ` Sundaresan, Sujaritha [this message]
2024-08-12 10:51             ` Sundaresan, Sujaritha
2024-08-09 10:58         ` Piecielska, Katarzyna
2024-08-09 11:41           ` Sundaresan, Sujaritha
2024-08-02  5:12 ` ✓ Fi.CI.IGT: success for tests/intel: Add tests to run suspend without display (rev4) 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=61358f2a-1739-499c-bb7f-572c469e7a45@intel.com \
    --to=sujaritha.sundaresan@intel.com \
    --cc=anshuman.gupta@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=kamil.konieczny@linux.intel.com \
    --cc=katarzyna.piecielska@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