Message ID | 1671642843-5244-1-git-send-email-quic_akhilpo@quicinc.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp3645064wrn; Wed, 21 Dec 2022 09:20:05 -0800 (PST) X-Google-Smtp-Source: AMrXdXtP1YphpyyeRSoaWi1qtOOM+V5l3XrlP2FSs70SGxxNMxpAPbwitg0JIGsjuwk06tq/4XfB X-Received: by 2002:a17:902:aa03:b0:18f:a447:2256 with SMTP id be3-20020a170902aa0300b0018fa4472256mr17120988plb.40.1671643205312; Wed, 21 Dec 2022 09:20:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671643205; cv=none; d=google.com; s=arc-20160816; b=nD4dQZ7x3WaHNU1cw8vx514meTQ4l9ATs6W4K1zweob+1k9uhBchnSzSUbIBrZZvgz Awj3erOlPnU9jMJCNjeleAR7BmGeyOAfMsJ10Ky+Trl4WjPNshWC9M6akevUv0ybrgl9 Ndl9Y/OgzUIrLISMbS7ugvU7HcOkseu/uaD3FfmTNX0llplz5Zm+kSYOhqmOwLoDoVen cf/B6J+VsSzz3AlSz2vmfa6uAtghI82+HSvY2U3x+Q/vKR+Eab3QdRf+0AY+3GBk6txD qfNW3TKNfx62uG3R1orPoRD1OvABUI5w3S1nGW+cDKIPVBGasqmfHVdIDjjIel1uFz15 VLKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=gBhHKx02h6Axdy+iRKzp80j+cKaack/GA8r6SHvEQjg=; b=JODrP/5BdS5/h5Sz1pqBUZ3BsRxmw0KWDSPEG0LgsBfGdfRrZGLV8e4PLBWBYI+bbX 1aNyVwwgt9tTWothjArhcRzkBfAdq2X3Yp8G+oxLUfn2cuAtAXjNKva4gRLyapsy7ZNR c7msVAKyub5mBeUrgWOk9XnI6FinjNYkAcxt7wB3kgKa5ptedJpRign9dEzwRQpjwLiN iAnOA+Ftznfa3v4q7YvalR0x0z17K5SpWSXfRUYW1ndWIWKZOGncDLcTesA4TMmeTk7B IsrVEKphpL+P8ac5Zsw0snqjaDmQBfQlZTVgIC+0iMWBTCXq/TcqZIEw2pCRSZetmrzs JcJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b="Hcq/uMmE"; 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=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ju20-20020a170903429400b001842f55e713si15681594plb.321.2022.12.21.09.19.52; Wed, 21 Dec 2022 09:20:05 -0800 (PST) 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=@quicinc.com header.s=qcppdkim1 header.b="Hcq/uMmE"; 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=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229844AbiLURQB (ORCPT <rfc822;pacteraone@gmail.com> + 99 others); Wed, 21 Dec 2022 12:16:01 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54176 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234799AbiLURP1 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 21 Dec 2022 12:15:27 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B1D87DAE; Wed, 21 Dec 2022 09:14:56 -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 2BLDqBvK018901; Wed, 21 Dec 2022 17:14:26 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=qcppdkim1; bh=gBhHKx02h6Axdy+iRKzp80j+cKaack/GA8r6SHvEQjg=; b=Hcq/uMmEZDfqTcvh88boF5kjeDCqSG+DcwHnt/fnoOnlJG3QDe4SgGBF2t/67L3e2FPU ZNrRm6kYOVdHoHfHgDhYRoNYnZ81ttlsTjafzlTkB+w0+l8uTTd1DbfhjkMy5UN2WmPq UGJjSMekoOuPsQLpVl/iBIZumje8tw6gkmTKB+1M9hGojm9CB49dcag7M/qmX3QzUzeP g7LCK8T5jpf2ODJ0qUqInUiDyNgQUZ+zMooGK8NEnq6yul0+qGGUqPd5ta1jJz+/u8Tt F30lPx84kDXdpbxRZfcAXNYWLMkgenaqLqny1tsSi3Sza5/uWFWOI1SigfFXoxL7AySC AA== Received: from nalasppmta03.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3mm2brrjcb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 21 Dec 2022 17:14:26 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA03.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 2BLHEOd0024082 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 21 Dec 2022 17:14:24 GMT Received: from hyd-lnxbld559.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.986.36; Wed, 21 Dec 2022 09:14:16 -0800 From: Akhil P Oommen <quic_akhilpo@quicinc.com> To: freedreno <freedreno@lists.freedesktop.org>, <dri-devel@lists.freedesktop.org>, <linux-arm-msm@vger.kernel.org>, Rob Clark <robdclark@gmail.com>, Ulf Hansson <ulf.hansson@linaro.org>, Bjorn Andersson <andersson@kernel.org>, Stephen Boyd <sboyd@kernel.org>, Philipp Zabel <p.zabel@pengutronix.de> CC: Akhil P Oommen <quic_akhilpo@quicinc.com>, Abhinav Kumar <quic_abhinavk@quicinc.com>, Andy Gross <agross@kernel.org>, Chia-I Wu <olvaffe@gmail.com>, Daniel Vetter <daniel@ffwll.ch>, David Airlie <airlied@gmail.com>, Dmitry Baryshkov <dmitry.baryshkov@linaro.org>, "Douglas Anderson" <dianders@chromium.org>, Geert Uytterhoeven <geert@linux-m68k.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Guenter Roeck <linux@roeck-us.net>, Kevin Hilman <khilman@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Konrad Dybcio <konrad.dybcio@somainline.org>, "Len Brown" <len.brown@intel.com>, Michael Turquette <mturquette@baylibre.com>, Pavel Machek <pavel@ucw.cz>, "Rafael J. Wysocki" <rafael@kernel.org>, "Sean Paul" <sean@poorly.run>, <linux-clk@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <linux-pm@vger.kernel.org> Subject: [PATCH v4 0/5] Improve GPU reset sequence for Adreno GPU Date: Wed, 21 Dec 2022 22:43:58 +0530 Message-ID: <1671642843-5244-1-git-send-email-quic_akhilpo@quicinc.com> X-Mailer: git-send-email 2.7.4 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-ORIG-GUID: A7scqoT25a38Jvcnb90YnPX4YI2t75XX X-Proofpoint-GUID: A7scqoT25a38Jvcnb90YnPX4YI2t75XX X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.923,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-12-21_09,2022-12-21_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=999 adultscore=0 priorityscore=1501 clxscore=1015 mlxscore=0 lowpriorityscore=0 malwarescore=0 spamscore=0 suspectscore=0 phishscore=0 bulkscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2212210143 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752844945578912623?= X-GMAIL-MSGID: =?utf-8?q?1752844945578912623?= |
Series |
Improve GPU reset sequence for Adreno GPU
|
|
Message
Akhil P Oommen
Dec. 21, 2022, 5:13 p.m. UTC
This is a rework of [1] using genpd instead of 'reset' framework. As per the recommended reset sequence of Adreno gpu, we should ensure that gpucc-cx-gdsc has collapsed at hardware to reset gpu's internal hardware states. Because this gdsc is implemented as 'votable', gdsc driver doesn't poll and wait until its hw status says OFF. So use the newly introduced genpd api (dev_pm_genpd_synced_poweroff()) to provide a hint to the gdsc driver to poll for the hw status and use genpd notifier to wait from adreno gpu driver until gdsc is turned OFF. This series is rebased on top of linux-next (20221215) since the changes span multiple drivers. [1] https://patchwork.freedesktop.org/series/107507/ Changes in v4: - Update genpd function documentation (Ulf) Changes in v3: - Rename the var 'force_sync' to 'wait (Stephen) Changes in v2: - Minor formatting fix - Select PM_GENERIC_DOMAINS from Kconfig Akhil P Oommen (4): clk: qcom: gdsc: Support 'synced_poweroff' genpd flag drm/msm/a6xx: Vote for cx gdsc from gpu driver drm/msm/a6xx: Remove cx gdsc polling using 'reset' drm/msm/a6xx: Use genpd notifier to ensure cx-gdsc collapse Ulf Hansson (1): PM: domains: Allow a genpd consumer to require a synced power off drivers/base/power/domain.c | 26 ++++++++++++++++++++ drivers/clk/qcom/gdsc.c | 11 +++++---- drivers/gpu/drm/msm/Kconfig | 1 + drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 46 ++++++++++++++++++++++++++++++++--- drivers/gpu/drm/msm/adreno/a6xx_gmu.h | 7 ++++++ drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 13 +++++++--- drivers/gpu/drm/msm/msm_gpu.c | 4 --- drivers/gpu/drm/msm/msm_gpu.h | 4 --- include/linux/pm_domain.h | 5 ++++ 9 files changed, 97 insertions(+), 20 deletions(-)