[PATCH i-g-t 2/4] tests/kms_content_protection: Move try commit call
Kandpal, Suraj
suraj.kandpal at intel.com
Mon Aug 19 05:18:52 UTC 2024
> -----Original Message-----
> From: B, Jeevan <jeevan.b at intel.com>
> Sent: Monday, August 19, 2024 10:35 AM
> To: Kandpal, Suraj <suraj.kandpal at intel.com>; igt-dev at lists.freedesktop.org
> Cc: Samala, Pranay <pranay.samala at intel.com>; Nautiyal, Ankit K
> <ankit.k.nautiyal at intel.com>; Kandpal, Suraj <suraj.kandpal at intel.com>
> Subject: RE: [PATCH i-g-t 2/4] tests/kms_content_protection: Move try
> commit call
>
> > -----Original Message-----
> > From: igt-dev <igt-dev-bounces at lists.freedesktop.org> On Behalf Of
> > Suraj Kandpal
> > Sent: Tuesday, August 13, 2024 9:50 AM
> > To: igt-dev at lists.freedesktop.org
> > Cc: Samala, Pranay <pranay.samala at intel.com>; Nautiyal, Ankit K
> > <ankit.k.nautiyal at intel.com>; Kandpal, Suraj <suraj.kandpal at intel.com>
> > Subject: [PATCH i-g-t 2/4] tests/kms_content_protection: Move try
> > commit call
> >
> > Currently we are calling try commit twice once in if condition and
> > again right after that. The correct sequence should be we call try
> > commit again only if the first one fails.
> >
> > Signed-off-by: Suraj Kandpal <suraj.kandpal at intel.com>
> > ---
> > tests/kms_content_protection.c | 6 +++---
> > 1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/tests/kms_content_protection.c
> > b/tests/kms_content_protection.c index 6bd744351..db6dc17b1 100644
> > --- a/tests/kms_content_protection.c
> > +++ b/tests/kms_content_protection.c
> > @@ -679,10 +679,10 @@ test_content_protection_mst(int content_type)
> >
> > for (count = 0; count < valid_outputs; count++)
> >
> > prepare_modeset_on_mst_output(hdcp_mst_output[count]);
> > - }
> >
> > - ret = igt_display_try_commit2(display, COMMIT_ATOMIC);
> > - igt_require_f(ret == 0, "Commit failure during MST modeset\n");
> Sequence change doesn't looks correct please reverify.
This is actually the correct sequence currently what was happening was that even if the try commit call inside the if statement passed
We would still end up doing a try commit again what er actually want is that if the try commit in the condition prior to this fails
We adjust the params and then do a new try commit call.
Ankit maybe you can confirm this behaviour.
Regards,
Suraj Kandpal
> > + ret = igt_display_try_commit2(display, COMMIT_ATOMIC);
> > + igt_require_f(ret == 0, "Commit failure during MST
> modeset\n");
> > + }
> >
> > for (count = 0; count < valid_outputs; count++) {
> > igt_output_set_prop_value(hdcp_mst_output[count],
> > IGT_CONNECTOR_CONTENT_PROTECTION, CP_DESIRED);
> > --
> > 2.43.2
More information about the igt-dev
mailing list