drm: Use original src rect while initializing damage iterator
authorJouni Högander <jouni.hogander@intel.com>
Tue, 23 Aug 2022 11:29:17 +0000 (14:29 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 13 Sep 2022 11:38:33 +0000 (14:38 +0300)
commitdd9b18e76f0434e47ee8f5243727c79a66a85243
tree6fb9193826906058898e76a454e42294198fabe8
parent8c9c40ec83445b188fb6b59e119bf5c2de81b02d
drm: Use original src rect while initializing damage iterator

drm_plane_state->src might be modified by the driver. This is done
e.g. in i915 driver when there is bigger framebuffer than the plane
and there is some offset within framebuffer. I915 driver calculates
separate offset and adjusts src rect coords to be relative to this
offset. Damage clips are still relative to original src coords
provided by user-space.

This patch ensures original coordinates provided by user-space are
used when initiliazing damage iterator.

Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220823112920.352563-2-jouni.hogander@intel.com
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
drivers/gpu/drm/drm_damage_helper.c