From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
To: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>,
Petri Latvala <petri.latvala@intel.com>,
Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: igt-dev@lists.freedesktop.org, intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [igt-dev] [PATCH i-g-t 7/7] kms_flip: Standardize return value for fb_is_bound
Date: Wed, 6 Mar 2019 12:25:30 +0100 [thread overview]
Message-ID: <7c52359d-89ba-d6a1-b812-7060d89ef42b@linux.intel.com> (raw)
In-Reply-To: <f721ca0d8367607136e076b1870c4cbcbecb8848.1551712108.git.rodrigosiqueiramelo@gmail.com>
Op 04-03-2019 om 16:32 schreef Rodrigo Siqueira:
> The function fb_is_bound() mix integer value with booleans for handling
> the return value. This commit standardizes the return value of
> fb_is_bound() for using only booleans.
>
> Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>
> ---
> tests/kms_flip.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/tests/kms_flip.c b/tests/kms_flip.c
> index de3ab600..abfdd363 100755
> --- a/tests/kms_flip.c
> +++ b/tests/kms_flip.c
> @@ -947,8 +947,7 @@ static void paint_flip_mode(struct igt_fb *fb, bool odd_frame)
> igt_put_cairo_ctx(drm_fd, fb, cr);
> }
>
> -static int
> -fb_is_bound(struct test_output *o, int fb)
> +static bool fb_is_bound(struct test_output *o, int fb)
> {
> int n;
>
> @@ -958,7 +957,7 @@ fb_is_bound(struct test_output *o, int fb)
> };
>
> if (drmIoctl(drm_fd, DRM_IOCTL_MODE_GETCRTC, &mode))
> - return 0;
> + return false;
>
> if (!mode.mode_valid || mode.fb_id != fb)
> return false;
>
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev
Nice cleanup. Hope we can eventually convert kms_flip to igt_display at some point for readability.
For all except patch 4:
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
:)
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2019-03-06 11:25 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-04 15:29 [igt-dev] [PATCH i-g-t 0/7] kms_flip: cleanups Rodrigo Siqueira
2019-03-04 15:29 ` [igt-dev] [PATCH i-g-t 1/7] kms_flip: Removes unreachable code related to TEST_RPM Rodrigo Siqueira
2019-03-04 15:30 ` [igt-dev] [PATCH i-g-t 2/7] kms_flip: Removes unreachable code related to TEST_TS_CONT Rodrigo Siqueira
2019-03-04 15:30 ` [igt-dev] [PATCH i-g-t 3/7] kms_flip: Fix warning related to i915 gem dependence Rodrigo Siqueira
2019-03-04 15:30 ` [igt-dev] [PATCH i-g-t 4/7] kms_flip: Remove unreachable condition in wait_for_events Rodrigo Siqueira
2019-03-05 10:39 ` Petri Latvala
2019-03-04 15:31 ` [igt-dev] [PATCH i-g-t 5/7] kms_flip: Remove magic constant in run_test_on_crtc_set() Rodrigo Siqueira
2019-03-04 15:31 ` [igt-dev] [PATCH i-g-t 6/7] kms_flip: Rework set_mode() Rodrigo Siqueira
2019-03-04 15:32 ` [Intel-gfx] [PATCH i-g-t 7/7] kms_flip: Standardize return value for fb_is_bound Rodrigo Siqueira
2019-03-06 11:25 ` Maarten Lankhorst [this message]
2019-03-06 21:40 ` [igt-dev] " Rodrigo Siqueira
2019-03-04 16:18 ` [igt-dev] ✓ Fi.CI.BAT: success for kms_flip: cleanups Patchwork
2019-03-04 20:04 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
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=7c52359d-89ba-d6a1-b812-7060d89ef42b@linux.intel.com \
--to=maarten.lankhorst@linux.intel.com \
--cc=arkadiusz.hiler@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=petri.latvala@intel.com \
--cc=rodrigosiqueiramelo@gmail.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