mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-07-05 22:07:06 +08:00

These patches were generated from: https://github.com/raspberrypi/linux/commits/rpi-6.12.y With the following command: git format-patch -N v6.12.27..HEAD (HEAD -> 8d3206ee456a5ecdf9ddbfd8e5e231e4f0cd716e) Exceptions: - (def)configs patches - github workflows patches - applied & reverted patches - readme patches - wireless patches Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
31 lines
1.0 KiB
Diff
31 lines
1.0 KiB
Diff
From 8879552d6b5e6f102c759f68c7732b2c8b01fa88 Mon Sep 17 00:00:00 2001
|
|
From: Dave Stevenson <dave.stevenson@raspberrypi.com>
|
|
Date: Wed, 11 Dec 2024 16:30:43 +0000
|
|
Subject: [PATCH] drm: vc4: txp: Do not allow 24bpp formats when transposing
|
|
|
|
The hardware doesn't support transposing to 24bpp (RGB888/BGR888)
|
|
formats. There's no way to advertise this through DRM, so block
|
|
it from atomic_check instead.
|
|
|
|
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
|
|
---
|
|
drivers/gpu/drm/vc4/vc4_txp.c | 7 +++++++
|
|
1 file changed, 7 insertions(+)
|
|
|
|
--- a/drivers/gpu/drm/vc4/vc4_txp.c
|
|
+++ b/drivers/gpu/drm/vc4/vc4_txp.c
|
|
@@ -272,6 +272,13 @@ static int vc4_txp_connector_atomic_chec
|
|
return -EINVAL;
|
|
}
|
|
|
|
+ if (conn_state->rotation & DRM_MODE_TRANSPOSE &&
|
|
+ (fb->format->format == DRM_FORMAT_RGB888 ||
|
|
+ fb->format->format == DRM_FORMAT_BGR888)) {
|
|
+ DRM_DEBUG_KMS("24bpp formats not supported when transposing\n");
|
|
+ return -EINVAL;
|
|
+ }
|
|
+
|
|
for (i = 0; i < ARRAY_SIZE(drm_fmts); i++) {
|
|
if (fb->format->format == drm_fmts[i])
|
|
break;
|