mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 07:51:16 -04:00
drm/i915/overlay: Remove redundant drm_rect_visible() use
The drm_rect_intersect() already returns if the intersection is visible or not, so the use of drm_rect_visible() is duplicate. Signed-off-by: Arthur Grillo <arthurgrillo@riseup.net> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230325172719.92102-1-arthurgrillo@riseup.net
This commit is contained in:
committed by
Ville Syrjälä
parent
d10612f830
commit
711c487ca4
@@ -972,10 +972,11 @@ static int check_overlay_dst(struct intel_overlay *overlay,
|
||||
rec->dst_width, rec->dst_height);
|
||||
|
||||
clipped = req;
|
||||
drm_rect_intersect(&clipped, &crtc_state->pipe_src);
|
||||
|
||||
if (!drm_rect_visible(&clipped) ||
|
||||
!drm_rect_equals(&clipped, &req))
|
||||
if (!drm_rect_intersect(&clipped, &crtc_state->pipe_src))
|
||||
return -EINVAL;
|
||||
|
||||
if (!drm_rect_equals(&clipped, &req))
|
||||
return -EINVAL;
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user