From: Jeremy Cline <jcline@redhat.com>
To: Lyude <lyude@redhat.com>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t v2 1/2] tests/kms_pipe_crc_basic: Use igt_display_require_output_on_pipe()
Date: Tue, 25 Aug 2020 15:13:00 -0400 [thread overview]
Message-ID: <20200825191300.GB274007@dev.jcline.org> (raw)
In-Reply-To: <20200818193528.986926-1-lyude@redhat.com>
On Tue, Aug 18, 2020 at 03:35:27PM -0400, Lyude wrote:
> From: Lyude Paul <lyude@redhat.com>
>
> v2: Rebase
>
> Signed-off-by: Lyude Paul <lyude@redhat.com>
> ---
It might be worth a short commit message body, something like "Refactor
tests_read_crc() to use igt_display_require_output_on_pipe() rather than
checking the validity of the pipe and output separately" maybe?
> tests/kms_pipe_crc_basic.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/tests/kms_pipe_crc_basic.c b/tests/kms_pipe_crc_basic.c
> index bb66bc6c..53d76df1 100644
> --- a/tests/kms_pipe_crc_basic.c
> +++ b/tests/kms_pipe_crc_basic.c
> @@ -65,15 +65,14 @@ static void test_bad_source(data_t *data)
> static void test_read_crc(data_t *data, enum pipe pipe, unsigned flags)
> {
> igt_display_t *display = &data->display;
> - igt_output_t *output = igt_get_single_output_for_pipe(display, pipe);
> + igt_output_t *output;
> igt_plane_t *primary;
> drmModeModeInfo *mode;
> igt_crc_t *crcs = NULL;
> int c, j;
>
> - igt_require_pipe(display, pipe);
> - igt_require_f(output, "No connector found for pipe %s\n",
> - kmstest_pipe_name(pipe));
> + igt_display_require_output_on_pipe(display, pipe);
> + output = igt_get_single_output_for_pipe(display, pipe);
>
> igt_display_reset(display);
> igt_output_set_pipe(output, pipe);
> --
> 2.26.2
>
Looks like a good refactor to me:
Reviewed-by: Jeremy Cline <jcline@redhat.com>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
prev parent reply other threads:[~2020-08-25 19:14 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-18 19:35 [igt-dev] [PATCH i-g-t v2 1/2] tests/kms_pipe_crc_basic: Use igt_display_require_output_on_pipe() Lyude
2020-08-18 19:35 ` [igt-dev] [PATCH i-g-t v2 2/2] tests/kms_pipe_crc_basic: Add disable-crc-after-crtc-pipe-* tests Lyude
2020-08-25 19:45 ` Jeremy Cline
2020-08-18 20:05 ` [igt-dev] ✗ Fi.CI.BAT: failure for series starting with [i-g-t,v2,1/2] tests/kms_pipe_crc_basic: Use igt_display_require_output_on_pipe() Patchwork
2020-08-18 20:40 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,v2,1/2] tests/kms_pipe_crc_basic: Use igt_display_require_output_on_pipe() (rev2) Patchwork
2020-08-19 0:46 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2020-08-25 19:13 ` Jeremy Cline [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200825191300.GB274007@dev.jcline.org \
--to=jcline@redhat.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=lyude@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox