* [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE
@ 2019-02-20 14:24 Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling Daniel Vetter
` (4 more replies)
0 siblings, 5 replies; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 14:24 UTC (permalink / raw)
To: IGT development; +Cc: Daniel Vetter
Except in igt_simulation.c where we use tricks and intentionally only
want part of the array in some cases.
Suggested-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
lib/tests/igt_assert.c | 3 ++-
lib/tests/igt_exit_handler.c | 3 ++-
lib/tests/igt_fork.c | 3 ++-
lib/tests/igt_invalid_subtest_name.c | 5 +++--
lib/tests/igt_list_only.c | 2 +-
lib/tests/igt_no_exit.c | 4 ++--
lib/tests/igt_no_subtest.c | 2 +-
lib/tests/igt_segfault.c | 4 +---
8 files changed, 14 insertions(+), 12 deletions(-)
diff --git a/lib/tests/igt_assert.c b/lib/tests/igt_assert.c
index 632e15978978..1caf5d885ddb 100644
--- a/lib/tests/igt_assert.c
+++ b/lib/tests/igt_assert.c
@@ -34,6 +34,7 @@
#include <sys/wait.h>
#include "igt_core.h"
+#include "drmtest.h"
#include "igt_tests_common.h"
@@ -63,7 +64,7 @@ static int do_fork(void)
case -1:
internal_assert(0);
case 0:
- argc = 1;
+ argc = ARRAY_SIZE(argv_run);
igt_simple_init(argc, argv_run);
test_to_run();
igt_exit();
diff --git a/lib/tests/igt_exit_handler.c b/lib/tests/igt_exit_handler.c
index f8a747862c01..892a7f141e90 100644
--- a/lib/tests/igt_exit_handler.c
+++ b/lib/tests/igt_exit_handler.c
@@ -26,6 +26,7 @@
#include <sys/types.h>
#include <sys/wait.h>
#include "igt_core.h"
+#include "drmtest.h"
#include "igt_tests_common.h"
@@ -63,7 +64,7 @@ static int testfunc(enum test_type test_type)
{
char prog[] = "igt_no_exit";
char *fake_argv[] = {prog};
- int fake_argc = 1;
+ int fake_argc = ARRAY_SIZE(fake_argv);
pid_t pid;
int status;
char tmp = 0;
diff --git a/lib/tests/igt_fork.c b/lib/tests/igt_fork.c
index 100031207461..7e8b4f9b5477 100644
--- a/lib/tests/igt_fork.c
+++ b/lib/tests/igt_fork.c
@@ -30,6 +30,7 @@
#include <sys/wait.h>
#include "igt_core.h"
+#include "drmtest.h"
#include "igt_tests_common.h"
@@ -93,7 +94,7 @@ static int do_fork(void (*test_to_run)(void))
case -1:
internal_assert(0);
case 0:
- argc = 1;
+ argc = ARRAY_SIZE(argv_run);
igt_simple_init(argc, argv_run);
test_to_run();
igt_exit();
diff --git a/lib/tests/igt_invalid_subtest_name.c b/lib/tests/igt_invalid_subtest_name.c
index f962e0df0121..92e767abe06f 100644
--- a/lib/tests/igt_invalid_subtest_name.c
+++ b/lib/tests/igt_invalid_subtest_name.c
@@ -25,6 +25,7 @@
#include <sys/wait.h>
#include "igt_core.h"
+#include "drmtest.h"
#include "igt_tests_common.h"
@@ -32,7 +33,7 @@ static void invalid_subtest_name(void)
{
char prog[] = "igt_no_exit";
char *fake_argv[] = {prog};
- int fake_argc = 1;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
@@ -49,7 +50,7 @@ static void nonexisting_subtest(void)
char arg1[] = "--run-subtest";
char arg2[] = "invalid-subtest";
char *fake_argv[] = {prog, arg1, arg2};
- int fake_argc = 3;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
diff --git a/lib/tests/igt_list_only.c b/lib/tests/igt_list_only.c
index 65fa9da66362..b18d13d3ddef 100644
--- a/lib/tests/igt_list_only.c
+++ b/lib/tests/igt_list_only.c
@@ -32,7 +32,7 @@ int main(int argc, char **argv)
char prog[] = "igt_list_only";
char arg[] = "--list-subtests";
char *fake_argv[] = {prog, arg};
- int fake_argc = 2;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
diff --git a/lib/tests/igt_no_exit.c b/lib/tests/igt_no_exit.c
index 4a777412b6a9..82f00b5220b1 100644
--- a/lib/tests/igt_no_exit.c
+++ b/lib/tests/igt_no_exit.c
@@ -36,7 +36,7 @@ static void no_exit_list_only(void)
char prog[] = "igt_list_only";
char arg[] = "--list-subtests";
char *fake_argv[] = {prog, arg};
- int fake_argc = 2;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
@@ -48,7 +48,7 @@ static void no_exit(void)
{
char prog[] = "igt_no_exit";
char *fake_argv[] = {prog};
- int fake_argc = 1;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
diff --git a/lib/tests/igt_no_subtest.c b/lib/tests/igt_no_subtest.c
index 1ae62cfd8027..92e6c277e60b 100644
--- a/lib/tests/igt_no_subtest.c
+++ b/lib/tests/igt_no_subtest.c
@@ -31,7 +31,7 @@ int main(int argc, char **argv)
{
char prog[] = "igt_no_exit";
char *fake_argv[] = {prog};
- int fake_argc = 1;
+ int fake_argc = ARRAY_SIZE(fake_argv);
igt_subtest_init(fake_argc, fake_argv);
diff --git a/lib/tests/igt_segfault.c b/lib/tests/igt_segfault.c
index 2a24531aaa8c..0d872f67850a 100644
--- a/lib/tests/igt_segfault.c
+++ b/lib/tests/igt_segfault.c
@@ -65,15 +65,13 @@ static int do_fork(void)
case -1:
internal_assert(0);
case 0:
+ argc = ARRAY_SIZE(argv_run);
if (simple) {
- argc = 1;
igt_simple_init(argc, argv_run);
crashme();
igt_exit();
} else {
-
- argc = 1;
igt_subtest_init(argc, argv_run);
if(runa)
--
2.20.1
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply related [flat|nested] 11+ messages in thread* [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
@ 2019-02-20 14:24 ` Daniel Vetter
2019-02-20 14:31 ` Chris Wilson
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests Daniel Vetter
` (3 subsequent siblings)
4 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 14:24 UTC (permalink / raw)
To: IGT development; +Cc: Daniel Vetter
igt_fixture within an igt_simple_test don't really work as advertised.
Minimal fix, the testcase seems fairly questionable already ...
References: https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_222/fi-icl-y/igt@kms_mmap_write_crc.html
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
tests/kms_mmap_write_crc.c | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/tests/kms_mmap_write_crc.c b/tests/kms_mmap_write_crc.c
index 93c96ef4de08..bf2b0c2991b3 100644
--- a/tests/kms_mmap_write_crc.c
+++ b/tests/kms_mmap_write_crc.c
@@ -268,7 +268,8 @@ static data_t data;
int main(int argc, char **argv)
{
int i;
- igt_simple_init_parse_opts(&argc, argv, "n", NULL, NULL, opt_handler, NULL);
+ igt_subtest_init_parse_opts(&argc, argv, "n", NULL, NULL,
+ opt_handler, NULL);
igt_skip_on_simulation();
@@ -286,10 +287,12 @@ int main(int argc, char **argv)
fork_cpuhog_helper();
}
- igt_info("Using %d rounds for the test\n", ROUNDS);
+ igt_subtest("main") {
+ igt_info("Using %d rounds for the test\n", ROUNDS);
- for (i = 0; i < ROUNDS; i++)
- run_test(&data);
+ for (i = 0; i < ROUNDS; i++)
+ run_test(&data);
+ }
igt_fixture {
igt_display_fini(&data.display);
--
2.20.1
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply related [flat|nested] 11+ messages in thread* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling Daniel Vetter
@ 2019-02-20 14:31 ` Chris Wilson
2019-02-20 23:44 ` Daniel Vetter
0 siblings, 1 reply; 11+ messages in thread
From: Chris Wilson @ 2019-02-20 14:31 UTC (permalink / raw)
To: Daniel Vetter, IGT development; +Cc: Daniel Vetter
Quoting Daniel Vetter (2019-02-20 14:24:48)
> igt_fixture within an igt_simple_test don't really work as advertised.
>
> Minimal fix, the testcase seems fairly questionable already ...
Definitely; it was written to reproduce a specific setup and demonstrate
an issue with forgetting to sync, or soemthing like that. Maarten
hopefully knows whether this can be simply subsumed into one of our
other tests. It's just the use of a cpu_hog stands out; though really it
wants a memory_hog? for that extra bit of cache pressure. That might be
useful to generalise in our other coherency sensitive tests.
> References: https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_222/fi-icl-y/igt@kms_mmap_write_crc.html
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> ---
> tests/kms_mmap_write_crc.c | 11 +++++++----
> 1 file changed, 7 insertions(+), 4 deletions(-)
>
> diff --git a/tests/kms_mmap_write_crc.c b/tests/kms_mmap_write_crc.c
> index 93c96ef4de08..bf2b0c2991b3 100644
> --- a/tests/kms_mmap_write_crc.c
> +++ b/tests/kms_mmap_write_crc.c
> @@ -268,7 +268,8 @@ static data_t data;
> int main(int argc, char **argv)
> {
> int i;
> - igt_simple_init_parse_opts(&argc, argv, "n", NULL, NULL, opt_handler, NULL);
> + igt_subtest_init_parse_opts(&argc, argv, "n", NULL, NULL,
> + opt_handler, NULL);
>
> igt_skip_on_simulation();
>
> @@ -286,10 +287,12 @@ int main(int argc, char **argv)
> fork_cpuhog_helper();
> }
>
> - igt_info("Using %d rounds for the test\n", ROUNDS);
> + igt_subtest("main") {
> + igt_info("Using %d rounds for the test\n", ROUNDS);
>
> - for (i = 0; i < ROUNDS; i++)
> - run_test(&data);
> + for (i = 0; i < ROUNDS; i++)
> + run_test(&data);
> + }
Ok, that was much simpler than I feared. I started by ripping out the
parse_opts :)
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread* Re: [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling
2019-02-20 14:31 ` Chris Wilson
@ 2019-02-20 23:44 ` Daniel Vetter
0 siblings, 0 replies; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 23:44 UTC (permalink / raw)
To: Chris Wilson; +Cc: IGT development, Daniel Vetter
On Wed, Feb 20, 2019 at 02:31:21PM +0000, Chris Wilson wrote:
> Quoting Daniel Vetter (2019-02-20 14:24:48)
> > igt_fixture within an igt_simple_test don't really work as advertised.
> >
> > Minimal fix, the testcase seems fairly questionable already ...
>
> Definitely; it was written to reproduce a specific setup and demonstrate
> an issue with forgetting to sync, or soemthing like that. Maarten
> hopefully knows whether this can be simply subsumed into one of our
> other tests. It's just the use of a cpu_hog stands out; though really it
> wants a memory_hog? for that extra bit of cache pressure. That might be
> useful to generalise in our other coherency sensitive tests.
>
> > References: https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_222/fi-icl-y/igt@kms_mmap_write_crc.html
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> > ---
> > tests/kms_mmap_write_crc.c | 11 +++++++----
> > 1 file changed, 7 insertions(+), 4 deletions(-)
> >
> > diff --git a/tests/kms_mmap_write_crc.c b/tests/kms_mmap_write_crc.c
> > index 93c96ef4de08..bf2b0c2991b3 100644
> > --- a/tests/kms_mmap_write_crc.c
> > +++ b/tests/kms_mmap_write_crc.c
> > @@ -268,7 +268,8 @@ static data_t data;
> > int main(int argc, char **argv)
> > {
> > int i;
> > - igt_simple_init_parse_opts(&argc, argv, "n", NULL, NULL, opt_handler, NULL);
> > + igt_subtest_init_parse_opts(&argc, argv, "n", NULL, NULL,
> > + opt_handler, NULL);
> >
> > igt_skip_on_simulation();
> >
> > @@ -286,10 +287,12 @@ int main(int argc, char **argv)
> > fork_cpuhog_helper();
> > }
> >
> > - igt_info("Using %d rounds for the test\n", ROUNDS);
> > + igt_subtest("main") {
> > + igt_info("Using %d rounds for the test\n", ROUNDS);
> >
> > - for (i = 0; i < ROUNDS; i++)
> > - run_test(&data);
> > + for (i = 0; i < ROUNDS; i++)
> > + run_test(&data);
> > + }
>
> Ok, that was much simpler than I feared. I started by ripping out the
> parse_opts :)
Yeah occasionally it pays of to be a minimalist :-)
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Thanks for taking a look, merged.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread
* [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling Daniel Vetter
@ 2019-02-20 14:24 ` Daniel Vetter
2019-02-20 14:51 ` Arkadiusz Hiler
2019-02-20 15:00 ` [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Arkadiusz Hiler
` (2 subsequent siblings)
4 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 14:24 UTC (permalink / raw)
To: IGT development; +Cc: Daniel Vetter
They don't work, see igt_can_fail(). We already check for
test_with_subtests in igt_subtest.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
lib/igt_core.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/igt_core.c b/lib/igt_core.c
index 71b05d3bbd3b..6eb4798e24ef 100644
--- a/lib/igt_core.c
+++ b/lib/igt_core.c
@@ -463,6 +463,7 @@ uint64_t igt_nsec_elapsed(struct timespec *start)
bool __igt_fixture(void)
{
assert(!in_fixture);
+ assert(test_with_subtests);
if (igt_only_list_subtests())
return false;
@@ -975,6 +976,8 @@ bool igt_only_list_subtests(void)
void __igt_subtest_group_save(int *save)
{
+ assert(test_with_subtests);
+
*save = skip_subtests_henceforth;
}
--
2.20.1
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply related [flat|nested] 11+ messages in thread* Re: [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests Daniel Vetter
@ 2019-02-20 14:51 ` Arkadiusz Hiler
2019-02-20 23:41 ` Daniel Vetter
0 siblings, 1 reply; 11+ messages in thread
From: Arkadiusz Hiler @ 2019-02-20 14:51 UTC (permalink / raw)
To: Daniel Vetter; +Cc: IGT development, Daniel Vetter
On Wed, Feb 20, 2019 at 03:24:49PM +0100, Daniel Vetter wrote:
> They don't work, see igt_can_fail(). We already check for
> test_with_subtests in igt_subtest.
>
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests
2019-02-20 14:51 ` Arkadiusz Hiler
@ 2019-02-20 23:41 ` Daniel Vetter
0 siblings, 0 replies; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 23:41 UTC (permalink / raw)
To: Arkadiusz Hiler; +Cc: IGT development, Daniel Vetter
On Wed, Feb 20, 2019 at 04:51:22PM +0200, Arkadiusz Hiler wrote:
> On Wed, Feb 20, 2019 at 03:24:49PM +0100, Daniel Vetter wrote:
> > They don't work, see igt_can_fail(). We already check for
> > test_with_subtests in igt_subtest.
> >
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
CI found another offender, I'll need to do another patch.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests Daniel Vetter
@ 2019-02-20 15:00 ` Arkadiusz Hiler
2019-02-20 23:38 ` Daniel Vetter
2019-02-20 15:14 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
2019-02-20 17:46 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
4 siblings, 1 reply; 11+ messages in thread
From: Arkadiusz Hiler @ 2019-02-20 15:00 UTC (permalink / raw)
To: Daniel Vetter; +Cc: IGT development, Daniel Vetter
On Wed, Feb 20, 2019 at 03:24:47PM +0100, Daniel Vetter wrote:
> Except in igt_simulation.c where we use tricks and intentionally only
> want part of the array in some cases.
>
> Suggested-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> ---
> lib/tests/igt_assert.c | 3 ++-
> lib/tests/igt_exit_handler.c | 3 ++-
> lib/tests/igt_fork.c | 3 ++-
> lib/tests/igt_invalid_subtest_name.c | 5 +++--
> lib/tests/igt_list_only.c | 2 +-
> lib/tests/igt_no_exit.c | 4 ++--
> lib/tests/igt_no_subtest.c | 2 +-
> lib/tests/igt_segfault.c | 4 +---
> 8 files changed, 14 insertions(+), 12 deletions(-)
>
> diff --git a/lib/tests/igt_assert.c b/lib/tests/igt_assert.c
> index 632e15978978..1caf5d885ddb 100644
> --- a/lib/tests/igt_assert.c
> +++ b/lib/tests/igt_assert.c
> @@ -34,6 +34,7 @@
> #include <sys/wait.h>
>
> #include "igt_core.h"
> +#include "drmtest.h"
It may be worth moving that macro somewhere else.
ctags show me about 10 spearate definitions across the codebase.
But that's another cleanup.
> diff --git a/lib/tests/igt_segfault.c b/lib/tests/igt_segfault.c
> index 2a24531aaa8c..0d872f67850a 100644
> --- a/lib/tests/igt_segfault.c
> +++ b/lib/tests/igt_segfault.c
> @@ -65,15 +65,13 @@ static int do_fork(void)
> case -1:
> internal_assert(0);
> case 0:
> + argc = ARRAY_SIZE(argv_run);
> if (simple) {
> - argc = 1;
> igt_simple_init(argc, argv_run);
> crashme();
>
> igt_exit();
> } else {
> -
> - argc = 1;
> igt_subtest_init(argc, argv_run);
>
igt_simple_init(ARRAY_SIZE(argv_run), argv_run);
may indeed be a bit much.
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread* Re: [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE
2019-02-20 15:00 ` [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Arkadiusz Hiler
@ 2019-02-20 23:38 ` Daniel Vetter
0 siblings, 0 replies; 11+ messages in thread
From: Daniel Vetter @ 2019-02-20 23:38 UTC (permalink / raw)
To: Arkadiusz Hiler; +Cc: IGT development, Daniel Vetter
On Wed, Feb 20, 2019 at 05:00:11PM +0200, Arkadiusz Hiler wrote:
> On Wed, Feb 20, 2019 at 03:24:47PM +0100, Daniel Vetter wrote:
> > Except in igt_simulation.c where we use tricks and intentionally only
> > want part of the array in some cases.
> >
> > Suggested-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> > Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> > ---
> > lib/tests/igt_assert.c | 3 ++-
> > lib/tests/igt_exit_handler.c | 3 ++-
> > lib/tests/igt_fork.c | 3 ++-
> > lib/tests/igt_invalid_subtest_name.c | 5 +++--
> > lib/tests/igt_list_only.c | 2 +-
> > lib/tests/igt_no_exit.c | 4 ++--
> > lib/tests/igt_no_subtest.c | 2 +-
> > lib/tests/igt_segfault.c | 4 +---
> > 8 files changed, 14 insertions(+), 12 deletions(-)
> >
> > diff --git a/lib/tests/igt_assert.c b/lib/tests/igt_assert.c
> > index 632e15978978..1caf5d885ddb 100644
> > --- a/lib/tests/igt_assert.c
> > +++ b/lib/tests/igt_assert.c
> > @@ -34,6 +34,7 @@
> > #include <sys/wait.h>
> >
> > #include "igt_core.h"
> > +#include "drmtest.h"
>
> It may be worth moving that macro somewhere else.
> ctags show me about 10 spearate definitions across the codebase.
>
> But that's another cleanup.
Yeah I looked at git grep ARRAY_SIZE too, and the macro feels a bit
misplayed. But then got lazy :-)
>
> > diff --git a/lib/tests/igt_segfault.c b/lib/tests/igt_segfault.c
> > index 2a24531aaa8c..0d872f67850a 100644
> > --- a/lib/tests/igt_segfault.c
> > +++ b/lib/tests/igt_segfault.c
> > @@ -65,15 +65,13 @@ static int do_fork(void)
> > case -1:
> > internal_assert(0);
> > case 0:
> > + argc = ARRAY_SIZE(argv_run);
> > if (simple) {
> > - argc = 1;
> > igt_simple_init(argc, argv_run);
> > crashme();
> >
> > igt_exit();
> > } else {
> > -
> > - argc = 1;
> > igt_subtest_init(argc, argv_run);
> >
>
> igt_simple_init(ARRAY_SIZE(argv_run), argv_run);
> may indeed be a bit much.
Because macro magic doesn't actually work, or something like that.
igt_subtest_init has a &argc which goes boom :-)
> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Thanks for your review, applied.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread
* [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] lib/tests: Use ARRAY_SIZE
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
` (2 preceding siblings ...)
2019-02-20 15:00 ` [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Arkadiusz Hiler
@ 2019-02-20 15:14 ` Patchwork
2019-02-20 17:46 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
4 siblings, 0 replies; 11+ messages in thread
From: Patchwork @ 2019-02-20 15:14 UTC (permalink / raw)
To: igt-dev
== Series Details ==
Series: series starting with [i-g-t,1/3] lib/tests: Use ARRAY_SIZE
URL : https://patchwork.freedesktop.org/series/56963/
State : success
== Summary ==
CI Bug Log - changes from IGT_4844 -> IGTPW_2456
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://patchwork.freedesktop.org/api/1.0/series/56963/revisions/1/mbox/
Known issues
------------
Here are the changes found in IGTPW_2456 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@amdgpu/amd_basic@userptr:
- fi-kbl-8809g: PASS -> DMESG-WARN [fdo#108965]
* igt@amdgpu/amd_cs_nop@fork-compute0:
- fi-blb-e6850: NOTRUN -> SKIP [fdo#109271] +17
* igt@gem_exec_basic@readonly-bsd2:
- fi-pnv-d510: NOTRUN -> SKIP [fdo#109271] +71
* igt@kms_busy@basic-flip-c:
- fi-pnv-d510: NOTRUN -> SKIP [fdo#109271] / [fdo#109278]
* igt@kms_pipe_crc_basic@hang-read-crc-pipe-b:
- fi-byt-clapper: PASS -> FAIL [fdo#103191] / [fdo#107362]
* igt@kms_pipe_crc_basic@read-crc-pipe-a:
- fi-byt-clapper: PASS -> FAIL [fdo#107362]
* igt@runner@aborted:
- fi-apl-guc: NOTRUN -> FAIL [fdo#108622]
#### Possible fixes ####
* igt@i915_module_load@reload:
- fi-blb-e6850: INCOMPLETE [fdo#107718] -> PASS
* igt@kms_busy@basic-flip-b:
- fi-gdg-551: FAIL [fdo#103182] -> PASS
* igt@kms_pipe_crc_basic@suspend-read-crc-pipe-b:
- fi-byt-clapper: FAIL [fdo#103191] / [fdo#107362] -> PASS
[fdo#103182]: https://bugs.freedesktop.org/show_bug.cgi?id=103182
[fdo#103191]: https://bugs.freedesktop.org/show_bug.cgi?id=103191
[fdo#107362]: https://bugs.freedesktop.org/show_bug.cgi?id=107362
[fdo#107718]: https://bugs.freedesktop.org/show_bug.cgi?id=107718
[fdo#108622]: https://bugs.freedesktop.org/show_bug.cgi?id=108622
[fdo#108965]: https://bugs.freedesktop.org/show_bug.cgi?id=108965
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109278]: https://bugs.freedesktop.org/show_bug.cgi?id=109278
Participating hosts (46 -> 41)
------------------------------
Additional (1): fi-pnv-d510
Missing (6): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-bdw-samus
Build changes
-------------
* IGT: IGT_4844 -> IGTPW_2456
CI_DRM_5636: b33b7e4ffb889d3d3e03ad9b64d0fe15dd2184b4 @ git://anongit.freedesktop.org/gfx-ci/linux
IGTPW_2456: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2456/
IGT_4844: ee6e006202a50c5aef373c0b075027ed7177935a @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
== Testlist changes ==
+igt@kms_mmap_write_crc@main
-igt@kms_mmap_write_crc
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2456/
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread* [igt-dev] ✗ Fi.CI.IGT: failure for series starting with [i-g-t,1/3] lib/tests: Use ARRAY_SIZE
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
` (3 preceding siblings ...)
2019-02-20 15:14 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
@ 2019-02-20 17:46 ` Patchwork
4 siblings, 0 replies; 11+ messages in thread
From: Patchwork @ 2019-02-20 17:46 UTC (permalink / raw)
To: igt-dev
== Series Details ==
Series: series starting with [i-g-t,1/3] lib/tests: Use ARRAY_SIZE
URL : https://patchwork.freedesktop.org/series/56963/
State : failure
== Summary ==
CI Bug Log - changes from IGT_4844_full -> IGTPW_2456_full
====================================================
Summary
-------
**FAILURE**
Serious unknown changes coming with IGTPW_2456_full absolutely need to be
verified manually.
If you think the reported changes have nothing to do with the changes
introduced in IGTPW_2456_full, please notify your bug team to allow them
to document this new failure mode, which will reduce false positives in CI.
External URL: https://patchwork.freedesktop.org/api/1.0/series/56963/revisions/1/mbox/
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in IGTPW_2456_full:
### IGT changes ###
#### Possible regressions ####
* igt@kms_pwrite_crc:
- shard-kbl: PASS -> FAIL
- shard-apl: PASS -> FAIL
- shard-glk: PASS -> FAIL
- shard-snb: PASS -> FAIL
- shard-hsw: PASS -> FAIL
New tests
---------
New tests have been introduced between IGT_4844_full and IGTPW_2456_full:
### New IGT tests (1) ###
* igt@kms_mmap_write_crc@main:
- Statuses : 5 pass(s)
- Exec time: [3.27, 5.19] s
Known issues
------------
Here are the changes found in IGTPW_2456_full that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_exec_schedule@preempt-other-chain-blt:
- shard-snb: NOTRUN -> SKIP [fdo#109271] +170
* igt@gem_softpin@noreloc-s3:
- shard-snb: PASS -> DMESG-WARN [fdo#102365]
* igt@kms_atomic_transition@3x-modeset-transitions-nonblocking-fencing:
- shard-kbl: NOTRUN -> SKIP [fdo#109271] / [fdo#109278]
* igt@kms_busy@basic-modeset-f:
- shard-glk: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +2
* igt@kms_busy@extended-modeset-hang-newfb-render-a:
- shard-hsw: NOTRUN -> DMESG-WARN [fdo#107956]
* igt@kms_busy@extended-modeset-hang-newfb-with-reset-render-b:
- shard-snb: NOTRUN -> DMESG-WARN [fdo#107956]
* igt@kms_busy@extended-pageflip-modeset-hang-oldfb-render-a:
- shard-glk: NOTRUN -> DMESG-WARN [fdo#107956]
* igt@kms_busy@extended-pageflip-modeset-hang-oldfb-render-d:
- shard-apl: NOTRUN -> SKIP [fdo#109271] / [fdo#109278]
* igt@kms_ccs@pipe-b-crc-sprite-planes-basic:
- shard-kbl: PASS -> FAIL [fdo#107725] / [fdo#108145]
* igt@kms_color@pipe-a-ctm-max:
- shard-glk: NOTRUN -> FAIL [fdo#108147]
* igt@kms_cursor_crc@cursor-128x128-onscreen:
- shard-apl: NOTRUN -> FAIL [fdo#103232]
* igt@kms_cursor_crc@cursor-256x256-sliding:
- shard-glk: NOTRUN -> FAIL [fdo#103232]
* igt@kms_cursor_crc@cursor-256x256-suspend:
- shard-apl: PASS -> FAIL [fdo#103191] / [fdo#103232]
* igt@kms_cursor_crc@cursor-64x21-random:
- shard-apl: PASS -> FAIL [fdo#103232] +1
* igt@kms_cursor_crc@cursor-alpha-opaque:
- shard-apl: PASS -> FAIL [fdo#109350]
* igt@kms_cursor_legacy@2x-long-nonblocking-modeset-vs-cursor-atomic:
- shard-glk: NOTRUN -> FAIL [fdo#105454]
* igt@kms_flip@2x-flip-vs-expired-vblank:
- shard-glk: PASS -> FAIL [fdo#105363] +1
* igt@kms_flip@2x-plain-flip-ts-check:
- shard-apl: NOTRUN -> SKIP [fdo#109271] +18
* igt@kms_flip@flip-vs-fences:
- shard-glk: PASS -> INCOMPLETE [fdo#103359] / [k.org#198133]
* igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-draw-mmap-cpu:
- shard-glk: PASS -> FAIL [fdo#103167] +6
* igt@kms_frontbuffer_tracking@psr-1p-offscren-pri-indfb-draw-mmap-wc:
- shard-kbl: NOTRUN -> SKIP [fdo#109271] +23
* igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-blt:
- shard-hsw: NOTRUN -> SKIP [fdo#109271] +51
* igt@kms_frontbuffer_tracking@psr-2p-scndscrn-shrfb-msflip-blt:
- shard-glk: NOTRUN -> SKIP [fdo#109271] +31
* igt@kms_plane@plane-position-covered-pipe-a-planes:
- shard-apl: PASS -> FAIL [fdo#103166] +1
* igt@kms_plane_alpha_blend@pipe-c-alpha-opaque-fb:
- shard-snb: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +23
* igt@kms_plane_alpha_blend@pipe-c-constant-alpha-max:
- shard-glk: PASS -> FAIL [fdo#108145]
* igt@kms_plane_alpha_blend@pipe-c-coverage-7efc:
- shard-hsw: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +2
* igt@kms_setmode@basic:
- shard-apl: PASS -> FAIL [fdo#99912]
* igt@kms_universal_plane@universal-plane-pipe-c-functional:
- shard-glk: PASS -> FAIL [fdo#103166] +4
* igt@kms_vblank@pipe-b-ts-continuation-modeset-hang:
- shard-apl: PASS -> FAIL [fdo#104894] +2
#### Possible fixes ####
* igt@i915_pm_rpm@system-suspend:
- shard-kbl: INCOMPLETE [fdo#103665] / [fdo#107807] -> PASS
* igt@kms_atomic_transition@plane-all-modeset-transition:
- shard-kbl: INCOMPLETE [fdo#103665] -> PASS
* igt@kms_atomic_transition@plane-all-modeset-transition-fencing:
- shard-apl: INCOMPLETE [fdo#103927] -> PASS +1
* igt@kms_color@pipe-b-ctm-max:
- shard-apl: FAIL [fdo#108147] -> PASS
* igt@kms_color@pipe-c-legacy-gamma:
- shard-apl: FAIL [fdo#104782] -> PASS
* igt@kms_cursor_crc@cursor-128x128-random:
- shard-apl: FAIL [fdo#103232] -> PASS +4
* igt@kms_cursor_crc@cursor-128x128-suspend:
- shard-kbl: FAIL [fdo#103191] / [fdo#103232] -> PASS
* igt@kms_cursor_crc@cursor-64x64-onscreen:
- shard-kbl: FAIL [fdo#103232] -> PASS
* igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-onoff:
- shard-glk: FAIL [fdo#103167] -> PASS +2
* igt@kms_plane@pixel-format-pipe-a-planes-source-clamping:
- shard-glk: FAIL [fdo#108948] -> PASS
* igt@kms_plane@plane-position-covered-pipe-c-planes:
- shard-apl: FAIL [fdo#103166] -> PASS +1
- shard-kbl: FAIL [fdo#103166] -> PASS
* igt@kms_plane_multiple@atomic-pipe-b-tiling-y:
- shard-glk: FAIL [fdo#103166] -> PASS +2
* igt@kms_vblank@pipe-b-ts-continuation-dpms-rpm:
- shard-kbl: FAIL [fdo#104894] -> PASS
[fdo#102365]: https://bugs.freedesktop.org/show_bug.cgi?id=102365
[fdo#103166]: https://bugs.freedesktop.org/show_bug.cgi?id=103166
[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#103191]: https://bugs.freedesktop.org/show_bug.cgi?id=103191
[fdo#103232]: https://bugs.freedesktop.org/show_bug.cgi?id=103232
[fdo#103359]: https://bugs.freedesktop.org/show_bug.cgi?id=103359
[fdo#103665]: https://bugs.freedesktop.org/show_bug.cgi?id=103665
[fdo#103927]: https://bugs.freedesktop.org/show_bug.cgi?id=103927
[fdo#104782]: https://bugs.freedesktop.org/show_bug.cgi?id=104782
[fdo#104894]: https://bugs.freedesktop.org/show_bug.cgi?id=104894
[fdo#105363]: https://bugs.freedesktop.org/show_bug.cgi?id=105363
[fdo#105454]: https://bugs.freedesktop.org/show_bug.cgi?id=105454
[fdo#107725]: https://bugs.freedesktop.org/show_bug.cgi?id=107725
[fdo#107807]: https://bugs.freedesktop.org/show_bug.cgi?id=107807
[fdo#107956]: https://bugs.freedesktop.org/show_bug.cgi?id=107956
[fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
[fdo#108147]: https://bugs.freedesktop.org/show_bug.cgi?id=108147
[fdo#108948]: https://bugs.freedesktop.org/show_bug.cgi?id=108948
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109278]: https://bugs.freedesktop.org/show_bug.cgi?id=109278
[fdo#109350]: https://bugs.freedesktop.org/show_bug.cgi?id=109350
[fdo#99912]: https://bugs.freedesktop.org/show_bug.cgi?id=99912
[k.org#198133]: https://bugzilla.kernel.org/show_bug.cgi?id=198133
Participating hosts (7 -> 5)
------------------------------
Missing (2): shard-skl shard-iclb
Build changes
-------------
* IGT: IGT_4844 -> IGTPW_2456
CI_DRM_5636: b33b7e4ffb889d3d3e03ad9b64d0fe15dd2184b4 @ git://anongit.freedesktop.org/gfx-ci/linux
IGTPW_2456: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2456/
IGT_4844: ee6e006202a50c5aef373c0b075027ed7177935a @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2456/
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2019-02-20 23:45 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-20 14:24 [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 2/3] tests/kms_mmap_write_crc: Fix igt_fixture handling Daniel Vetter
2019-02-20 14:31 ` Chris Wilson
2019-02-20 23:44 ` Daniel Vetter
2019-02-20 14:24 ` [igt-dev] [PATCH i-g-t 3/3] lib: disallow fixtures/subtest groups in simple tests Daniel Vetter
2019-02-20 14:51 ` Arkadiusz Hiler
2019-02-20 23:41 ` Daniel Vetter
2019-02-20 15:00 ` [igt-dev] [PATCH i-g-t 1/3] lib/tests: Use ARRAY_SIZE Arkadiusz Hiler
2019-02-20 23:38 ` Daniel Vetter
2019-02-20 15:14 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/3] " Patchwork
2019-02-20 17:46 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox