Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp4980245rdb; Fri, 15 Sep 2023 20:24:16 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGL75HBvCMnvWAq/gmzpBfok8Rnv2hWnVKhlEFA2Ckxw3xZlgRQgeJ8Aarg7j+VHVyfkC4K X-Received: by 2002:a05:6358:1cb:b0:139:4783:5140 with SMTP id e11-20020a05635801cb00b0013947835140mr3403323rwa.16.1694834656248; Fri, 15 Sep 2023 20:24:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694834656; cv=none; d=google.com; s=arc-20160816; b=aXGnqdLY3ZxjuvEgJIBdYaU+j6VW3vDuvbLG60i+UlzR8TNXACgBr/igRf7XmMZAye DczhY5Dl8zep6IJHGVy5JamunwgKGb+I0tHBBCLeBu2ODfR4xC2wXOdWEqykbhy2K1nm y9COG1Jr/Uoqxenb41eFMwZqfaaXwsWUiR0RrcnhT2X2+9KqWzQ5pdR4uIbCqYaCRmd5 r2pFxWINrQhW0/NAMQ2aPWhDtlimh/Tbi8arc9V0b3Ndv+0U3szqmTg1wFIOyl9cRU5A djdSy+tRZeISt5OXv8PEYsJ2GYOJ/Xi5rujFdnyPE8zY+kkG7R/Yk6uo/vqGJ0DPHOiU XqeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:autocrypt :from:references:cc:to:content-language:subject:user-agent :mime-version:date:message-id:dkim-signature; bh=YouDa+ERRcXfsKD05SHv7uq2HbLul8fzNckpEFgl+38=; fh=hvPsiPqraR2RbXGHs80SGWsK+xTD02JxG9wPDeZceGg=; b=iOyo84mAl1NajbyU2ZJXkBadPkAWVJE1szPmfJwNUwHK2RU62hhf8hw3ZpXO7mlXJY iN3rCacksAw5DmEAZFN57ON3v3zVdiXYJQdT/1p2/lIjaEweLQmJNwr+fWKO6LOMhdPC 50xsoLqYqEF+exZQuFfBlkrOo8nd2XtY3zf1eZqhecOnKw/IoTlKduJNlGh+P8uvyhm6 /MuVdvryr1msAElxxSE9ec1A8+BcMpg9GZ9Ip3PJy7t1wNM/SMyFczhfvdlkVp8YjbZs UcSRp6z/LefjOEH30zHvt+9lvuiJLQuWAIW8mfWjfb2xrBEGc1x/LRykywwnSkYlQldF kRbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="A/rXRJ+5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 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 pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id g132-20020a636b8a000000b005775d4973e5si3943025pgc.728.2023.09.15.20.24.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Sep 2023 20:24:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="A/rXRJ+5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 37C1180BF1F1; Fri, 15 Sep 2023 17:57:02 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238522AbjIPAzs (ORCPT + 99 others); Fri, 15 Sep 2023 20:55:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50024 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238719AbjIPAzd (ORCPT ); Fri, 15 Sep 2023 20:55:33 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96D212733 for ; Fri, 15 Sep 2023 17:54:18 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id 38308e7fff4ca-2b703a0453fso44996601fa.3 for ; Fri, 15 Sep 2023 17:54:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1694825657; x=1695430457; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=YouDa+ERRcXfsKD05SHv7uq2HbLul8fzNckpEFgl+38=; b=A/rXRJ+5hj8kZa4RuChDDkIJtcazBhGC0MaUBkPsdLogNF5KaF8LJJ07/6fvpnJRi6 Jc072txH1x7ImV90wUQBnfsGU0rhB0gfb8RFRQ9o3PFxA1nHm661EX9L18pUUjsV3bvm gKTVBsmURcasuyxnH/7V/TEVlEIhXnbE9h7cCO5b4MFL17N9qKnUq+hgw0jPTyoLmXDb OgEsoUGl723pYIBipj4arNIINORb1Ud10xn/3IwD4ouUGORWVFCi817alll4cnHCxoi0 vP9+GXkR7AVa0QH7xq15RgExKOzwNlEqytzvWfECLmejltwg9XiBmJLrfYeSm7aT+VXk EL6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694825657; x=1695430457; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=YouDa+ERRcXfsKD05SHv7uq2HbLul8fzNckpEFgl+38=; b=lpzUB9KFJRs363pU0w6C0TwZqAKUWR09M6vhMZShnuuPtGQVmfNniLv3k11YxF8TGU d2826DONFCJ3zLukHSrtYlImUlAvJUbBXe/+91F35tTTnvJfjSKXKpmiBhNZjT9LaPk7 hqw8ARzncxwkIEyokePVmkz+kxfC36j16fpzZypwK4LVh9Gr2YTJpExRj6QC2nFBT4ZT dx8rNXQjhdmoy+zJ7wPG81u+SiDC9eYX7v4hUEpwVzcwlAWZBD/n+qSN0JfBlp97meCi jF3lrzkSKYWd428pbeXTeXxTayIH5nxtvqPdtLppQjaMV/GuDDeNUPIivND6468XoTtL CtvA== X-Gm-Message-State: AOJu0Yz+XPpUW4A0fBCZzEthPToUxKuqb+ll6w9wIVZesrJ8F7mgCdyS dUNJ2C62IQ9um/3ft3k59/pBeQ== X-Received: by 2002:a2e:3505:0:b0:2bd:10b7:4610 with SMTP id z5-20020a2e3505000000b002bd10b74610mr2594910ljz.25.1694825656782; Fri, 15 Sep 2023 17:54:16 -0700 (PDT) Received: from [192.168.37.154] (178235177186.dynamic-4-waw-k-1-1-0.vectranet.pl. [178.235.177.186]) by smtp.gmail.com with ESMTPSA id e10-20020a170906248a00b00993928e4d1bsm3046483ejb.24.2023.09.15.17.54.15 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 15 Sep 2023 17:54:16 -0700 (PDT) Message-ID: <49687bc6-7121-422c-99fd-e68dd46aae95@linaro.org> Date: Sat, 16 Sep 2023 02:54:14 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 00/53] icc-rpmh multi-RSC voting groundwork Content-Language: en-US To: Mike Tipton Cc: Georgi Djakov , Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , cros-qcom-dts-watchers@chromium.org, Marijn Suijten , linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <20230708-topic-rpmh_icc_rsc-v1-0-b223bd2ac8dd@linaro.org> <20230807215739.GA9621@hu-mdtipton-lv.qualcomm.com> <10520827-dc01-475c-b09a-35cefc9e0a62@linaro.org> <20230913012951.GA19284@hu-mdtipton-lv.qualcomm.com> <20230914023239.GA25147@hu-mdtipton-lv.qualcomm.com> <978fd46d-8142-41e6-9c62-df678018d6c2@linaro.org> <20230915160525.GA14240@hu-mdtipton-lv.qualcomm.com> From: Konrad Dybcio Autocrypt: addr=konrad.dybcio@linaro.org; keydata= xsFNBF9ALYUBEADWAhxdTBWrwAgDQQzc1O/bJ5O7b6cXYxwbBd9xKP7MICh5YA0DcCjJSOum BB/OmIWU6X+LZW6P88ZmHe+KeyABLMP5s1tJNK1j4ntT7mECcWZDzafPWF4F6m4WJOG27kTJ HGWdmtO+RvadOVi6CoUDqALsmfS3MUG5Pj2Ne9+0jRg4hEnB92AyF9rW2G3qisFcwPgvatt7 TXD5E38mLyOPOUyXNj9XpDbt1hNwKQfiidmPh5e7VNAWRnW1iCMMoKqzM1Anzq7e5Afyeifz zRcQPLaqrPjnKqZGL2BKQSZDh6NkI5ZLRhhHQf61fkWcUpTp1oDC6jWVfT7hwRVIQLrrNj9G MpPzrlN4YuAqKeIer1FMt8cq64ifgTzxHzXsMcUdclzq2LTk2RXaPl6Jg/IXWqUClJHbamSk t1bfif3SnmhA6TiNvEpDKPiT3IDs42THU6ygslrBxyROQPWLI9IL1y8S6RtEh8H+NZQWZNzm UQ3imZirlPjxZtvz1BtnnBWS06e7x/UEAguj7VHCuymVgpl2Za17d1jj81YN5Rp5L9GXxkV1 aUEwONM3eCI3qcYm5JNc5X+JthZOWsbIPSC1Rhxz3JmWIwP1udr5E3oNRe9u2LIEq+wH/toH kpPDhTeMkvt4KfE5m5ercid9+ZXAqoaYLUL4HCEw+HW0DXcKDwARAQABzShLb25yYWQgRHli Y2lvIDxrb25yYWQuZHliY2lvQGxpbmFyby5vcmc+wsGOBBMBCAA4FiEEU24if9oCL2zdAAQV R4cBcg5dfFgFAmQ5bqwCGwMFCwkIBwIGFQoJCAsCBBYCAwECHgECF4AACg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IH/DoYRfn jfFQSC8bffFjat7BQGFz4ZpRavkMUFuDirn5Tf28oc5ebe2cIHp4/kajTx/7JOxWZ80U70mA cBgEeYSrYYnX+UJsSxpzLc/0sT1eRJDEhI4XIQM4ClIzpsCIN5HnVF76UQXh3a9zpwh3dk8i bhN/URmCOTH+LHNJYN/MxY8wuukq877DWB7k86pBs5IDLAXmW8v3gIDWyIcgYqb2v8QO2Mqx YMqL7UZxVLul4/JbllsQB8F/fNI8AfttmAQL9cwo6C8yDTXKdho920W4WUR9k8NT/OBqWSyk bGqMHex48FVZhexNPYOd58EY9/7mL5u0sJmo+jTeb4JBgIbFPJCFyng4HwbniWgQJZ1WqaUC nas9J77uICis2WH7N8Bs9jy0wQYezNzqS+FxoNXmDQg2jetX8en4bO2Di7Pmx0jXA4TOb9TM izWDgYvmBE8= In-Reply-To: <20230915160525.GA14240@hu-mdtipton-lv.qualcomm.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.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 (pete.vger.email [0.0.0.0]); Fri, 15 Sep 2023 17:57:02 -0700 (PDT) On 15.09.2023 18:05, Mike Tipton wrote: > On Fri, Sep 15, 2023 at 03:43:27PM +0200, Konrad Dybcio wrote: >> On 14.09.2023 04:32, Mike Tipton wrote: >>> On Wed, Sep 13, 2023 at 10:31:49AM +0200, Konrad Dybcio wrote: >>>>> The applicable voters should likely be defined in the target-specific >>>>> headers, rather than the common qcom,icc.h. The bit range used for them >>>>> could be common, but each target may only support a small subset of the >>>>> total set of possible voters across all targets. >>>> I'm not sure how client drivers would then choose the >>>> correct path other than >>>> >>>> switch (soc) { >>>> case 8450: >>>> tag = QCOM_ICC_TAG_VOTER_8450_HLOS; >>>> break; >>>> case 8550: >>>> tag = QCOM_ICC_TAG_VOTER_8550_HLOS; >>>> break; >>>> ... >>>> } >>>> >>>> which would be unacceptable. >>> >>> The same general way it's handled for the endpoint bindings, which are >>> already target-specific. >>> >>> Any client drivers hardcoding the endpoint bindings in their driver >>> would have to include the appropriate, target-specific binding header >>> (e.g. qcom,sm8550-rpmh.h). That would only be possible if their driver >>> file is itself target-specific. Otherwise, it would have to pull the >>> endpoint bindings from devicetree. Or just use the recommended >>> of_icc_get() and let devicetree do everything for them. Same for the >>> target-specific voter tag bindings. >>> >>> Clients can also specify their tags in devicetree. They don't actually >>> have to call icc_set_tag() directly. For example: >>> >>> #include >>> >>> interconnects = <&mmss_noc MASTER_MDP QCOM_ICC_TAG_VOTER_DISP >>> &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_VOTER_DISP>; >>> >>> Then when they call of_icc_get() for this path it'll automatically have >>> QCOM_ICC_TAG_VOTER_DISP set for them. >> I think I'd skew towards the "define everything in the DT" approach. >> >> One thing that makes me uneasy to go on with this approach is the >> question whether there is a case in which we would want to switch >> from e.g. voting through DISP to voting through APPS (or similar) >> from within a single device. > > It shouldn't be common. But it could be done fairly simply by listing > paths for each different voter in the dt properties. > > interconnects = <&mmss_noc MASTER_MDP QCOM_ICC_TAG_VOTER_APPS > &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_VOTER_APPS>, > <&mmss_noc MASTER_MDP QCOM_ICC_TAG_VOTER_DISP > &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_VOTER_DISP>, > interconnect-names = "path-apps-voter", > "path-disp-voter"; Eeeeeh, I don't know.. this almost sounds like a patch-up solution to a problem that doesn't quite yet exist. I debated introducing a third interconnect cell for this, but I am not sure the added complexity is worth it. Having a global set of RSC-bound tags would be a "nice" and tidy solution.. Maybe we could even allocate like 24 bits to these, as I don't think you'll be introducing new buckets (or at least I hope you won't!). 24 is an obscene amount of RSCs to have, even counting virtual channels, so unless you folks have some dark plans to make all pieces of hardware powered completely separately from each other, I suppose I could ask for a pinky-promise to not exceed that number, ever :D Konrad