Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp784468pxb; Mon, 25 Oct 2021 18:56:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyfaeX44zMQHj9xg4Uovlz3K2Pfz8nULDfGLQn1mdl6ZgN2kToukDGzivD8efSSkn5wGFLf X-Received: by 2002:a17:907:72d0:: with SMTP id du16mr27252434ejc.226.1635213393905; Mon, 25 Oct 2021 18:56:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635213393; cv=none; d=google.com; s=arc-20160816; b=i00KIQerF4TnehiSYnBn/Hn3In4/8NK0K6mUVAsctIAlRzfviYf0MqtSrir1d1lBXm Ba7htZozYYCJTsxt+zVIfUBwlsmgUjSJ8PrXztIZTaNSbKFsr/LSanUqlOLLfZmy0+E+ 8OdhSrRFbHk6akrKkg/D3bd2Q7+SfmIWAhBzlEtwhgLIwtn15JVnp/weEbm/KqJbI2Dm E9avt2IN+7fo+wz77c4UMU03tc4YcLG6eA4U1xwRFr6K1tLwvA9awlJaadrtpr/wBJEZ c+d3xkZNCUQeTJsx/Eap0o6VMhNociJuCA6r0RW3FUj7wWWoKduKfJieYa3tCS39+4us m6SQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=FGNc9Tx8g5/v6KFaaId5VnO2l2Gb29zLqsK+20u4jlQ=; b=kouUscK9M9LUPo9x1fPc+HGeAQk6QsYVOyQIHUx6yI3QGg7if52fTEocURiHdhQCMZ 7tp+CF+v11eoPK1OM5Li9cZKllD2CxLOqySGBWAvA9JMIk623/1+NUCMuRnBliXyRJHl g+bJWko1zSp8KUauVvVQigsO5gp4h4ZeMqlkYuTolwLx4ES+Hkr74jZ+UWwrWrP1qljP Ko9NB64qBErhOKRnO7QUIh0KEBYIX2tAfiJJ9j0aiBMuer9QTHWbMC90Q0UWHnrLC7Re 3l5dB2GP0uWvPYWgqXA8PGyWTPDsJTBtoMHWSKqTavAc2j81/mKBBzAcGxX1U13IaeCB H4OQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cJ3SgI09; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y7si36036385edd.521.2021.10.25.18.56.10; Mon, 25 Oct 2021 18:56:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cJ3SgI09; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232997AbhJYVoK (ORCPT + 99 others); Mon, 25 Oct 2021 17:44:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55312 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232895AbhJYVoJ (ORCPT ); Mon, 25 Oct 2021 17:44:09 -0400 Received: from mail-ot1-x334.google.com (mail-ot1-x334.google.com [IPv6:2607:f8b0:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B2ECC061767 for ; Mon, 25 Oct 2021 14:41:46 -0700 (PDT) Received: by mail-ot1-x334.google.com with SMTP id w12-20020a056830410c00b0054e7ceecd88so16906013ott.2 for ; Mon, 25 Oct 2021 14:41:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=FGNc9Tx8g5/v6KFaaId5VnO2l2Gb29zLqsK+20u4jlQ=; b=cJ3SgI091BISPRXBiE8q+NoMzCMMO7TE3mUjnVUSZyyTM/2HdEVTjjMyq1UXYuMO/I 9qbPtU9k5GfpLfM8F5+H9jcEfr/yhky4VTwQKbUFixO2j+WJbmYLLbSskU78vG9M67gX fEvF1LXQw9Avk5tv4b51z16nbHxwj5vIdMelwpLPvEfeK4GaaQHo9EdS/1qo7r/rwV2s FPDNv8jCkgsJnDCsSVlF2pUZ+2Eged6qJeAVqKkpDWh5KjAgHW0qvj7PcQd2taipNnoZ 9qMAgV881ohcmD70JM1ccV+heo10pUPygClUkcx53B4MuxQl5H8u/jc/gnMlmfXu4YcC C8cw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=FGNc9Tx8g5/v6KFaaId5VnO2l2Gb29zLqsK+20u4jlQ=; b=Ef+R4ZILIqwJMBHrSgjgTGMxdHv1gNIMwMN0llQOMJ+o0LGXvjQLeobFGo8QYnk3UR PuPqClS5fQ+3ciVxTTGXDKyozGsNGTev6xQLVPY+3Y537PxT/1p7LjdnEDIz0tt+u+WN pctvgkXuWi4vWAnZVjYN0hWXJp/huXM/hWE1RnvRadi9EPYAPBYJe8HmTV0vXUFUgnXE 2QJqQuC1WPyxd9i/T+ql8cL0fIuOuvpY4BaC4dO8Xn+Iyr2rZsVhbzGNuaY9U4upOm9b Xw1D2+/S4jQ9IbIhCEWAb/qN016aqYauiAgtvpoaUVe6RmLwhlvDQjXFpcdK/2ZKXqMk BITQ== X-Gm-Message-State: AOAM531vjhLNpeDlKyCofwx8AB+bZv/Huabkc+hWxRSTBqoE7sM1DelM UbMUvjh05Nq1oKp4yT7khvj4OQ== X-Received: by 2002:a9d:704d:: with SMTP id x13mr15188704otj.4.1635198105567; Mon, 25 Oct 2021 14:41:45 -0700 (PDT) Received: from ripper ([2600:1700:a0:3dc8:205:1bff:fec0:b9b3]) by smtp.gmail.com with ESMTPSA id s20sm4306440oiw.17.2021.10.25.14.41.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Oct 2021 14:41:45 -0700 (PDT) Date: Mon, 25 Oct 2021 14:43:23 -0700 From: Bjorn Andersson To: Stephen Boyd , Viresh Kumar , Ulf Hansson Cc: Sandeep Maheswaram , Rob Herring , Andy Gross , Greg Kroah-Hartman , Felipe Balbi , Doug Anderson , Matthias Kaehlcke , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, quic_pkondeti@quicinc.com, quic_ppratap@quicinc.com Subject: Re: [PATCH v2 1/3] dt-bindings: usb: qcom,dwc3: Add multi-pd bindings for dwc3 qcom Message-ID: References: <1635152851-23660-1-git-send-email-quic_c_sanm@quicinc.com> <1635152851-23660-2-git-send-email-quic_c_sanm@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon 25 Oct 13:17 PDT 2021, Stephen Boyd wrote: > Quoting Bjorn Andersson (2021-10-25 12:10:35) > > On Mon 25 Oct 02:07 PDT 2021, Sandeep Maheswaram wrote: > > > > > Add multi pd bindings to set performance state for cx domain > > > to maintain minimum corner voltage for USB clocks. > > > > > > Signed-off-by: Sandeep Maheswaram > > > --- > > > v2: > > > Make cx domain mandatory. > > > > > > Documentation/devicetree/bindings/usb/qcom,dwc3.yaml | 8 +++++++- > > > 1 file changed, 7 insertions(+), 1 deletion(-) > > > > > > diff --git a/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml b/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml > > > index 2bdaba0..fd595a8 100644 > > > --- a/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml > > > +++ b/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml > > > @@ -42,7 +42,13 @@ properties: > > > > > > power-domains: > > > description: specifies a phandle to PM domain provider node > > > - maxItems: 1 > > > + minItems: 2 > > > + items: > > > + - description: cx power domain > > > + - description: USB gdsc power domain > > > + > > > + required-opps: > > > + description: specifies the performance state to power domain > > > > I'm still worried about the fact that we can't just rely on the USB GDSC > > being a subdomin of CX in order to just "turn on" CX. > > > > Afaict accepting this path forward means that for any device that sits > > in a GDSC power domain we will have to replicate this series for the > > related driver. > > > > I suspect the problem is that it's not just "turn on" but wanting to > turn it on and then set the performance state to some value based on the > clk frequency. I don't see an opp-table involved, just the required-opps for the purpose of turning CX on a little bit more. Perhaps I'm missing something here though. > Maybe the simplest version of that could be supported > somehow by having dev_pm_opp_set_rate() figure out that the 'level' > applies to the parent power domain instead of the child one? Having the performance_state request cascade up through the GDSC sounds like a nice solution; I've not looked at the code to see if this is feasible though. > Or we may need to make another part of the OPP binding to indicate the > relationship between the power domain and the OPP and the parent of > the power domain. I suspect this would be useful if a power-domain provider needs to translate a performance_state into a different supply-performance_state. Not sure if we have such case currently; these examples are all an adjustable power-domain with "gating" subdomains. PS. I think we have the same problem in the display subsystem, the sub-blocks are powered by MDSS_GDSC, which is a subdomain of MMCX. We trust the parent mdss node to keep the GDSC powered and specify MMCX as the power-domain for the children, so that we can affect their levels by respective opp-table. Regards, Bjorn