From mboxrd@z Thu Jan 1 00:00:00 1970 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 0D496F34C49 for ; Mon, 13 Apr 2026 13:59:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References :Message-Id:Content-Transfer-Encoding:Content-Type: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=FiMsl19rJD1IVfeYhbmK871odM1dYpv4rqscGsKp4+E=; b=4kE6joEhyzHAahCkp9r8/aMnVe njQMmjDOjXSnn52uU2y4b4tO714xKbPaH3nylrs9nc1McFl+NTnU1zZD5ONdhHj/ohB7PRUycP/R4 AierwQkigRGEY3WQH9S+EsLNIF99mHdi3E6YtWU/vv7mbz84DAzLhrAc7/MYnQoEXU8CjNCjq5uhz Mlfq66DMESXLzlc99hylMYuqgGldokbJ7wPStz/dl/XtqID6m6H8VkhZRMyoZgEZ3NvvwoaT5jHW5 eHwiFBusDSNQk5hYiQx893vs7XM3EUklpVCe0XYYQymfCUz3if5Vagri/KQTQng8Hoae/kEWKekTQ 5YeDsCBA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1wCHod-0000000Fnjo-0BPO; Mon, 13 Apr 2026 13:59:03 +0000 Received: from smtpout-03.galae.net ([185.246.85.4]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1wCHoZ-0000000Fngy-05hD for linux-arm-kernel@lists.infradead.org; Mon, 13 Apr 2026 13:59:00 +0000 Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-03.galae.net (Postfix) with ESMTPS id 840DE4E429F0; Mon, 13 Apr 2026 13:58:57 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 5246E5FFB9; Mon, 13 Apr 2026 13:58:57 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id D67C91045001B; Mon, 13 Apr 2026 15:58:51 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1776088735; h=from:subject:date:message-id:to:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references; bh=FiMsl19rJD1IVfeYhbmK871odM1dYpv4rqscGsKp4+E=; b=E8vMd4rjXXppZok1PPM26OX2QRCpxqxDsHauysoy1TaWuc0RSVJCNNz0WLgRiTReuTeGli QFUsjDkpF6UD7xwtbrP2obOTgVtNfORZHiWSog3gxm9iDU8UGlfwipRHsgN9191h1hKhGS xEycHcRhVWqb75gBlb7yxHxuDaoVDMzmlY5XnZwlxcfHSgG2uXJeSSvvN24LMlAZUjNT7O LMURjH/hI1i1GKe3c8EkVoaZK0JpLM9pvLLlLdv/0R+jwQISt63bg5EFShLfTj1zucfRoL 47JVxnoCwFBmMJrT8EZ5UdYvCbipdT/4oBZ1sAXo+gIraE3fs8mcVPJL8dLgOg== From: Luca Ceresoli Date: Mon, 13 Apr 2026 15:58:34 +0200 Subject: [PATCH 02/10] drm/msm/hdmi: switch to of_drm_get_bridge_by_endpoint() MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20260413-drm-bridge-alloc-getput-panel_or_bridge-v1-2-acd01cd79a1f@bootlin.com> References: <20260413-drm-bridge-alloc-getput-panel_or_bridge-v1-0-acd01cd79a1f@bootlin.com> In-Reply-To: <20260413-drm-bridge-alloc-getput-panel_or_bridge-v1-0-acd01cd79a1f@bootlin.com> To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Rob Clark , Dmitry Baryshkov , Abhinav Kumar , Jessica Zhang , Sean Paul , Marijn Suijten , Xinliang Liu , Tian Tao , Xinwei Kong , Sumit Semwal , Yongqin Liu , John Stultz , Andrzej Hajda , Neil Armstrong , Robert Foss , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Tomi Valkeinen , Michal Simek Cc: Hui Pu , Ian Ray , Thomas Petazzoni , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, freedreno@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, Luca Ceresoli X-Mailer: b4 0.15.1 X-Last-TLS-Session-Version: TLSv1.3 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260413_065859_202947_03AF7A38 X-CRM114-Status: GOOD ( 10.23 ) 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 This driver calls drm_of_find_panel_or_bridge() with a NULL pointer in the @panel parameter, thus using a reduced feature set of that function. Replace this call with the simpler of_drm_get_bridge_by_endpoint(). Since of_drm_get_bridge_by_endpoint() increases the refcount of the returned bridge, ensure it is put on removal. Signed-off-by: Luca Ceresoli --- drivers/gpu/drm/msm/hdmi/hdmi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index 852abb2466f0..90e529b3d0c8 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -287,7 +287,7 @@ static int msm_hdmi_dev_probe(struct platform_device *pdev) spin_lock_init(&hdmi->reg_lock); mutex_init(&hdmi->state_mutex); - ret = drm_of_find_panel_or_bridge(dev_of_node(dev), 1, 0, NULL, &hdmi->next_bridge); + ret = of_drm_get_bridge_by_endpoint(dev_of_node(dev), 1, 0, &hdmi->next_bridge); if (ret && ret != -ENODEV) return ret; @@ -383,6 +383,7 @@ static void msm_hdmi_dev_remove(struct platform_device *pdev) component_del(&pdev->dev, &msm_hdmi_ops); msm_hdmi_put_phy(hdmi); + drm_bridge_put(hdmi->next_bridge); } static int msm_hdmi_runtime_suspend(struct device *dev) -- 2.53.0