From patchwork Mon Mar 20 23:36:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Anholt X-Patchwork-Id: 9635483 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 82762601E9 for ; Mon, 20 Mar 2017 23:36:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 74E1826E97 for ; Mon, 20 Mar 2017 23:36:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 69C0E277D9; Mon, 20 Mar 2017 23:36:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 22C8D26E97 for ; Mon, 20 Mar 2017 23:36:24 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 845516E6BB; Mon, 20 Mar 2017 23:36:22 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from anholt.net (anholt.net [50.246.234.109]) by gabe.freedesktop.org (Postfix) with ESMTP id 8A2AA6E6B1 for ; Mon, 20 Mar 2017 23:36:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by anholt.net (Postfix) with ESMTP id 3EC4310A1E6E; Mon, 20 Mar 2017 16:36:18 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at anholt.net Received: from anholt.net ([127.0.0.1]) by localhost (kingsolver.anholt.net [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Sz3H9ULMc67M; Mon, 20 Mar 2017 16:36:16 -0700 (PDT) Received: from eliezer.anholt.net (localhost [127.0.0.1]) by anholt.net (Postfix) with ESMTP id 60EA510A1E57; Mon, 20 Mar 2017 16:36:16 -0700 (PDT) Received: by eliezer.anholt.net (Postfix, from userid 1000) id 919F42EA044; Mon, 20 Mar 2017 16:36:15 -0700 (PDT) From: Eric Anholt To: dri-devel@lists.freedesktop.org, tom.cooksey@arm.com, Russell King Subject: [PATCH v3 3/3] drm: Clarify the role of plane_state argument to drm_simple update(). Date: Mon, 20 Mar 2017 16:36:15 -0700 Message-Id: <20170320233615.5242-3-eric@anholt.net> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170320233615.5242-1-eric@anholt.net> References: <20170320233615.5242-1-eric@anholt.net> Cc: linux-kernel@vger.kernel.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Like the atomic update hook it's wrapping, the plane_state is the old one, and the new one is in plane->state. Both msxfb and tinydrm use it correctly, but I mistook it for the new state in pl111 due to its naming. Signed-off-by: Eric Anholt Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_simple_kms_helper.c | 4 ++-- include/drm/drm_simple_kms_helper.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/drm_simple_kms_helper.c b/drivers/gpu/drm/drm_simple_kms_helper.c index 16789faa9291..e084f9f8ca66 100644 --- a/drivers/gpu/drm/drm_simple_kms_helper.c +++ b/drivers/gpu/drm/drm_simple_kms_helper.c @@ -114,7 +114,7 @@ static int drm_simple_kms_plane_atomic_check(struct drm_plane *plane, } static void drm_simple_kms_plane_atomic_update(struct drm_plane *plane, - struct drm_plane_state *pstate) + struct drm_plane_state *old_pstate) { struct drm_simple_display_pipe *pipe; @@ -122,7 +122,7 @@ static void drm_simple_kms_plane_atomic_update(struct drm_plane *plane, if (!pipe->funcs || !pipe->funcs->update) return; - pipe->funcs->update(pipe, pstate); + pipe->funcs->update(pipe, old_pstate); } static int drm_simple_kms_plane_prepare_fb(struct drm_plane *plane, diff --git a/include/drm/drm_simple_kms_helper.h b/include/drm/drm_simple_kms_helper.h index fffbb95a0915..2d36538e4a17 100644 --- a/include/drm/drm_simple_kms_helper.h +++ b/include/drm/drm_simple_kms_helper.h @@ -72,7 +72,7 @@ struct drm_simple_display_pipe_funcs { * the hardware lacks vblank support entirely. */ void (*update)(struct drm_simple_display_pipe *pipe, - struct drm_plane_state *plane_state); + struct drm_plane_state *old_plane_state); /** * @prepare_fb: