Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp1870522rdb; Tue, 3 Oct 2023 03:51:12 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF9DeVkjO15CTCihSvNtQf4j7vmtIZ4uvBdrUCf3u8cc758nWJlUTkyfo569iHCGRTPBtGI X-Received: by 2002:a05:6358:52c4:b0:134:c8cb:6a00 with SMTP id z4-20020a05635852c400b00134c8cb6a00mr18004752rwz.12.1696330272410; Tue, 03 Oct 2023 03:51:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696330272; cv=none; d=google.com; s=arc-20160816; b=DMkOluFWa/ndvbX1ImPkd5OEyDEoClZF4itsLn3lVc4pzoFV9GEbg+T8w9sWpkpsKM CHt6pnEi9BXIn9BxN6onttovPVZEAm6mKv3qpIDyRpK421mpM06z4Ccxt3UunH7KmYIe KCKsdxCNRcbj4HkKxR6OgTUYecPRu3WyoN380aN4DAccsy8p6dJE8V3ISAB0mvaNmfAp lDMYyIyoCu6Jc8Zvy/kjNVYAzUDIw2kcntvZMRR+VOSTEkfhOzsKnrQGhFrCP/mA0Fqq WkEUhsEhQ7aVjuxeU8HbDYGwLEBgPN0p5aM6E1oOBQyKemNKdgHZG6WEl/xPxJiP/z72 PI9Q== 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; bh=y8VXMQbWfNHKudqVq/a5CmVrHDYhK9OZh62HVtRuS5A=; fh=63Ayw8rOKUtA4EZXRc1C8uEFxkwknwpvg2AoVHwP2yg=; b=I/13RcHUt68O4sCaDT4WvVEvosAvLmU9HmiYObiF/ZqFAZy1LOqRAMb/XL2Cwrm3P/ ueO8LcWYNCwMVCBYU6d9sEdM0zz3GG2B9QObInI4R78mFNqFvtQtFE3PihkBpdZwPND8 YsTN4+RAPEH/IAZOguCvHTX5Nls/du4FIxYznbKKa4nzFIlfPVXmvPAkfusUfZ/o/UNB my0sNoCMqVcT3TIBcVBSmBOSBO4rxWy5RCy0yUoeV72lWRwiZA95rCQQkh9b+gX0P8m8 +3uKa7GReBn0YabKc0A0bsRrWi3o1cUMNiektJbSqn3PONMeELhsko3EyuIu25MbQsUW cLpA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id w3-20020a636203000000b00573fe49ad3esi1139904pgb.672.2023.10.03.03.51.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Oct 2023 03:51:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id BE56680206F8; Tue, 3 Oct 2023 03:51:09 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231173AbjJCKu5 (ORCPT + 99 others); Tue, 3 Oct 2023 06:50:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38664 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231928AbjJCKuy (ORCPT ); Tue, 3 Oct 2023 06:50:54 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id A60B0BF; Tue, 3 Oct 2023 03:50:50 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5E60BC15; Tue, 3 Oct 2023 03:51:28 -0700 (PDT) Received: from pluto (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 602633F5A1; Tue, 3 Oct 2023 03:50:48 -0700 (PDT) Date: Tue, 3 Oct 2023 11:50:46 +0100 From: Cristian Marussi To: Sudeep Holla Cc: Nikunj Kela , robh+dt@kernel.org, Brian Masney , krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: Re: [PATCH v4 1/4] firmware: arm_scmi: Add polling support for completion in smc Message-ID: References: <20230718160833.36397-1-quic_nkela@quicinc.com> <20230911194359.27547-1-quic_nkela@quicinc.com> <20230911194359.27547-2-quic_nkela@quicinc.com> <20231003103317.pjfmf6uisahowmom@bogus> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231003103317.pjfmf6uisahowmom@bogus> X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.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 (groat.vger.email [0.0.0.0]); Tue, 03 Oct 2023 03:51:09 -0700 (PDT) On Tue, Oct 03, 2023 at 11:33:17AM +0100, Sudeep Holla wrote: > On Mon, Sep 11, 2023 at 12:43:56PM -0700, Nikunj Kela wrote: > > Currently, the return from the smc call assumes the completion of > > the scmi request. However this may not be true in virtual platforms > > that are using hvc doorbell. > > > > Hmm, it is expectation from SMCCC for the fast calls. Is you HVC FID > not a fast call. AFAIK, only TOS use yielding calls. Are you using them > here ? If not, this must complete when the SMC/HVC returns. We added > support for platforms indicating the same via interrupt. > > I would like to avoid adding this build config. Why does it require polling ? > Broken firmware ? I would add a compatible for that. Or if the qcom always > wants to do this way, just make it specific to the qcom compatible. > > I would avoid a config flag as it needs to be always enabled for single > image and affects other platforms as well. So please drop this change. > If this is absolutely needed, just add additional property which DT > maintainers may not like as it is more like a policy or just make it > compatible specific. > Not sure if it could be acceptable or controversial, BUT if there is the need somehow to support polling for yielding calls (depending on the location of the SCMI server), should not we think about doing this by just looking up dynamically the fast-call bits in the provided FID ? Why we need another binding, given that the FID is currently already statically provided by the DT itself (via smc-id) or dynamically by the hypervisor at setup by the changes in this series and the SMCCC spec clearly defines how the IDs are supposed to be formed for fast-atomic-calls ? This way we could enforce the compliance with the SMCCC spec tooo... ...for sure it would require a bit of work in the core, though, given the const nature of some of this structures. Thanks, Cristian