Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp4758496rdh; Wed, 29 Nov 2023 09:48:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IHt6IL8kKQxtZjl2wXKkzj93VqGCZdpyQ0XRQ7LaS4ZVRzGlkgR/yoUZ9HIDObX3+inpYA9 X-Received: by 2002:a17:90b:1b42:b0:285:a17f:9dba with SMTP id nv2-20020a17090b1b4200b00285a17f9dbamr16639930pjb.16.1701280089605; Wed, 29 Nov 2023 09:48:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701280089; cv=none; d=google.com; s=arc-20160816; b=YfplzZrfSov79IPjjoxIlAVXP6dyGGlS8HeS8Zgn2w0Hwt1IJIXMW+p7rX//xWdMfx afvsPslxpuurJR34LgRazRXg2hUQda+J7UG/qmGzvhiiWsD3nM779dm+N4QIUzS32pD8 lJNR+aeENM2hEdl2QAC1R6oDXCosx8GT+Wwf09JpbZFHLSfAhL9ZGvhpSHgS6VKcMA4o A3M02QN2seZfNHQYtZ37V+waasisHVbu6HXXjPeOGkIzKGZVZ1g9akv3BncErzsA2jn1 8wPwRjSEW+89hv6UM8qB+bQdwfuNZpQh/hCqqVXv2NQYOFUL+tmwKSyyR4mIfdfcFdNk 4FDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=3zeh5R65RoEi6uPniKX/YoBeDqb1N7/IYh+LS+VqK0M=; fh=WdvorNt9W2LCUPiGPsn75/bW5381IkpXRxF82JgZV7c=; b=DJLCHRX289GnTSHqUn/Y7eCUTmNWY45/AeneBvGWi7O2eV72fljXIdAkQU2vA8N4ZO sZFNRAA+MISvP9vFl+oaZcJoyQg9lrHuaylhUESnSg5kMNtfyfQRbAgMtVduYE8J1gT0 35f3i2li2jPvrkg4CR49zRCZZKeiTfcVKHNv2erCupg+NqZMj4OHfttuHgpWRMGhipap bpcwlc5BKmgGj1vOY366mHpf2Um+zInMaO9oJTnMfy2+OpFs0jbDc85VbwFPMRAiJ5zI 2jMeEhn5/28iWfqBcNqFJIh8BelV/wc2wkWJZD1VA82WMOIe5JG6XJn68qT2IszGatNM pxEQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=A48yuMKu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id ds23-20020a17090b08d700b00277e0d7163asi1746585pjb.32.2023.11.29.09.48.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Nov 2023 09:48:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=A48yuMKu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id C5FF780C2564; Wed, 29 Nov 2023 09:48:01 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231351AbjK2RrU (ORCPT + 99 others); Wed, 29 Nov 2023 12:47:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231256AbjK2RrP (ORCPT ); Wed, 29 Nov 2023 12:47:15 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 98071CA; Wed, 29 Nov 2023 09:47:21 -0800 (PST) Received: from pps.filterd (m0279868.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3AT5tjUh011806; Wed, 29 Nov 2023 17:47:13 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=qcppdkim1; bh=3zeh5R65RoEi6uPniKX/YoBeDqb1N7/IYh+LS+VqK0M=; b=A48yuMKukL7WrFA9Dh0zq6iQF9c5EsszapdZQPdGMyY8dDUFvNdHQajJ5hCs9tZ4ajR9 ucHoK2WDij2rO+eYH5PUwDLVw+OM31vZodzFNkX+vvmmZTwHW8BOzUR69VRcf9yxB/am Ihemk1QNUspUmEkRhELBksoaK1DgTn24YJI9oVuYpUZupYBqE1tUB+7v0cEdD+QSVpd3 nE3rdVbpRdUzN1E4S/FOUqPrTMnJp0xH/YHT1aXEg1gCq2q9Z1wR3t6XeIZzoB231j7J 7aH0WAlyvO4Xm3WW0y54f3WEvdTtdmoS5+21bLL66KN3bHR7+FLHAwfKkhmRGk2dcgMD rQ== Received: from nalasppmta01.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3unjdtksp0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 29 Nov 2023 17:47:13 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA01.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 3ATHlCpI023892 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 29 Nov 2023 17:47:12 GMT Received: from khsieh-linux1.qualcomm.com (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Wed, 29 Nov 2023 09:47:11 -0800 From: Kuogee Hsieh To: , , , , , , , , , , CC: Kuogee Hsieh , , , , , , , Subject: [PATCH v8 3/7] drm/msm/dp: use drm_bridge_hpd_notify() to report HPD status changes Date: Wed, 29 Nov 2023 09:46:46 -0800 Message-ID: <1701280010-32476-4-git-send-email-quic_khsieh@quicinc.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1701280010-32476-1-git-send-email-quic_khsieh@quicinc.com> References: <1701280010-32476-1-git-send-email-quic_khsieh@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: OqjqexBULez5Y6nGE7C6OvR4eS1YW8bQ X-Proofpoint-ORIG-GUID: OqjqexBULez5Y6nGE7C6OvR4eS1YW8bQ X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.997,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-11-29_15,2023-11-29_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 lowpriorityscore=0 suspectscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 impostorscore=0 priorityscore=1501 clxscore=1015 malwarescore=0 phishscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311060000 definitions=main-2311290135 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 29 Nov 2023 09:48:01 -0800 (PST) Currently DP driver use drm_helper_hpd_irq_event(), bypassing drm bridge framework, to report HPD status changes to user space frame work. Replace it with drm_bridge_hpd_notify() since DP driver is part of drm bridge. Signed-off-by: Kuogee Hsieh Reviewed-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dp/dp_display.c | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c index 56f8d91..c2e3247 100644 --- a/drivers/gpu/drm/msm/dp/dp_display.c +++ b/drivers/gpu/drm/msm/dp/dp_display.c @@ -340,26 +340,10 @@ static const struct component_ops dp_display_comp_ops = { .unbind = dp_display_unbind, }; -static void dp_display_send_hpd_event(struct msm_dp *dp_display) -{ - struct dp_display_private *dp; - struct drm_connector *connector; - - dp = container_of(dp_display, struct dp_display_private, dp_display); - - connector = dp->dp_display.connector; - drm_helper_hpd_irq_event(connector->dev); -} - static int dp_display_send_hpd_notification(struct dp_display_private *dp, bool hpd) { - if ((hpd && dp->dp_display.link_ready) || - (!hpd && !dp->dp_display.link_ready)) { - drm_dbg_dp(dp->drm_dev, "HPD already %s\n", - (hpd ? "on" : "off")); - return 0; - } + struct drm_bridge *bridge = dp->dp_display.bridge; /* reset video pattern flag on disconnect */ if (!hpd) { @@ -373,7 +357,7 @@ static int dp_display_send_hpd_notification(struct dp_display_private *dp, drm_dbg_dp(dp->drm_dev, "type=%d hpd=%d\n", dp->dp_display.connector_type, hpd); - dp_display_send_hpd_event(&dp->dp_display); + drm_bridge_hpd_notify(bridge, dp->dp_display.link_ready); return 0; } -- 2.7.4