diff options
author | Geert Uytterhoeven <geert@linux-m68k.org> | 2022-07-08 20:20:48 +0200 |
---|---|---|
committer | Sam Ravnborg <sam@ravnborg.org> | 2022-07-09 15:00:52 +0200 |
commit | 356d2c8e76ebb1134a0685ce4b923d8201337475 (patch) | |
tree | 96faa5b150816c53d8f7d54cdd74182a295c02fc /drivers/gpu/drm/drm_framebuffer.c | |
parent | dc1dc76bd9a48c6aba3efae5eadb9a884043966e (diff) |
drm/client: Use actual bpp when allocating frame buffers
When allocating a frame buffer, the number of bits per pixel needed is
derived from the deprecated drm_format_info.cpp[] field. While this may
work for formats using less than 8 bits per pixel, it does lead to a
large overallocation.
Reduce memory consumption by using the actual number of bits per pixel
instead.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/eabcf4f298184dabe46823fcf5ceffa1da0ec7ef.1657294931.git.geert@linux-m68k.org
Diffstat (limited to 'drivers/gpu/drm/drm_framebuffer.c')
0 files changed, 0 insertions, 0 deletions