Linux v4.19-rc4-176-g211b100a5ced

This commit is contained in:
Jeremy Cline 2018-09-21 10:10:19 -04:00
parent 28c16a6fad
commit b333c0a3ef
No known key found for this signature in database
GPG Key ID: 9223308FA9B246DB
4 changed files with 6 additions and 94 deletions

View File

@ -1,88 +0,0 @@
From patchwork Wed Jul 25 12:29:07 2018
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: drm/vc4: Fix the "no scaling" case on multi-planar YUV formats
From: Boris Brezillon <boris.brezillon@bootlin.com>
X-Patchwork-Id: 240917
Message-Id: <20180725122907.13702-1-boris.brezillon@bootlin.com>
To: Eric Anholt <eric@anholt.net>
Cc: David Airlie <airlied@linux.ie>,
Boris Brezillon <boris.brezillon@bootlin.com>, stable@vger.kernel.org,
dri-devel@lists.freedesktop.org
Date: Wed, 25 Jul 2018 14:29:07 +0200
When there's no scaling requested ->is_unity should be true no matter
the format.
Also, when no scaling is requested and we have a multi-planar YUV
format, we should leave ->y_scaling[0] to VC4_SCALING_NONE and only
set ->x_scaling[0] to VC4_SCALING_PPF.
Doing this fixes an hardly visible artifact (seen when using modetest
and a rather big overlay plane in YUV420).
Fixes: fc04023fafec ("drm/vc4: Add support for YUV planes.")
Cc: <stable@vger.kernel.org>
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
---
drivers/gpu/drm/vc4/vc4_plane.c | 25 ++++++++++++-------------
1 file changed, 12 insertions(+), 13 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_plane.c b/drivers/gpu/drm/vc4/vc4_plane.c
index cfb50fedfa2b..a3275fa66b7b 100644
--- a/drivers/gpu/drm/vc4/vc4_plane.c
+++ b/drivers/gpu/drm/vc4/vc4_plane.c
@@ -297,6 +297,9 @@ static int vc4_plane_setup_clipping_and_scaling(struct drm_plane_state *state)
vc4_state->y_scaling[0] = vc4_get_scaling_mode(vc4_state->src_h[0],
vc4_state->crtc_h);
+ vc4_state->is_unity = (vc4_state->x_scaling[0] == VC4_SCALING_NONE &&
+ vc4_state->y_scaling[0] == VC4_SCALING_NONE);
+
if (num_planes > 1) {
vc4_state->is_yuv = true;
@@ -312,24 +315,17 @@ static int vc4_plane_setup_clipping_and_scaling(struct drm_plane_state *state)
vc4_get_scaling_mode(vc4_state->src_h[1],
vc4_state->crtc_h);
- /* YUV conversion requires that scaling be enabled,
- * even on a plane that's otherwise 1:1. Choose TPZ
- * for simplicity.
+ /* YUV conversion requires that horizontal scaling be enabled,
+ * even on a plane that's otherwise 1:1. Looks like only PPF
+ * works in that case, so let's pick that one.
*/
- if (vc4_state->x_scaling[0] == VC4_SCALING_NONE)
- vc4_state->x_scaling[0] = VC4_SCALING_TPZ;
- if (vc4_state->y_scaling[0] == VC4_SCALING_NONE)
- vc4_state->y_scaling[0] = VC4_SCALING_TPZ;
+ if (vc4_state->is_unity)
+ vc4_state->x_scaling[0] = VC4_SCALING_PPF;
} else {
vc4_state->x_scaling[1] = VC4_SCALING_NONE;
vc4_state->y_scaling[1] = VC4_SCALING_NONE;
}
- vc4_state->is_unity = (vc4_state->x_scaling[0] == VC4_SCALING_NONE &&
- vc4_state->y_scaling[0] == VC4_SCALING_NONE &&
- vc4_state->x_scaling[1] == VC4_SCALING_NONE &&
- vc4_state->y_scaling[1] == VC4_SCALING_NONE);
-
/* No configuring scaling on the cursor plane, since it gets
non-vblank-synced updates, and scaling requires requires
LBM changes which have to be vblank-synced.
@@ -672,7 +668,10 @@ static int vc4_plane_mode_set(struct drm_plane *plane,
vc4_dlist_write(vc4_state, SCALER_CSC2_ITR_R_601_5);
}
- if (!vc4_state->is_unity) {
+ if (vc4_state->x_scaling[0] != VC4_SCALING_NONE ||
+ vc4_state->x_scaling[1] != VC4_SCALING_NONE ||
+ vc4_state->y_scaling[0] != VC4_SCALING_NONE ||
+ vc4_state->y_scaling[1] != VC4_SCALING_NONE) {
/* LBM Base Address. */
if (vc4_state->y_scaling[0] != VC4_SCALING_NONE ||
vc4_state->y_scaling[1] != VC4_SCALING_NONE) {

2
gitrev
View File

@ -1 +1 @@
ae596de1a0c8c2c924dc99d23c026259372ab234
211b100a5ceda9d1856a3f84334f9ca5f680b638

View File

@ -69,7 +69,7 @@ Summary: The Linux kernel
# The rc snapshot level
%global rcrev 4
# The git snapshot level
%define gitrev 3
%define gitrev 4
# Set rpm version accordingly
%define rpmversion 4.%{upstream_sublevel}.0
%endif
@ -592,9 +592,6 @@ Patch309: gpio-pxa-handle-corner-case-of-unprobed-device.patch
Patch330: bcm2835-cpufreq-add-CPU-frequency-control-driver.patch
# https://patchwork.freedesktop.org/patch/240917/
Patch331: drm-vc4-Fix-the-no-scaling-case-on-multi-planar-YUV-formats.patch
# Fix for AllWinner A64 Timer Errata, still not final
# https://patchwork.kernel.org/patch/10392891/
Patch350: arm64-arch_timer-Workaround-for-Allwinner-A64-timer-instability.patch
@ -1879,6 +1876,9 @@ fi
#
#
%changelog
* Fri Sep 21 2018 Jeremy Cline <jcline@redhat.com> - 4.19.0-0.rc4.git4.1
- Linux v4.19-rc4-176-g211b100a5ced
* Thu Sep 20 2018 Jeremy Cline <jcline@redhat.com> - 4.19.0-0.rc4.git3.1
- Linux v4.19-rc4-137-gae596de1a0c8

View File

@ -1,3 +1,3 @@
SHA512 (linux-4.18.tar.xz) = 950eb85ac743b291afe9f21cd174d823e25f11883ee62cecfbfff8fe8c5672aae707654b1b8f29a133b1f2e3529e63b9f7fba4c45d6dacccc8000b3a9a9ae038
SHA512 (patch-4.19-rc4.xz) = 31fa976573d724ab5592dbb97473c5523dea635e0f1235bb61ca8e81b7146218e277238039b817a82a3763d0b667038cb85a41fd103d680037db7cad40a88cd3
SHA512 (patch-4.19-rc4-git3.xz) = eebf7845c05ea3374adb2761476e68bf6ceae3730e4e58984e56717ffd09d06b482ba302d97abfdf0de8fb6322a5f99cb10dc422735939f42253107de7dcad9c
SHA512 (patch-4.19-rc4-git4.xz) = e75a9888c04546a06050174f2e9f5342c1955436d82729d2c8c8168ece128b1ab829bebdc80de5b553a438926dc70d6f2f95083ea7dbd2cc140bfaa05b14a6a4