[igt-dev] [PATCH i-g-t] tests/psr: Skip if PSR cannot be enabled for the current mode.
Dhinakaran Pandiyan
dhinakaran.pandiyan at intel.com
Wed Aug 1 19:05:46 UTC 2018
On Wed, 2018-08-01 at 09:59 +0100, Chris Wilson wrote:
> Quoting Dhinakaran Pandiyan (2018-08-01 07:43:23)
> > PSR tests on ICL fail waiting for PSR to become active, whereas the
> > driver does not enable it on the HW due to unmet timing
> > requirements
> > [ 482.485873] [drm:intel_dp_compute_config [i915]] PSR condition
> > failed: PSR setup time (330 us) too long
> > We should probably bring back the kernel patch that programmed an
> > alternate
> > mode, but skip tests for now.
> >
> > Cc: José Roberto de Souza <jose.souza at intel.com>
> > Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan at intel.com>
> > ---
> > tests/kms_psr.c | 12 +++++++++++-
> > 1 file changed, 11 insertions(+), 1 deletion(-)
> >
> > diff --git a/tests/kms_psr.c b/tests/kms_psr.c
> > index 218b3960..89118ad4 100644
> > --- a/tests/kms_psr.c
> > +++ b/tests/kms_psr.c
> > @@ -193,11 +193,19 @@ static bool sink_support(data_t *data)
> > char buf[512];
> >
> > igt_debugfs_read(data->drm_fd, "i915_edp_psr_status", buf);
> > -
> > return data->with_psr_disabled ||
> > strstr(buf, "Sink_Support: yes\n");
> > }
> >
> > +static bool mode_support(data_t *data)
> > +{
> > + char buf[512];
>
> For both of these, we don't even need to read debugfs if data-
> >with_psr_disabled.
Correct, will move the check ahead.
>
> > + igt_debugfs_read(data->drm_fd, "i915_edp_psr_status", buf);
>
> If you are reading the debugfs frequently, cache the debugfs dir
>
> data->debugfs = igt_debugfs_dir(data->drm_fd);
Didn't know we had a function to do this, thanks.
>
> Then use igt_sysfs_read(data->debugfs, "i915_edp_psr_status", buf,
> sizeof(buf));
>
> > + return data->with_psr_disabled ||
> > + strstr(buf, "Enabled: yes\n");
>
> Is there any delay before PSR is enabled?
Enabled should be set when modeset completes, so we shouldn't be
needing a delay. Not too sure how a non-blocking modeset would behave.
>
> We really should adopt yaml (mild background rant).
As a standard debugfs format?
> -Chris
More information about the igt-dev
mailing list