From patchwork Sun Jun 2 12:04:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 13682817 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 A2548C25B74 for ; Sun, 2 Jun 2024 12:05: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: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=bflACeqAq/KJ7+ODsYE+oTodBVgfp9JDiTtU+hTEjeQ=; b=m6Kbfr/EV5e7Mu 7F1/9nsQKNuCl/jxBsAgwdpdctc9JFSBmba5yfG6nbhghXBEXVmTYl2VzuE9+xEfUjmu6HsvP2x6a YPki/gUKyMlKMWbzhoUgFDLYJ+iSUlZmtbbuwHz6Gyrv6PVkMw5Wigs9/PpYrJMt4vOEdJDHu/aqU 7PTXuHO32PSJo3xZXb+xhMOSGkYOOmFoms/UjccHq1Mo4f2lYttM6cOhqMof54z3AOauYbA4z2Ehd 3c8QHnqBIMk8mv1xmrVJoSvyLWWNZ1v7yRCDtO4so71ZVH3Jm49Y9O4IXaWltXEytvzbeZ7JxMmyg FYbRJfK0lhY5ASzX4khA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sDjxm-0000000EBs3-3tLe; Sun, 02 Jun 2024 12:05:26 +0000 Received: from mail-lf1-x12c.google.com ([2a00:1450:4864:20::12c]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sDjxJ-0000000EBQF-3wun for linux-arm-kernel@lists.infradead.org; Sun, 02 Jun 2024 12:04:59 +0000 Received: by mail-lf1-x12c.google.com with SMTP id 2adb3069b0e04-52b992fd796so216857e87.0 for ; Sun, 02 Jun 2024 05:04:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1717329896; x=1717934696; 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=kNuDl566fdESfLAQYfAX73LiPJqclp33YW6YrFo8/hQ=; b=Hzwo6Mgo0ooWFkXZq5aF/E7/2ZzQE0vMIFEfSvyuOS13XdAdqSRmNJ45fO5tBFrT8l VQdsP196doYrAaIKNh1hFST6NacrEHF+zNi3Flb6le1cmbzEpviG5hX3rfOyX8lR7i8f qc+j9We4IVJSwRsLd5KQy+iVSjj7xWjAXQbrPs1DzYzP1pVgKIi6njiAatES7/urzyQ+ 4L6vtdRT4jcaEO19XiKHC/AlIfVAl/zHD56Z+xx8yQdrr0neaZLHUCI7AhCedPeISRCu zFwi4SMqIpxIFh1DfAPODgPZkPFxaSatenV/pSH9fDAP0ORXAlQkcPrcLunGttPAJXgL F3Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717329896; x=1717934696; 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=kNuDl566fdESfLAQYfAX73LiPJqclp33YW6YrFo8/hQ=; b=aWbhP7KMS0l8HIe00eBN0BzCmU4aNmeuzsthhdj/JkPoFP8EjCMESk4ZGGevJHCg5H Kps764/gFufAJlPUYpz9mIcaYnZ6CXVJmmoVjVDcWk4GbJ7kADyQ6QMXKo8586QhTh58 UiM619zabEi1HqbOnIkXdvvnrdlEDpyMnitMsubyejzC1SyQ1+23AMVWOspvkupW0MBL dvBBZhzAARFfIlZTqKmvuf4XdeePxDXJhZd7TnLYhOByNYZZlbq3TBYKO0niI5OE+5uR mwJmXBC47vquJdRskKhnG6LVjQtOPv2EQ31PgfKJlR/vDISXxyxLDaMSqi4XrdgFO3CM kvHQ== X-Forwarded-Encrypted: i=1; AJvYcCUTyh5X0CO43SD5OlpWTlU/Fiz2iZ/pJJG6vvFLccBc55vbCxF73kmgpchXlk/dmOGZ4vu5nT6+Nhl9tET4K0ZxDlBaTO0bpxG4CvfLCTTJp2J3dPs= X-Gm-Message-State: AOJu0YzbZruOqhbyBjH6PZzPLnnSHYvHsvfElXc1wHkPIxx7qjoI/kMq dIyos0TlwvrtN0EnZVRNtUkGb1xhTRLsHT/y1YgUePLBKsRcKupJfTHaXhIkvsg= X-Google-Smtp-Source: AGHT+IEFQgWpWrVek9sgb57OqXvq4Yl2GmvGbIbFNiQhz8GQhgLZZKzZdXR7VkMjAFTMyvzTXG7Rfw== X-Received: by 2002:a19:c514:0:b0:523:70db:7a0f with SMTP id 2adb3069b0e04-52b8958b9fdmr4091009e87.8.1717329896464; Sun, 02 Jun 2024 05:04:56 -0700 (PDT) Received: from umbar.lan ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-52b8b56867fsm759398e87.44.2024.06.02.05.04.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Jun 2024 05:04:55 -0700 (PDT) From: Dmitry Baryshkov Date: Sun, 02 Jun 2024 15:04:52 +0300 Subject: [PATCH v3 12/12] drm/imx: move imx_drm_connector_destroy to imx-tve MIME-Version: 1.0 Message-Id: <20240602-drm-imx-cleanup-v3-12-e549e2a43100@linaro.org> References: <20240602-drm-imx-cleanup-v3-0-e549e2a43100@linaro.org> In-Reply-To: <20240602-drm-imx-cleanup-v3-0-e549e2a43100@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=h/DSMM9BfsUckdlfOnVl0fUleOjgfbtfRzHBaAfH+mc=; b=owEBbQGS/pANAwAKAYs8ij4CKSjVAcsmYgBmXF/eWV2GMqKPP+JRWmUQkel1cF728TylDcmgO 0eEmDycmaaJATMEAAEKAB0WIQRMcISVXLJjVvC4lX+LPIo+Aiko1QUCZlxf3gAKCRCLPIo+Aiko 1dhZCACRu+PPllOgalpri1YjKo6EeMiZwJWGWbZB7vOG0XyWYSRR5eOJXBxq7Dj/kYq1tegFmZ3 sXQtiS/j7TCmbhCYqvEG+QiVIv0VxmNuCjq9qOFsMBTD6/FUpIAzVeNrhl5Qy7mrMXjC1M6bHZ+ v6/8k3KX4MHbqfZRU5Dpp2zbGsEAc2rTMc1oDNLCYVtEGVj6iBBwBREE39J09ROUeymKQxN9zyL eUrLTC+oNnRZxVOhJCFH3vqAPavR2QAJ0efqynRhJ+JKGykNLo0kYI/5rrBb/NVGncTm86QrMCI xXuY1XxZTkkPPdY/sYjc+KccNcaJHNxc/1mFxsBUvQSY06WQ 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-20240602_050458_115227_EB1698CD X-CRM114-Status: GOOD ( 12.03 ) 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 Reviewed-by: Philipp Zabel --- 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 29f494bfff67..d46d07d25f51 100644 --- a/drivers/gpu/drm/imx/ipuv3/imx-tve.c +++ b/drivers/gpu/drm/imx/ipuv3/imx-tve.c @@ -305,9 +305,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,