From: Mark Yacoub Date: Mon, 13 Dec 2021 16:07:22 +0000 (-0500) Subject: drm/mediatek: Set the default value of rotation to DRM_MODE_ROTATE_0 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=d95b00f1a8c57f10a7c83bec5a245391c7666f36;p=linux.git drm/mediatek: Set the default value of rotation to DRM_MODE_ROTATE_0 At the reset hook, call __drm_atomic_helper_plane_reset which is called at the initialization of the plane and sets the default value of rotation on all planes to DRM_MODE_ROTATE_0 which is equal to 1. Tested on Jacuzzi (MTK). Resolves IGT@kms_properties@plane-properties-{legacy,atomic} Signed-off-by: Mark Yacoub Signed-off-by: Chun-Kuang Hu --- diff --git a/drivers/gpu/drm/mediatek/mtk_drm_plane.c b/drivers/gpu/drm/mediatek/mtk_drm_plane.c index 734a1fb052dfd..075747a6d4aac 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_plane.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_plane.c @@ -44,9 +44,10 @@ static void mtk_plane_reset(struct drm_plane *plane) state = kzalloc(sizeof(*state), GFP_KERNEL); if (!state) return; - plane->state = &state->base; } + __drm_atomic_helper_plane_reset(plane, &state->base); + state->base.plane = plane; state->pending.format = DRM_FORMAT_RGB565; }