diff mbox

[i-g-t] tests/kms_atomic: subtest atomic_invalid_params requires CRTC

Message ID 20170829103243.2662-1-marta.lofstedt@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Marta Lofstedt Aug. 29, 2017, 10:32 a.m. UTC
Check for valid crtc is missing in igt@kms_atomic@atomic_invalid_params.
This leads to segfault on machines where the subtest should be skipped.

Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>
---
 tests/kms_atomic.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Kahola, Mika Aug. 29, 2017, 10:49 a.m. UTC | #1
In my view, this is a valid check.

Reviewed-by: Mika Kahola <mika.kahola@intel.com>

On Tue, 2017-08-29 at 13:32 +0300, Marta Lofstedt wrote:
> Check for valid crtc is missing in igt@kms_atomic@atomic_invalid_para
> ms.
> This leads to segfault on machines where the subtest should be
> skipped.
> 
> Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>
> ---
>  tests/kms_atomic.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tests/kms_atomic.c b/tests/kms_atomic.c
> index d77a526f..042a7c26 100644
> --- a/tests/kms_atomic.c
> +++ b/tests/kms_atomic.c
> @@ -1596,6 +1596,7 @@ igt_main
>  		struct kms_atomic_connector_state *conn =
>  			find_connector(scratch, crtc);
>  
> +		igt_require(crtc);
>  		igt_require(plane);
>  		igt_require(conn);
>  		atomic_invalid_params(crtc, plane, conn);
Arkadiusz Hiler Aug. 30, 2017, 8:06 a.m. UTC | #2
On Tue, Aug 29, 2017 at 01:49:18PM +0300, Mika Kahola wrote:
> In my view, this is a valid check.
> 
> Reviewed-by: Mika Kahola <mika.kahola@intel.com>
> 
> On Tue, 2017-08-29 at 13:32 +0300, Marta Lofstedt wrote:
> > Check for valid crtc is missing in igt@kms_atomic@atomic_invalid_para
> > ms.
> > This leads to segfault on machines where the subtest should be
> > skipped.
> > 
> > Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>

pushed

thanks for the patch and the review :-)
diff mbox

Patch

diff --git a/tests/kms_atomic.c b/tests/kms_atomic.c
index d77a526f..042a7c26 100644
--- a/tests/kms_atomic.c
+++ b/tests/kms_atomic.c
@@ -1596,6 +1596,7 @@  igt_main
 		struct kms_atomic_connector_state *conn =
 			find_connector(scratch, crtc);
 
+		igt_require(crtc);
 		igt_require(plane);
 		igt_require(conn);
 		atomic_invalid_params(crtc, plane, conn);