[PATCH 2/2] drm/meson: overlay: fix Amlogic Compressed Framebuffer modifier layout extract

From: Neil Armstrong
Date: Thu Jul 23 2020 - 05:06:01 EST


The bitwise operation worked because the result is casted in a lower bits
integer, and was not changed after the modifier defines rework.

Use the correct operation as already used in meson_overlay_atomic_update().

Fixes: e860785d5730 ("drm/meson: overlay: setup overlay for Amlogic FBC")
Signed-off-by: Neil Armstrong <narmstrong@xxxxxxxxxxxx>
---
drivers/gpu/drm/meson/meson_overlay.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/meson/meson_overlay.c b/drivers/gpu/drm/meson/meson_overlay.c
index a8bcc70644df..83ec613bbfb6 100644
--- a/drivers/gpu/drm/meson/meson_overlay.c
+++ b/drivers/gpu/drm/meson/meson_overlay.c
@@ -756,8 +756,7 @@ static bool meson_overlay_format_mod_supported(struct drm_plane *plane,
if ((modifier & DRM_FORMAT_MOD_AMLOGIC_FBC(0, 0)) ==
DRM_FORMAT_MOD_AMLOGIC_FBC(0, 0)) {
unsigned int layout = modifier &
- DRM_FORMAT_MOD_AMLOGIC_FBC(
- __fourcc_mod_amlogic_layout_mask, 0);
+ __fourcc_mod_amlogic_layout_mask;
unsigned int options =
(modifier >> __fourcc_mod_amlogic_options_shift) &
__fourcc_mod_amlogic_options_mask;
--
2.22.0