From patchwork Thu Mar 30 14:16:30 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: 77197 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1166997vqo; Thu, 30 Mar 2023 07:25:56 -0700 (PDT) X-Google-Smtp-Source: AK7set/ErX4wuxVD7CPrNkP0G1FNkdvIKn2Ri3Nah/L+KPb8VdA0sh5q7zJZ0WVsA5796ux9oUak X-Received: by 2002:a05:6a20:a82a:b0:db:1b41:704 with SMTP id cb42-20020a056a20a82a00b000db1b410704mr18817217pzb.16.1680186356095; Thu, 30 Mar 2023 07:25:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680186356; cv=none; d=google.com; s=arc-20160816; b=Kcz3U0adPLUgR7OgkwPo62a66oxoWPL4g4m+pR9eGxhkF63bvTxQ4C99qRfAZtBZJr 9XEyhBcjWoXkYgs2gVPFM9mlGSC21rEbxIKAi7yPznzCQZzbmbx7NtBsZQpk9LjAQyO0 vMZTdID3bqh7OhkDzX7ZNss8CJS8KeYQNluuih9esc/q4qI/LtxN6j4i7PDF9aQeV+FC Bo6bQhZKfTVAJ+uGG2j6eXge2+sgK62gQZycEqVVTE42wsaMTrBA+oB3e1of2BgOz8dN XWYmL3JC9UsGdfdRViiE/Ahx4TrfTlLjOzhSYESDL5MATMzL1OQNGjF7SsPv6S17tyHj QpDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=FPL/NFW6a4XbVx65QKR0eZskSslmSBbVywRw1jCRzh4=; b=Ifszc6YpBfQciwMFRrehRIIY/OPT7kM3i8mXhNkETNyWO6K425QWtficfQ0aVYozxD 4mPqA5Cl5NElpzlb1jmDxPTTGs5uLJkEeXc9QcwKbfoq+Jed6ecZWACAyK5cRSliP9FL P62vcPjPm4lXHgC8VH/I4GlWWuwLje4+GjCoLZJwgzqR4W4wKTLutseW7OP8eMYIitE3 rE7wX6xXX3ghgiTLeFUFELc0cDU7cPYzhWuuByCn/yeEakaLgMKywhOYqTEHFi8qqpKI 5xAy60UGrV1+fJX2b45wlOU8B9UjjwnkZNuRVXr9n9IGWGx5GKNg9OIMtMM5IpGI7l3J J+tg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=aK3ZHmDB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u63-20020a638542000000b00513234112acsi15378482pgd.888.2023.03.30.07.25.42; Thu, 30 Mar 2023 07:25:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=aK3ZHmDB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232356AbjC3ORG (ORCPT + 99 others); Thu, 30 Mar 2023 10:17:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232280AbjC3OQq (ORCPT ); Thu, 30 Mar 2023 10:16:46 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CCA8C5FE5 for ; Thu, 30 Mar 2023 07:16:44 -0700 (PDT) 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 6D5746603191; Thu, 30 Mar 2023 15:16:41 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1680185802; bh=/+IRk8GyWs1c9yVT0iTCxo8DT1414PGgt9mTBDTdxe0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=aK3ZHmDBVuEE2y80vMNCLAu6pwbfIkiUbL6aB4ukEEV+bjKDFx4xHQDIpmj7woNhm qrpd0m5OYgs86EzB8GKfAnLOVxB4fDmC+24RMfnCc2o2S1N2grVnj39w6HZga+2/1y VU1vFAwybwNulwZ4ibH9HlEQqQnekLBOHnigwSQdsMo5Bm4i0QL+klWEC5NPzoSxo1 X3xcKSN2TxINeDjkb2YsCfxdJhh5DJa63YxP71NoERP/VpsGCPtp9oxZIoZgM0GJlC GHiye2YoUQMFPlc8CTiQrDkqjH0wC1mGGIyvGu6VfdWGU/1XrM3OirRI3tinrlos16 0sZF23fDOPXlw== From: AngeloGioacchino Del Regno To: chunkuang.hu@kernel.org Cc: p.zabel@pengutronix.de, airlied@gmail.com, daniel@ffwll.ch, matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com, dri-devel@lists.freedesktop.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@collabora.com, wenst@chromium.org Subject: [PATCH v1 7/8] drm/mediatek: dp: Use devm variant of drm_bridge_add() Date: Thu, 30 Mar 2023 16:16:30 +0200 Message-Id: <20230330141631.190528-9-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230330141631.190528-1-angelogioacchino.delregno@collabora.com> References: <20230330141631.190528-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1761803088561590951?= X-GMAIL-MSGID: =?utf-8?q?1761803088561590951?= 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 --- 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 6aaf162a6bfe..62d53c4b3feb 100644 --- a/drivers/gpu/drm/mediatek/mtk_dp.c +++ b/drivers/gpu/drm/mediatek/mtk_dp.c @@ -2565,7 +2565,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);