Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp2712589rdb; Wed, 4 Oct 2023 09:12:06 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH20SXOdAAlnkjW01HhTAPYv95EqjhW9o3AbRD+ZHVjtDq7oRH8eWF2O1rPpAGBzWVe7ja2 X-Received: by 2002:a05:6a21:a5a5:b0:153:a461:d96e with SMTP id gd37-20020a056a21a5a500b00153a461d96emr3383237pzc.47.1696435925957; Wed, 04 Oct 2023 09:12:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696435925; cv=none; d=google.com; s=arc-20160816; b=hciVjRiRpZS66Ib/azzH7gUcm6Rh5Y3loSpFs/dPsoQZc71h1Pg6DfVE6uJ3CvmOuw hjCT0kjnUv2vW48zOgod36faj3lJL9NWmXmTvIQS83qM4RLn7y9Ux6jiiy0wVhBg3Ls9 pW7P6ahbLI73gySt2kxOQhP5fcyM5xEMNdeeFTbnpIEQcIRAHDYFQe4dZX1Xt77jTf1U zSxG6bQ51PVlUqT9RRi0eL7y1Pz8Ptb4BmBSg/v5aIrcrGaMwfhCqFFv/3GE7LhApsDj JpJYUt/NxxWuvptbv6W/zC4/0t0KKBu4MqNcu5SLOBV94nFD7qIZYxVmQNNOA0Li17vB aGkQ== 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=y+bmeiGLNtgoAknMyrcYgvR3ty9DQseETlykNbO4Ds8=; fh=AWwrOG2kNvvkSnJRkj0dm4n3wNA2wRLtUnqULet8gPQ=; b=fhhPRgFoNQOSRSsBxUGKxLHudx4NL8/RJwiFbZOXClaWhi12ez+Htjy16LYlINIlmp 1GmqCV0aep3HUvOKH/8VhhTGdG8hb3T1yrKsCAVHsrffU4EZo+XJCWgb578MZgvHy/+N XFv+llF+T4HaKvey/1pzNlryqlB/fbLDgOoD5vgpY8FxMKJHKOe/Ns7CN1VZ48LjuC/x sg+Vyd8tffQ+gf93kckjGeF/L97zJpmGzfh4azGRPSvndBqCmEaOEhaexk8riUsiVWsJ wBU6CQTcuK2txESvDIUT9OlyHE1vtF+XgPZmxKDf6ZWsVVSLETKyS4EaTH34rHnpZtLE Xuhw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 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 snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id m18-20020a63ed52000000b0056546b5fef5si3872963pgk.561.2023.10.04.09.12.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Oct 2023 09:12:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 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 snail.vger.email (Postfix) with ESMTP id 1023A81065B6; Wed, 4 Oct 2023 09:12:05 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242776AbjJDQMF (ORCPT + 99 others); Wed, 4 Oct 2023 12:12:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44522 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243313AbjJDQMA (ORCPT ); Wed, 4 Oct 2023 12:12:00 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E08141703; Wed, 4 Oct 2023 09:11:44 -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 EA334C15; Wed, 4 Oct 2023 09:12:22 -0700 (PDT) Received: from bogus (e103737-lin.cambridge.arm.com [10.1.197.49]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id AB2543F762; Wed, 4 Oct 2023 09:11:42 -0700 (PDT) Date: Wed, 4 Oct 2023 17:11:40 +0100 From: Sudeep Holla To: Nikunj Kela Cc: cristian.marussi@arm.com, robh+dt@kernel.org, Sudeep Holla , 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: <20231004161140.uzqb4eapyo6gd7xm@bogus> 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> <1c58a05b-1337-0287-225f-5a73b4c6828e@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1c58a05b-1337-0287-225f-5a73b4c6828e@quicinc.com> X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_NONE 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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Wed, 04 Oct 2023 09:12:05 -0700 (PDT) On Tue, Oct 03, 2023 at 08:53:20AM -0700, Nikunj Kela wrote: > > On 10/3/2023 3:33 AM, 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. > > > > -- > > Regards, > > Sudeep > We are using Fast call FID. We are using completion IRQ for all the scmi > instances except one where we need to communicate with the server when GIC > is in suspended state in HLOS. We will need to poll the channel for > completion in that use case. I am open to suggestions. IIUC, for the sake of that one corner case, you have added the polling Kconfig and will be enabled for all the case and even on other platforms in a single Image. I think we could be something better, no ? Please share details on that one corner case. Is it in the scmi drivers already ? If so, specifics please. If no, again provide details on how you plan to use. We do have ways to make a polling call, but haven't mixed it with interrupt based calls for a reason, but we can revisit if it makes sense. -- Regards, Sudeep