From patchwork Thu Jul 6 12:30:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 13303592 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 1432EC001DF for ; Thu, 6 Jul 2023 12:30:58 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D47B810E44A; Thu, 6 Jul 2023 12:30:44 +0000 (UTC) Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by gabe.freedesktop.org (Postfix) with ESMTPS id C17F410E3EA for ; Thu, 6 Jul 2023 12:30:37 +0000 (UTC) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id E43326606FC1; Thu, 6 Jul 2023 13:30:35 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1688646636; bh=5+0g34fw0wGVdF8pSXSyeJt5CPUOp79klTRlFXdGl4A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PXRdj/hwHQs2SS81BQtrJIekePJZYwkIN/n2Ikp2BxktX6eGrI213k29FdWmkIYe5 hVg7B2E/Qrmy3m27lgj54mi/lEmr9stGO4ZeuQRis4apiQFKZyfxTGtNOb/6JhhB6T s2hE7LiTsKshLGTET5+QLNk8OO40i9FCJsR1dg28ncRoyPLq0d3d9/K4EDZm2hb3YK m2qYk8qRFiQorjGMfTJTRHAyQK84SaUKmApKeDWu2THIKisZlKErE64VTNpSCfyd7/ pHJVaOU+Vj3+qugYlIlfliCc1QUQx0wcjwKF4MlwmMpbvvqDoLF9XAHRLEzGLoTGey g6G9Ds1ehO4og== From: AngeloGioacchino Del Regno To: chunkuang.hu@kernel.org Subject: [PATCH v4 7/9] drm/mediatek: dp: Use devm variant of drm_bridge_add() Date: Thu, 6 Jul 2023 14:30:23 +0200 Message-Id: <20230706123025.208408-8-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230706123025.208408-1-angelogioacchino.delregno@collabora.com> References: <20230706123025.208408-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: nfraprado@collabora.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, matthias.bgg@gmail.com, kernel@collabora.com, linux-arm-kernel@lists.infradead.org, angelogioacchino.delregno@collabora.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" In preparation for adding support for aux-bus, which will add a code path that may fail after the drm_bridge_add() call, change that to devm_drm_bridge_add() to simplify failure paths later. Signed-off-by: AngeloGioacchino Del Regno Tested-by: Chen-Yu Tsai --- drivers/gpu/drm/mediatek/mtk_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/mediatek/mtk_dp.c b/drivers/gpu/drm/mediatek/mtk_dp.c index eebcb32e67ee..6bc620aded45 100644 --- a/drivers/gpu/drm/mediatek/mtk_dp.c +++ b/drivers/gpu/drm/mediatek/mtk_dp.c @@ -2564,7 +2564,7 @@ static int mtk_dp_probe(struct platform_device *pdev) DRM_BRIDGE_OP_DETECT | DRM_BRIDGE_OP_EDID | DRM_BRIDGE_OP_HPD; mtk_dp->bridge.type = mtk_dp->data->bridge_type; - drm_bridge_add(&mtk_dp->bridge); + devm_drm_bridge_add(dev, &mtk_dp->bridge); mtk_dp->need_debounce = true; timer_setup(&mtk_dp->debounce_timer, mtk_dp_debounce_timer, 0);