drm/simpledrm: Enable FB_DAMAGE_CLIPS property
authorThomas Zimmermann <tzimmermann@suse.de>
Wed, 10 Nov 2021 10:37:00 +0000 (11:37 +0100)
committerThomas Zimmermann <tzimmermann@suse.de>
Thu, 11 Nov 2021 11:06:58 +0000 (12:06 +0100)
commit0dd80b483b95abdbc3919cb360d17179a5f85d2c
tree306e8cbcfe97dd2b6fd33769fb84b3795c3a2b0c
parent18ac700d75e81b7892c6377f6d8b917453ac69fd
drm/simpledrm: Enable FB_DAMAGE_CLIPS property

Enable the FB_DAMAGE_CLIPS property to reduce display-update
overhead. Also fixes a warning in the kernel log.

  simple-framebuffer simple-framebuffer.0: [drm] drm_plane_enable_fb_damage_clips() not called

Fix the computation of the blit rectangle. This wasn't an issue so
far, as simpledrm always blitted the full framebuffer. The code now
supports damage clipping and virtual screen sizes.

v3:
* fix drm_dev_enter() error path (Noralf)
* remove unnecessary clipping from update function (Noralf)

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Noralf Trønnes <noralf@tronnes.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20211110103702.374-8-tzimmermann@suse.de
drivers/gpu/drm/tiny/simpledrm.c