Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp630972pxb; Tue, 12 Apr 2022 09:30:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyN8OxLf7HqoKL9oQH5pqMPro0rneGisgi1hP7mjT/hvTMqYn/3x+6KknGDJ3TYD4s2grJJ X-Received: by 2002:a17:907:eab:b0:6dd:e8fe:3dc with SMTP id ho43-20020a1709070eab00b006dde8fe03dcmr34305625ejc.165.1649781052692; Tue, 12 Apr 2022 09:30:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649781052; cv=none; d=google.com; s=arc-20160816; b=HERodMq+UFta/XvFJERsTDu8ySICmo0HXS74aXYo/9W1UP9UZ0JgUQuFz0onPa/3XX B98JrOqzO1tVt3/+R6rLsTLuidnaRLHIPrP4XKhf7bNqxgW6bLx2eElfxh52JDUxooaX 4MHgCT7LmfLHRkaggkFlu0PR5UG2Wj4wjknUOaatrqZgPeDxSUSjGQMdPRLv+eIYZB63 XzsYGG4fafKPdlo4qpzQvGZ5gnNZT1vMx3Ykhr6iG52OC6WLPbjzG5W+o/pBO8RxMOQs MNwEYsrUoyci5255Vf/SiaGn8St48hQcLTNL4usti55kWUz+p76ujyT1vqdqPJbOsKOM qs2g== 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=/WwnNesPTf8Dg72nvsKVKosz6intO0Gr4fZ4BwrOcQ0=; b=cUBaDMs8OHho+Z8TdDBC0qcozHzm5RBygSLttmZVfJOx2pKBiZx+2ItDf+9zyGDW95 Wb+GjLYKLsvXFoZquo9UriWZTBEoZxXrpPWSBG6TemsGKARcNDAZRbOMfLBy8TdqSGvB P+MYwPMk9kYWvs9pz2ow1P+olRqHW/puEDeOjmfaVNTb8qCitr8W+hW00VLS1WTL30O5 fYG/egQRDoaFFnrNd4uxX8/CJzrgOAFSEIpJYAS1cz/JaXv0ncspu6foBerS629Spgv8 e84VL5d6DPM3TAOcYKgVEck5BUMUhAUkas30I4SgQUc5LRVFj5hhCZDambQu7deUyv5g ZamQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=btVkYfbe; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c1-20020a50cf01000000b0041c8d83d948si8791760edk.594.2022.04.12.09.30.23; Tue, 12 Apr 2022 09:30:52 -0700 (PDT) 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=@kernel.org header.s=k20201202 header.b=btVkYfbe; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346489AbiDKNdA (ORCPT + 99 others); Mon, 11 Apr 2022 09:33:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47374 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344372AbiDKNc7 (ORCPT ); Mon, 11 Apr 2022 09:32:59 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 187C0EBD; Mon, 11 Apr 2022 06:30:46 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A729160FAF; Mon, 11 Apr 2022 13:30:45 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0CB6BC385A5; Mon, 11 Apr 2022 13:30:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1649683845; bh=gUEFNz2ZvRfZ6XHal7LLowTMm6RR0s9wpCOWjkYj/78=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=btVkYfbeBEQVuTdjBp8B3BigqHcGf5HpRkLstQIBcH9LWLmRh5vsXIpGU0kALfJsg GsKeRk1/noyp4G95qkgYxpGqQZyUsBerE9nn97aTLhTMsaqwN79SSJcIB1fzwEnHQK ad7/sn5GWbzNqIHYmeloa6QFylpGlGN8QxgnfwG9IGl+8NpsxrUyqrP8cF71ycRJvm MzhlXcRErl7tMRQktqqQpLtY+WGszokeXTV6MBFutpTZ65mPWYkPO21USiXLMonxTN 4Eop22Qa3dln+5zaDE4gLm2tcAKGlCDahEoKx8sNecU/r6E9be3t4Gi/dYSQP169BZ zNhTBxsrNnI6w== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1ndu7q-0005UC-MX; Mon, 11 Apr 2022 15:30:38 +0200 Date: Mon, 11 Apr 2022 15:30:38 +0200 From: Johan Hovold To: Bjorn Andersson Cc: Rajendra Nayak , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RESEND 2/2] soc: qcom: rpmhpd: add sc8280xp rpmh power-domains Message-ID: References: <20220225054345.2479565-1-bjorn.andersson@linaro.org> <20220225054345.2479565-2-bjorn.andersson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220225054345.2479565-2-bjorn.andersson@linaro.org> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 24, 2022 at 09:43:45PM -0800, Bjorn Andersson wrote: > The Qualcomm sc8280xp platform has 8 power-domains. Add these, and their > relevant active-only variants, to the RPMh power-domain driver. As we discussed off-list, the sc8280xp apparently has 13 domains. Guess the commit message should be updated even if you don't expose all of these to Linux. > Signed-off-by: Bjorn Andersson > --- > drivers/soc/qcom/rpmhpd.c | 26 ++++++++++++++++++++++++++ > 1 file changed, 26 insertions(+) > > diff --git a/drivers/soc/qcom/rpmhpd.c b/drivers/soc/qcom/rpmhpd.c > index 58f1dc9b9cb7..71602eb824f7 100644 > --- a/drivers/soc/qcom/rpmhpd.c > +++ b/drivers/soc/qcom/rpmhpd.c > @@ -180,6 +180,11 @@ static struct rpmhpd mxc_ao = { > .res_name = "mxc.lvl", > }; > > +static struct rpmhpd nsp = { > + .pd = { .name = "nsp", }, > + .res_name = "nsp.lvl", > +}; > + > /* SDM845 RPMH powerdomains */ > static struct rpmhpd *sdm845_rpmhpds[] = { > [SDM845_CX] = &cx_w_mx_parent, > @@ -363,10 +368,31 @@ static const struct rpmhpd_desc sc8180x_desc = { > .num_pds = ARRAY_SIZE(sc8180x_rpmhpds), > }; > > +/* SC8280xp RPMH powerdomains */ > +static struct rpmhpd *sc8280xp_rpmhpds[] = { > + [SC8280XP_CX] = &cx, > + [SC8280XP_CX_AO] = &cx_ao, > + [SC8280XP_MX] = &mx, > + [SC8280XP_MX_AO] = &mx_ao, > + [SC8280XP_EBI] = &ebi, > + [SC8280XP_LCX] = &lcx, > + [SC8280XP_LMX] = &lmx, > + [SC8280XP_GFX] = &gfx, > + [SC8280XP_MMCX] = &mmcx, > + [SC8280XP_MMCX_AO] = &mmcx_ao, > + [SC8280XP_NSP] = &nsp, > +}; Commit 90c74c1c2574 ("soc: qcom: rpmhpd: Sort power-domain definitions and lists") recently sorted the other arrays. Sorting by address like you've implicitly done here makes it easy to compare with the firmware interface, but perhaps you want to sort alphabetically for consistency. Since there apparently are no users for active-only domains in the tree, perhaps they can also be added later. > + > +static const struct rpmhpd_desc sc8280xp_desc = { > + .rpmhpds = sc8280xp_rpmhpds, > + .num_pds = ARRAY_SIZE(sc8280xp_rpmhpds), > +}; > + > static const struct of_device_id rpmhpd_match_table[] = { > { .compatible = "qcom,sc7180-rpmhpd", .data = &sc7180_desc }, > { .compatible = "qcom,sc7280-rpmhpd", .data = &sc7280_desc }, > { .compatible = "qcom,sc8180x-rpmhpd", .data = &sc8180x_desc }, > + { .compatible = "qcom,sc8280xp-rpmhpd", .data = &sc8280xp_desc }, > { .compatible = "qcom,sdm845-rpmhpd", .data = &sdm845_desc }, > { .compatible = "qcom,sdx55-rpmhpd", .data = &sdx55_desc}, > { .compatible = "qcom,sm6350-rpmhpd", .data = &sm6350_desc }, Johan