From patchwork Mon Aug 29 13:11:49 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 12957947 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 228BFECAAD5 for ; Mon, 29 Aug 2022 13:48:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=v/VPQuhbSbIM9dC0pLbbjOVL9xWgIHfYbZuGxSFZc+8=; b=xn+2/9WpVD0iAJ peTzWJuFaeatsjP6heKEQpXBJa20mVrOqalAugY8CjtMkbTsur9zpfpw0WOzvEpoc+DLSId1uhcHk kF5ZD/Z+jodcdhczbfQ9aTV+g6aSi4z2A8pKJRc4KKh+H/feWpf89qFdD5ThM2NruzQN7HBb4n+BT IPNO1SHBFAN/uvRVPVDKrNuI5kkv8t00MzI1svzUfoKfCAa+j9t6UL/zlEs7O3LmR4IVKxYvHzvK9 ZjlbmjlDPk+o2T9WwYiV0Q177R/O9OguFEe+HiiS4BR3qUPpWb8+K/uldcgFkTydh3gdlNVGbPw1p fI1mX0xBt29g0V/bq+VA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oSf6Y-00Ap3u-7F; Mon, 29 Aug 2022 13:47:08 +0000 Received: from wnew2-smtp.messagingengine.com ([64.147.123.27]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oSecP-00Abbj-8M for linux-arm-kernel@lists.infradead.org; Mon, 29 Aug 2022 13:16:01 +0000 Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailnew.west.internal (Postfix) with ESMTP id DF5142B05E5E; Mon, 29 Aug 2022 09:15:53 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Mon, 29 Aug 2022 09:15:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h=cc :cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1661778953; x= 1661786153; bh=fGq4pxjwR9dhN8V94rScn9Z1raHP34bbSYZqQRlSHw0=; b=c VXAet/qyIapvApr4WQBJpPocgntulpZY1iMHgEOHg6IOdnmDSveEjj3Z8AKVmHc7 C3snlSKLgltL8UUmjsAtZfPms8eriiJSBQMJMMv96+UWrrIZbcihxTFOzArWyOUS WYbvYV1ir05vDLmz/OcTIJUsqeJPnF0O4HFr56HWO+O6dnm42EWhfga8x4dwhgm4 wj07s+IrTQg1peX5jGvfNDhFycYUccwXfFSFYh0v7Jin/SzkCTbbx2AUa2TCzJiH ZOqUGD7DJTplKseM17IJPtDX3OCWHkeNrc5iOZ/S0+nDdioFGvGvk9CX5VMP9WJr WMRsBmhG0wdCzBgWU2a+g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1661778953; x= 1661786153; bh=fGq4pxjwR9dhN8V94rScn9Z1raHP34bbSYZqQRlSHw0=; b=t XOfZrOEyjM13jfV1nPLKePsnAo8mXNQfreTSb+SO/DhCM67pNDSwKfdu2lE9O7MZ 8dA6mZBcgOJSrU1zbEtdHJ3nNM0gmeERQXR0SI6jApcEXKgu+LWtYRQ+stQRcA9a 1QvQq/z/rLnXizwQ/LU4Oo+LlHDDwW4WWup/C9Hqderml0ot9FMIYHFIl9yKjHCM G1xzNsm/sPJCmUV741nzZ6KcIdYWeZ2Rj43M08xaNOAa3OmaXGiBsmPaCo+ewMmR dRWTGI8I//uQzxge+fvfoMw9BUx+yhAB5h0t3v5gU29SrQ5rypa+sry1bXeIbZ9+ rFvdyor2LMfebHEuijAZQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvdekuddgieegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkofgjfhggtgfogfesthhqredtredtjeenucfhrhhomhepofgr gihimhgvucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtf frrghtthgvrhhnpeefiedvfefggffgffehveejieffuddtgffhjefggeetieduvdeileet lefgveegtdenucevlhhushhtvghrufhiiigvpeejnecurfgrrhgrmhepmhgrihhlfhhroh hmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Feedback-ID: i8771445c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 29 Aug 2022 09:15:52 -0400 (EDT) From: Maxime Ripard To: Maxime Ripard , Ben Skeggs , David Airlie , Chen-Yu Tsai , Thomas Zimmermann , Jani Nikula , Lyude Paul , Philipp Zabel , Maarten Lankhorst , Rodrigo Vivi , Tvrtko Ursulin , Jernej Skrabec , Samuel Holland , Karol Herbst , =?utf-8?q?Noralf_Tr=C3=B8nnes?= , Emma Anholt , Daniel Vetter , Joonas Lahtinen Cc: Maxime Ripard , Hans de Goede , linux-arm-kernel@lists.infradead.org, Phil Elwell , intel-gfx@lists.freedesktop.org, Dave Stevenson , dri-devel@lists.freedesktop.org, Dom Cobley , linux-kernel@vger.kernel.org, nouveau@lists.freedesktop.org, linux-sunxi@lists.linux.dev, Mateusz Kwiatkowski , Geert Uytterhoeven Subject: [PATCH v2 35/41] drm/sun4i: tv: Convert to atomic hooks Date: Mon, 29 Aug 2022 15:11:49 +0200 Message-Id: <20220728-rpi-analog-tv-properties-v2-35-459522d653a7@cerno.tech> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220728-rpi-analog-tv-properties-v2-0-459522d653a7@cerno.tech> References: <20220728-rpi-analog-tv-properties-v2-0-459522d653a7@cerno.tech> MIME-Version: 1.0 X-Mailer: b4 0.10.0-dev-65ba7 X-Developer-Signature: v=1; a=openpgp-sha256; l=1624; i=maxime@cerno.tech; h=from:subject:message-id; bh=EjOnDOZq2Ss8h1qrZ2KbpJgd2LCqDkVnUyJOEPlgRRU=; b=owGbwMvMwCX2+D1vfrpE4FHG02pJDMk8uxSZmRf9TNF9MLFCtKDh5WYP9ySNxJebzPxF3ifKTegX //Oho5SFQYyLQVZMkSVG2HxJ3KlZrzvZ+ObBzGFlAhnCwMUpABN5wc3I0C3w1OXska8Z0ziW3cybKH d28trNi/xnvNBh45Yo2PNjxhRGhkkfI1cdvB1c0TZjwVWp4y6Fs9e7/trsvM4iWiQ+JfzHEyYA X-Developer-Key: i=maxime@cerno.tech; a=openpgp; fpr=BE5675C37E818C8B5764241C254BCFC56BF6CE8D X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220829_061557_403847_4F6CE59E X-CRM114-Status: UNSURE ( 7.10 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The sun4i TV driver still uses legacy enable and disable hook implementation. Let's convert to the atomic variants. Signed-off-by: Maxime Ripard Acked-by: Jernej Skrabec diff --git a/drivers/gpu/drm/sun4i/sun4i_tv.c b/drivers/gpu/drm/sun4i/sun4i_tv.c index 53152d77c392..f7aad995ab5b 100644 --- a/drivers/gpu/drm/sun4i/sun4i_tv.c +++ b/drivers/gpu/drm/sun4i/sun4i_tv.c @@ -339,7 +339,8 @@ static void sun4i_tv_mode_to_drm_mode(const struct tv_mode *tv_mode, mode->vtotal = mode->vsync_end + tv_mode->vback_porch; } -static void sun4i_tv_disable(struct drm_encoder *encoder) +static void sun4i_tv_disable(struct drm_encoder *encoder, + struct drm_atomic_state *state) { struct sun4i_tv *tv = drm_encoder_to_sun4i_tv(encoder); struct sun4i_crtc *crtc = drm_crtc_to_sun4i_crtc(encoder->crtc); @@ -353,7 +354,8 @@ static void sun4i_tv_disable(struct drm_encoder *encoder) sunxi_engine_disable_color_correction(crtc->engine); } -static void sun4i_tv_enable(struct drm_encoder *encoder) +static void sun4i_tv_enable(struct drm_encoder *encoder, + struct drm_atomic_state *state) { struct sun4i_tv *tv = drm_encoder_to_sun4i_tv(encoder); struct sun4i_crtc *crtc = drm_crtc_to_sun4i_crtc(encoder->crtc); @@ -469,8 +471,8 @@ static void sun4i_tv_mode_set(struct drm_encoder *encoder, } static const struct drm_encoder_helper_funcs sun4i_tv_helper_funcs = { - .disable = sun4i_tv_disable, - .enable = sun4i_tv_enable, + .atomic_disable = sun4i_tv_disable, + .atomic_enable = sun4i_tv_enable, .mode_set = sun4i_tv_mode_set, };