mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-22 15:02:32 +00:00
51 lines
1.4 KiB
Diff
51 lines
1.4 KiB
Diff
|
From bfdb79d68e27c16a8b3ef43e77f95958774d1bd1 Mon Sep 17 00:00:00 2001
|
||
|
From: David Plowman <david.plowman@raspberrypi.com>
|
||
|
Date: Mon, 17 Oct 2022 15:18:24 +0100
|
||
|
Subject: [PATCH] drivers/gpu/drm/vc4: Add missing 32-bit RGB formats
|
||
|
|
||
|
The missing 32-bit per pixel ABGR and various "RGB with an X value"
|
||
|
formats are added. Change sent by Dave Stevenson.
|
||
|
|
||
|
Signed-off-by: David Plowman <david.plowman@raspberrypi.com>
|
||
|
---
|
||
|
drivers/gpu/drm/vc4/vc4_firmware_kms.c | 28 +++++++++++++++-----------
|
||
|
1 file changed, 16 insertions(+), 12 deletions(-)
|
||
|
|
||
|
--- a/drivers/gpu/drm/vc4/vc4_firmware_kms.c
|
||
|
+++ b/drivers/gpu/drm/vc4/vc4_firmware_kms.c
|
||
|
@@ -184,18 +184,22 @@ static const struct vc_image_format {
|
||
|
.drm = DRM_FORMAT_ARGB8888,
|
||
|
.vc_image = VC_IMAGE_ARGB8888,
|
||
|
},
|
||
|
-/*
|
||
|
- * FIXME: Need to resolve which DRM format goes to which vc_image format
|
||
|
- * for the remaining RGBA and RGBX formats.
|
||
|
- * {
|
||
|
- * .drm = DRM_FORMAT_ABGR8888,
|
||
|
- * .vc_image = VC_IMAGE_RGBA8888,
|
||
|
- * },
|
||
|
- * {
|
||
|
- * .drm = DRM_FORMAT_XBGR8888,
|
||
|
- * .vc_image = VC_IMAGE_RGBA8888,
|
||
|
- * },
|
||
|
- */
|
||
|
+ {
|
||
|
+ .drm = DRM_FORMAT_XBGR8888,
|
||
|
+ .vc_image = VC_IMAGE_RGBX32,
|
||
|
+ },
|
||
|
+ {
|
||
|
+ .drm = DRM_FORMAT_ABGR8888,
|
||
|
+ .vc_image = VC_IMAGE_RGBA32,
|
||
|
+ },
|
||
|
+ {
|
||
|
+ .drm = DRM_FORMAT_RGBX8888,
|
||
|
+ .vc_image = VC_IMAGE_BGRX8888,
|
||
|
+ },
|
||
|
+ {
|
||
|
+ .drm = DRM_FORMAT_BGRX8888,
|
||
|
+ .vc_image = VC_IMAGE_RGBX8888,
|
||
|
+ },
|
||
|
{
|
||
|
.drm = DRM_FORMAT_RGB565,
|
||
|
.vc_image = VC_IMAGE_RGB565,
|