From patchwork Sun Mar 31 20:29:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 13612301 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 DBCD5CD1284 for ; Sun, 31 Mar 2024 20:30:25 +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:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=aWL1MUEk13YTZ87lQY1c7H18vEX9lck+5feTddI8i/I=; b=zjM7ncTOs8xt0I x2okENd0FHRGKU18UvLGZ1RNxvuBm/2HysQ4QlXMVk4VAniQ2rvSVxBmV2oBVUZu0Cv/u4DrzObN+ VHzCI4jgwXDkeha8IdbMDHd7o4Tq4SPHkuUlLrFwR01dqCWD8xH1HgzYHA02faw8DoCUxGTghTxOm kmJf2yPNg65FxdcDT7ErHtHediGqwXMIJuCCBavipLMs+Q/Wbj+3lRzEVbO0DkHnnToCOHT2PImsg CigJMhLobWVfYji9FQufpT/N3oOL2A5dB6uHCRZJo5Z9QL/+q/lABvk9SxJOiKMuWief/QxwL342H b1WX/wEg+HX06dyj8m3Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rr1oh-00000006GPQ-37bl; Sun, 31 Mar 2024 20:30:11 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rr1nw-00000006FyC-2wWj for linux-arm-kernel@bombadil.infradead.org; Sun, 31 Mar 2024 20:29:25 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Cc:To:In-Reply-To:References: Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Sender:Reply-To:Content-ID:Content-Description; bh=+v9GTIZDIAWX08FzKTARGqVQVzeSJaMCtOVkVitqgmc=; b=IMc7diuStYwgHjqipzyMnYU4OP O/5Gla4jkAL0tDOs3i1eEHaTfhF+JoJHKgheN+Rd8UAXn5+0mNGuM1p4zOj5fwEjIMS5CbOPooucH NX6U7RYgwNIqQfde60R/JtZq7EYunobDIJM609upxK6hgZi392BeN9r4BJI+VgHfZ1FNRf4bh/muH l9HafnWy8Ccn4Q9qjPbn4fgihcmwhDJJLex96M9CZZURWnkooDGCcTubHIKXXhP9EeFo2osAQ8R2W DVlQAB17GojTlcqXvfYD8LmjOxTdcF9HUjtVVayhCyExgz983R1OJ7ojoW/PaZcpoUltDbMVliaLl vEmCOh4g==; Received: from mail-lf1-x130.google.com ([2a00:1450:4864:20::130]) by desiato.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rr1nq-00000002isP-3DNN for linux-arm-kernel@lists.infradead.org; Sun, 31 Mar 2024 20:29:23 +0000 Received: by mail-lf1-x130.google.com with SMTP id 2adb3069b0e04-513d23be0b6so3821733e87.0 for ; Sun, 31 Mar 2024 13:29:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1711916955; x=1712521755; darn=lists.infradead.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=+v9GTIZDIAWX08FzKTARGqVQVzeSJaMCtOVkVitqgmc=; b=wBvqFcNcX+mTSx5VbLZJNzJh78QI9PveUB3hhYspO51sge1gaLr1dNEX6MYWoYQDMi 2dfCuPIfDdJe1wOKNW8mJ2hd+jkZwxmi5nkH54wTYLWtnU1nMRYkPidVTDpl2ZYwsPJF R8B76nKlRHI/Z2Olf0/yT062tmrUfaJwQDqQUnt8g/sYciJKOIEFlgvI7wIsgIzS+D/3 yWo/Kq+O1QdEj+HSfeuyPlFLiZhKJn1qzsF9PKoEzoXhR4KG9tQxQnOPGyT1ESrfUVMO hVJ7UqgB+a+u46jYNNDB/OXXfEFz+X8+4BCE2K7uhVV5Y3zPn1xSiWn37MVdtcoqlWVp Is0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711916955; x=1712521755; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+v9GTIZDIAWX08FzKTARGqVQVzeSJaMCtOVkVitqgmc=; b=gU/wK/K7FHxnTaBa2p3Wo+tSnXnRBhbaAW5x8WCoWXibLOu31xyQPIbGUj8rsVmPVt tZrvgGG8IXq7kHr6Cua8AmrPYnEkdVPB2ZhzFTTCFMeb8Uo9AQchBQ7mMxTMJXw8/Tc7 lJi1L8sLUVuUYAiJ8brhKENzy0uYTU09bOls8aemyzuLONNcwNN2JJEXE1+mLitJUfnF Dvug7B6GeCgSqiR05BdGTFEYZIWJQRCc/ue126Mopu4aTDnp5M98wJbHrn4ipAKodMYG lf9Pt60aeRBdoepINyY/LSSv7ks6zL4hf33Sz/QpDN0E2jYa0fpHm8o4rEo8jEhgWAwo LQXw== X-Forwarded-Encrypted: i=1; AJvYcCVJb5bM4tvHGUq4faBb5oJm6Siw4yiizNwTpyaVzHF5UcImWZPt9S6iZhlAEPbmus2eRQ3w5qn/kjwJ0bxTiA38TwttuEQ9fIk1Y8guRSpmDWoYipI= X-Gm-Message-State: AOJu0YxLPhhso7d8vq8dlWgcyGVA06SYTM4rfS45DuF0Reb2RMtpKTNl +UC5hnCVMg4/WZ5v4gXRMqvU6DP7e6m2QQscm+49drfiNUNe1Yb1zd4rOJpX4Rg= X-Google-Smtp-Source: AGHT+IE3dsaZsU0ynBFh7eT7zhvlqvKfwqYNj4h+qdo+iuTj8Q2UMpieGDvwPHTYdOFd6ciMJdrZ9A== X-Received: by 2002:ac2:51a5:0:b0:515:c615:ce23 with SMTP id f5-20020ac251a5000000b00515c615ce23mr5780599lfk.22.1711916955358; Sun, 31 Mar 2024 13:29:15 -0700 (PDT) Received: from umbar.lan ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id y25-20020a197519000000b00513cfc2a7aesm1237276lfe.71.2024.03.31.13.29.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 Mar 2024 13:29:15 -0700 (PDT) From: Dmitry Baryshkov Date: Sun, 31 Mar 2024 23:29:09 +0300 Subject: [PATCH v2 12/12] drm/imx: move imx_drm_connector_destroy to imx-tve MIME-Version: 1.0 Message-Id: <20240331-drm-imx-cleanup-v2-12-d81c1d1c1026@linaro.org> References: <20240331-drm-imx-cleanup-v2-0-d81c1d1c1026@linaro.org> In-Reply-To: <20240331-drm-imx-cleanup-v2-0-d81c1d1c1026@linaro.org> To: Philipp Zabel , David Airlie , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam Cc: Chris Healy , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, Dmitry Baryshkov X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2503; i=dmitry.baryshkov@linaro.org; h=from:subject:message-id; bh=5YQu6iei1O3icFERDmvk1l0kTnnJ0t2qf5um+94Fdg0=; b=owEBbQGS/pANAwAKAYs8ij4CKSjVAcsmYgBmCceQDf+olRh9QfALPc+aBKfyzH5lo75neZO7G 9G/c0G65EuJATMEAAEKAB0WIQRMcISVXLJjVvC4lX+LPIo+Aiko1QUCZgnHkAAKCRCLPIo+Aiko 1a3kB/9PCf+qZk6BU9uNm4Mq6b6l9aQ1snWLpd5Ocn28EkiTCxoVc7+x/jVRyrbJOf4CizSpcN4 ahurpK9t+VYswcda71cQTvEEn0yhiUyWAuDObsaFkm5tzVSAuS91s1JFeU+ya3lffWXzV6RqgGY CLSiOEl9XV1T6ncjZPjgioIMS7a+2QnMvzCaobKIqdp58Ku/IyhAdOk2CqnZEd6XjG1dNoeZacb qbGt9CrEp7uvvf7znqrphQ7pFAu1EjhOBPJqCLV8wJgJsgAwlOqyGLzVnjkyvEJF/gJp46VRISr C813XA47F0iXhSoBO/vRA3tmI3DiCh+Gb88qe3xGNAFnNCSn X-Developer-Key: i=dmitry.baryshkov@linaro.org; a=openpgp; fpr=8F88381DD5C873E4AE487DA5199BF1243632046A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240331_212921_214977_DA332988 X-CRM114-Status: GOOD ( 12.12 ) 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 imx-tve driver is the only remaining user of imx_drm_connector_destroy(). Move the function to imx-tve.c Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/imx/ipuv3/imx-drm-core.c | 7 ------- drivers/gpu/drm/imx/ipuv3/imx-drm.h | 2 -- drivers/gpu/drm/imx/ipuv3/imx-tve.c | 8 +++++++- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/imx/ipuv3/imx-drm-core.c b/drivers/gpu/drm/imx/ipuv3/imx-drm-core.c index 4cfabcf7375a..189d395349b8 100644 --- a/drivers/gpu/drm/imx/ipuv3/imx-drm-core.c +++ b/drivers/gpu/drm/imx/ipuv3/imx-drm-core.c @@ -34,13 +34,6 @@ module_param(legacyfb_depth, int, 0444); DEFINE_DRM_GEM_DMA_FOPS(imx_drm_driver_fops); -void imx_drm_connector_destroy(struct drm_connector *connector) -{ - drm_connector_unregister(connector); - drm_connector_cleanup(connector); -} -EXPORT_SYMBOL_GPL(imx_drm_connector_destroy); - static int imx_drm_atomic_check(struct drm_device *dev, struct drm_atomic_state *state) { diff --git a/drivers/gpu/drm/imx/ipuv3/imx-drm.h b/drivers/gpu/drm/imx/ipuv3/imx-drm.h index e01f026047de..0c85bf83ffbf 100644 --- a/drivers/gpu/drm/imx/ipuv3/imx-drm.h +++ b/drivers/gpu/drm/imx/ipuv3/imx-drm.h @@ -25,8 +25,6 @@ extern struct platform_driver ipu_drm_driver; int imx_drm_encoder_parse_of(struct drm_device *drm, struct drm_encoder *encoder, struct device_node *np); -void imx_drm_connector_destroy(struct drm_connector *connector); - int ipu_planes_assign_pre(struct drm_device *dev, struct drm_atomic_state *state); diff --git a/drivers/gpu/drm/imx/ipuv3/imx-tve.c b/drivers/gpu/drm/imx/ipuv3/imx-tve.c index b49bddb85535..a5118504b522 100644 --- a/drivers/gpu/drm/imx/ipuv3/imx-tve.c +++ b/drivers/gpu/drm/imx/ipuv3/imx-tve.c @@ -307,9 +307,15 @@ static int imx_tve_atomic_check(struct drm_encoder *encoder, return 0; } +static void imx_tve_connector_destroy(struct drm_connector *connector) +{ + drm_connector_unregister(connector); + drm_connector_cleanup(connector); +} + static const struct drm_connector_funcs imx_tve_connector_funcs = { .fill_modes = drm_helper_probe_single_connector_modes, - .destroy = imx_drm_connector_destroy, + .destroy = imx_tve_connector_destroy, .reset = drm_atomic_helper_connector_reset, .atomic_duplicate_state = drm_atomic_helper_connector_duplicate_state, .atomic_destroy_state = drm_atomic_helper_connector_destroy_state,