[Intel-gfx] [PATCH i-g-t 2/5] lib/igt_core: reserve long options for individual tests
Antonio Argenziano
antonio.argenziano at intel.com
Thu May 30 00:03:46 UTC 2019
On 29/05/19 16:27, Lucas De Marchi wrote:
> Start the core optiosn from 500 so the individual tests can have their
> own options starting from 0. This makes it easier to set the long
> options without conflicting.
>
> 500 is just a magic number, higher than any ascii char that could be
> used in the individual test.
>
> While at it, fix the coding style to use tab rather than space.
>
> Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>
Acked-by: Antonio Argenziano <antonio.argenziano at intel.com>
> ---
> lib/igt_core.c | 16 ++++++++++------
> 1 file changed, 10 insertions(+), 6 deletions(-)
>
> diff --git a/lib/igt_core.c b/lib/igt_core.c
> index 9c86d664..814f5c72 100644
> --- a/lib/igt_core.c
> +++ b/lib/igt_core.c
> @@ -280,12 +280,16 @@ int test_children_sz;
> bool test_child;
>
> enum {
> - OPT_LIST_SUBTESTS,
> - OPT_RUN_SUBTEST,
> - OPT_DESCRIPTION,
> - OPT_DEBUG,
> - OPT_INTERACTIVE_DEBUG,
> - OPT_HELP = 'h'
> + /*
> + * Let the first values be used by individual tests so options don't
> + * conflict with core ones
> + */
> + OPT_LIST_SUBTESTS = 500,
> + OPT_RUN_SUBTEST,
> + OPT_DESCRIPTION,
> + OPT_DEBUG,
> + OPT_INTERACTIVE_DEBUG,
> + OPT_HELP = 'h'
> };
>
> static int igt_exitcode = IGT_EXIT_SUCCESS;
>
More information about the Intel-gfx
mailing list