drm/ssd130x: Preallocate format-conversion buffer in atomic_check
authorThomas Zimmermann <tzimmermann@suse.de>
Mon, 9 Oct 2023 14:06:36 +0000 (16:06 +0200)
committerThomas Zimmermann <tzimmermann@suse.de>
Tue, 14 Nov 2023 09:17:23 +0000 (10:17 +0100)
commitc669875041d038e91fa99766a07ec2d8bd6dcf6a
tree6f50182ffe04032ff077415f42496cbb45c7c709
parente7c814d305e110d6db3f440d14490a8d0d9477d9
drm/ssd130x: Preallocate format-conversion buffer in atomic_check

Preallocate the format-conversion state's storage in the plane's
atomic_check function if a format conversion is necessary. Allows
the update to fail if no memory is available. Avoids the same
allocation within atomic_update, which may not fail.

v6:
* update patch for ssd132x support

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Tested-by: Javier Martinez Canillas <javierm@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231009141018.11291-8-tzimmermann@suse.de
drivers/gpu/drm/solomon/ssd130x.c