Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp10630rdb; Mon, 22 Jan 2024 10:12:44 -0800 (PST) X-Google-Smtp-Source: AGHT+IHKx6vitcbf2hCUjUn8B4HKU09KXknMBES9mQNA2fnvLGtcS94cLgv81uqfhAH0hnRojgU3 X-Received: by 2002:ac2:4da7:0:b0:50e:d48b:7ff1 with SMTP id h7-20020ac24da7000000b0050ed48b7ff1mr2230164lfe.133.1705947164235; Mon, 22 Jan 2024 10:12:44 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705947164; cv=pass; d=google.com; s=arc-20160816; b=eexL5PPozIMAZycl/VKKijriU4+Zlp46UqvW2/+0yzZD4kSrdq0M7tWUcJ9GOePiYK 28yIvh5SF1YLdHtspbdvw7GBWZ/XTU9/daRSO9/+dzXZN7MSWzsxn1i1zzni8HxeAUCD 6XIFdNCG6+aafrGiETeJrY+i+UItV2H049PHj18wdoIReVs+DOh4WFSXduikwwd1kPxx lxlcWm8P9J8fwyjNCeY4hGnqDMoKnCaawQ93R/DeV6sYL2ggpVthEzfA6Dk+JW2QMiD+ s98CL4lt5UAT1x1WiYSUDQsEXpC9CfRxsm6/bkXe3EgG7PMBjZLaMwFunk4dagDu0Mrp KsEg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=FDs5RA9l/1YLjMhJ9/RhnqWe/iFg+T34uR8dnP0JYX4=; fh=tWGCbkeNpf8Tjb4339IJbPJO8k3eDPMCCyBWcUg5Gnk=; b=PdGPgwlImnuh4WGxy9V6z9/hnt/WjnJ+IeCs9bisp2gwmOLEvwZOty+W8KB8Fnc9Gw jKFNEVbHaIX/fJvFAMKi1cL3ehrK+LJQSq+tdvMvpPlx262at8A+4/nuXQifW72U8Ww+ JJ7a/ZZbmm1wzzuLWUIZPddp+LQyWtbtbphFUSH+Upqh5diekLo5CVtwti075XWEQQ64 aKmgyxF+KjRtlEnz5sNs2Rxu5/dmUBEEycHjIATt6Ci/DxrqO9X1u1S4JvsUC3Cx5EGo wohUjqBT4tpeZMvpL+Sz/2mJt6kSyhZWsRoDZ91XZyMjMGyIyS8j7fbCN/1aYwvbtOEN giow== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V6fINjAq; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-33810-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-33810-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id dv24-20020a170906b81800b00a28badcf374si11084192ejb.198.2024.01.22.10.12.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Jan 2024 10:12:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-33810-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V6fINjAq; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-33810-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-33810-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id B44C91F2FEE3 for ; Mon, 22 Jan 2024 18:04:02 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 126C362A16; Mon, 22 Jan 2024 17:25:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="V6fINjAq" Received: from mail-pf1-f179.google.com (mail-pf1-f179.google.com [209.85.210.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D8288629FC for ; Mon, 22 Jan 2024 17:25:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705944337; cv=none; b=Rg64aoK8UadSM2M8g5c5e+q3oihNMLjEWH1NI0oIl7/9BgVgOJlXTqMy/KFjg3O/WFCjRXcZO2HkS9dE9j+0D16Xrn4MW8dUEU5TDuhxrQtBCZ2OphqRSyTF63jFqnCyPE/YCftsKDp9qzNozJ+n5fshDyeIdxWXJXZcnnUMSEg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705944337; c=relaxed/simple; bh=gCpxvZ3Cr8PY8P8B+/AhrkttFfZIceXbRbsl7hJtitE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=B8exwAihtEPiITXhl3dOlUhdAUhTh2wLK8k0XaWwI/7zmh7eOwvzNXdDVLmG/sjSXy1xP95qy1rKvWH4QCmyNoAcY7/OPpPfgL0uzzjgqclkBoKgIWRHf54OXPswBrRmm1EElBEelhDpGBCkEIAWaAt6gQuh0s1HY0MILz0FwSc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=V6fINjAq; arc=none smtp.client-ip=209.85.210.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-6dbce74f917so1017358b3a.0 for ; Mon, 22 Jan 2024 09:25:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1705944335; x=1706549135; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=FDs5RA9l/1YLjMhJ9/RhnqWe/iFg+T34uR8dnP0JYX4=; b=V6fINjAqQDFSlLl/pgb9PtlLhcbrf3wsV3UwEdNDr/RO3tTg9obUPIU95P0pG+nipG sTzBMMn7RBfoP0Xuu7p8gg16GxeUuxDesUJCxJw1dhfipaQtRDN0dSi0e5PP6rwd/X3l zGFDI/3z2IzthzKSLVnUqF/p5OQPm63fE63ehdGBnuuhyNrkuKN70klKnaHVywTQ7h+x SVRumG537VZJbisWOdkaTTCnTx7onD63GAk1qb27efeOMHxUE6m6Wl2TU+20Dd0earPa W+e5PC6KISDcPeooGcFTXZtD2ueFew2Q/yuXqyYTF0nTBfuTn5cwiAULcew65bp2QEnT GJlw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705944335; x=1706549135; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=FDs5RA9l/1YLjMhJ9/RhnqWe/iFg+T34uR8dnP0JYX4=; b=PpxwwpbkAqBWX6lHv/Y+pG6yyi8a5248fto2EnPoVAD9UmQqHvaSZ4bdFcM5uUuGd3 LDsRKUsIV2mJ0h9BH/GqwMkIsO5i3p4GCHn4CO3hc2o2BLpgBelrtJLa3fSyacKo9Gc4 lf2lkKdObDm8tDP9t+iDELk+iUzgTqMiGa5L2+QehwT34jymqlK8MBm/kQFswQ0tNVYk KNH3Vdnl3B1ntEkHDnX6aZC8OSGtaZ7XWDtddiApCoS6qsYkbgl5pjZ6vXUlUbck5g3p o9Wk5hDPgsUmUau8tLQWsU3INKSDFX22iN7fbWv7w/UVsI5pik2RoEo/sKVcVT0od+hK 7X0Q== X-Gm-Message-State: AOJu0YxI53JRb6AVSU9X12sZA7bycEim6Jz2kqXDO0f/3ynToBaS5UDl IWzMc2PwKmKtcEu3OMa/Rcd2mz/vjUF0YKCn4fbQYBPxgVm0Rs6XtDqwhDVRQQ== X-Received: by 2002:a05:6a20:11a6:b0:19a:63:70dd with SMTP id v38-20020a056a2011a600b0019a006370ddmr1362052pze.36.1705944335124; Mon, 22 Jan 2024 09:25:35 -0800 (PST) Received: from thinkpad ([120.56.197.174]) by smtp.gmail.com with ESMTPSA id h3-20020a056a00218300b006dbd341379dsm3749903pfi.68.2024.01.22.09.25.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Jan 2024 09:25:34 -0800 (PST) Date: Mon, 22 Jan 2024 22:55:28 +0530 From: Manivannan Sadhasivam To: Johan Hovold Cc: Konrad Dybcio , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Johan Hovold , Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Krzysztof Kozlowski , Konrad Dybcio Subject: Re: [PATCH 1/3] arm64: dts: qcom: sc8280xp: Fix PCIe PHY power-domains Message-ID: <20240122172528.GE3176@thinkpad> References: <20231227-topic-8280_pcie_dts-v1-0-13d12b1698ff@linaro.org> <20231227-topic-8280_pcie_dts-v1-1-13d12b1698ff@linaro.org> <20231229170334.GA9098@thinkpad> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20231229170334.GA9098@thinkpad> On Fri, Dec 29, 2023 at 10:33:34PM +0530, Manivannan Sadhasivam wrote: > On Fri, Dec 29, 2023 at 12:24:55PM +0100, Johan Hovold wrote: > > On Wed, Dec 27, 2023 at 11:28:26PM +0100, Konrad Dybcio wrote: > > > The PCIe GDSCs are only related to the RCs. The PCIe PHYs on the other > > > hand, are powered by VDD_MX and their specific VDDA_PHY/PLL regulators. > > > > No, that does not seem to be entirely correct. I added the power-domains > > here precisely because they were needed to enable the PHYs. > > > > This is something I stumbled over when trying to figure out how to > > add support for the second lane pair (i.e. four-lane mode), and I just > > went back and confirmed that this is still the case. > > > > If you try to enable one of these PHYs without the corresponding GDSC > > being enabled, you end up with: > > > > [ 37.709324] ------------[ cut here ]------------ > > [ 37.718196] gcc_pcie_3b_aux_clk status stuck at 'off' > > [ 37.718205] WARNING: CPU: 4 PID: 482 at drivers/clk/qcom/clk-branch.c:86 clk_branch_wait+0x144/0x15c > > > > Technically this patch is correct. PHYs are backed by MX domain only and not > GDSCs. Only the controllers (PCIe, UFS, USB) are backed by GDSCs. The fact that > you are seeing issue with PCIe Aux clock suggests me that this clock may not be > applicable to the PHY but it needs to be enabled for working of the PHY somehow. > I'll try to find the details on how exactly it is needed. > > But if I get the answer like, "This clock is also sourced to PHY directly", then > we may need to add dual power domain for PHY (both GDSC and MX). > So I answer I got from Qcom is that this clock is only applicable to the PCIe controller and not PHYs. On some platforms, there is a separate PCIE_PHY_AUX_CLK coming from GCC that is used during L1SS state. I think that caused confusion while adding PHY support for followup platforms and folks just used PCIE_AUX_CLK since they couldn't find the actual PCIE_PHY_AUX_CLK. I've prepared a series to fix this mess, but I want to know how you end up seeing the above "clk status stuck at off" issue. Is there an actual usecase for powering up PHY without controller or you just experimented with it? - Mani -- மணிவண்ணன் சதாசிவம்