[PATCH i-g-t 2/2] tests/intel/kms_psr2_sf: Add checks for early transport

B, Jeevan jeevan.b at intel.com
Wed Jun 19 15:33:50 UTC 2024


> -----Original Message-----
> From: Hogander, Jouni <jouni.hogander at intel.com>
> Sent: Thursday, June 13, 2024 4:12 PM
> To: igt-dev at lists.freedesktop.org; B, Jeevan <jeevan.b at intel.com>
> Subject: Re: [PATCH i-g-t 2/2] tests/intel/kms_psr2_sf: Add checks for early
> transport
> 
> On Wed, 2024-06-12 at 16:36 +0530, Jeevan B wrote:
> > Add checks weather early transport if supported then we check if early
> > trasport is working.
> 
> Generally this patch looks ok to me. I'm not sure if better approach would be to
> modify psr_enable to accept PR_MODE_SEL_FETCH_ET and PSR_MODE_2_ET.
> When PR_MODE_SEL_FETCH or PSR_MODE_2 is given then it would set the Early
> Transport disable bit (0x20). This is how I was doing it for Panel Replay/PSR here:
> 
> https://patchwork.freedesktop.org/patch/598537/?series=133866&rev=2
> 
> What do you think?
Hmm AFAIK ET is enabled by default if available. So I don’t we should alter it.

BR, Jeevan B 
> 
> BR,
> 
> Jouni Högander
> 
> >
> > Signed-off-by: Jeevan B <jeevan.b at intel.com>
> > ---
> >  tests/intel/kms_psr2_sf.c | 18 +++++++++++++++++-
> >  1 file changed, 17 insertions(+), 1 deletion(-)
> >
> > diff --git a/tests/intel/kms_psr2_sf.c b/tests/intel/kms_psr2_sf.c
> > index 4c3e34aa0..e612b8266 100644
> > --- a/tests/intel/kms_psr2_sf.c
> > +++ b/tests/intel/kms_psr2_sf.c
> > @@ -168,6 +168,7 @@ typedef struct {
> >         igt_plane_t *test_plane;
> >         bool big_fb_test;
> >         bool fbc_flag;
> > +       bool et_flag;
> >         cairo_t *cr;
> >         uint32_t screen_changes;
> >         int cur_x, cur_y;
> > @@ -184,11 +185,23 @@ static bool
> > set_sel_fetch_mode_for_output(data_t *data)
> >  {
> >         bool supported = false;
> >
> > +       data->et_flag = false;
> > +
> >         if (psr_sink_support(data->drm_fd, data->debugfs_fd,
> > -                                                PR_MODE_SEL_FETCH,
> > data->output)) {
> > +
> > PR_MODE_SEL_FETCH_ET, data->output)) {
> > +               supported = true;
> > +               data->psr_mode = PR_MODE_SEL_FETCH;
> > +               data->et_flag = true;
> > +       } else if (psr_sink_support(data->drm_fd, data->debugfs_fd,
> > +                                                       PR_MODE_SEL_F
> > ETCH, data->output)) {
> >                 supported = true;
> >                 data->psr_mode = PR_MODE_SEL_FETCH;
> >         } else if (psr_sink_support(data->drm_fd, data->debugfs_fd,
> > +                                                       PSR_MODE_2_ET
> > , data->output)) {
> > +               supported = true;
> > +               data->psr_mode = PSR_MODE_2;
> > +               data->et_flag = true;
> > +       } else  if (psr_sink_support(data->drm_fd, data->debugfs_fd,
> >                                                           PSR_MODE_2,
> > data->output)) {
> >                 supported = true;
> >                 data->psr_mode = PSR_MODE_2; @@ -916,6 +929,9 @@
> > static void run(data_t *data)
> >                 igt_assert_f(intel_fbc_wait_until_enabled(data-
> > >drm_fd,
> >                                                           data-
> > >pipe),
> >                                                           "FBC still
> > disabled\n");
> > +       if (data->et_flag)
> > +               igt_assert_f(early_transport_check(data->debugfs_fd),
> > +                            "Early Trasport Disbaled\n");
> >
> >         data->screen_changes = 0;
> >



More information about the igt-dev mailing list