[PATCH igt 1/9] drm/recovery: Wait for devcore to become available
Kamil Konieczny
kamil.konieczny at linux.intel.com
Tue Jul 1 15:58:03 UTC 2025
Hi Rob,
On 2025-06-30 at 11:08:55 -0700, Rob Clark wrote:
> From: Rob Clark <rob.clark at oss.qualcomm.com>
Please change subject, it is now:
[PATCH igt 1/9] drm/recovery: Wait for devcore to become available
and it should be:
[PATCH igt 1/9] tests/msm/msm_recovery: Wait for devcore to become available
or little shorter:
[PATCH igt 1/9] tests/msm/msm_recovery: Wait for devcore
After a resend I will ack it, I have also few nits for other
patches.
Regards,
Kamil
>
> The devcore could take some time to show up, so add a igt_wait() with
> timeout so we don't fail the test if the devcore is not immediately
> available.
>
> This addresses a source of flakeyness.
>
> Signed-off-by: Rob Clark <rob.clark at oss.qualcomm.com>
> ---
> tests/msm/msm_recovery.c | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/tests/msm/msm_recovery.c b/tests/msm/msm_recovery.c
> index fbe26e687ed3..433392079bd4 100644
> --- a/tests/msm/msm_recovery.c
> +++ b/tests/msm/msm_recovery.c
> @@ -44,8 +44,12 @@ read_and_clear_devcore(void)
> glob_t glob_buf = {0};
> int ret, fd;
>
> - ret = glob("/sys/class/devcoredump/devcd*/data", GLOB_NOSORT, NULL, &glob_buf);
> - if ((ret == GLOB_NOMATCH) || !glob_buf.gl_pathc)
> + /* The devcore shows up asynchronously, so it might not be
> + * immediately available:
> + */
> + if (!igt_wait(glob("/sys/class/devcoredump/devcd*/data",
> + GLOB_NOSORT, NULL, &glob_buf) != GLOB_NOMATCH,
> + 1000, 100))
> return;
>
> fd = open(glob_buf.gl_pathv[0], O_RDWR);
> --
> 2.50.0
>
More information about the igt-dev
mailing list