diff options
author | Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com> | 2019-03-04 12:32:08 -0300 |
---|---|---|
committer | Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com> | 2019-03-12 09:01:21 -0300 |
commit | 4a6e6be764f6da8fe9049e76e4aae7eac349701f (patch) | |
tree | da7d682ae8f055f0fad05abe8815a17a4ed895bf /tests/kms_flip.c | |
parent | e94044d67f3a8a02785caeb07111ef982f5a6bc6 (diff) |
kms_flip: Standardize return value for fb_is_bound
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>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'tests/kms_flip.c')
-rwxr-xr-x | tests/kms_flip.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/kms_flip.c b/tests/kms_flip.c index c9fb6762..dfa5a69e 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; |