From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D5704C4828E for ; Fri, 2 Feb 2024 10:57:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=6jcLWv6x442AHxtTfMacURANVL12bk889cyz/iBxzvw=; b=ySsDdA47A2AuA4 yDlAu+eqQ1fXNb7bqXiOrdk7IMTAcyrmqZvRyYXP2bVquHFkW8+F5raYkt76yaE9lqTeHULJ4PFy5 zCRVYRO6Na8Shj2oGEDybv+OQGUJwiOEm6nA9A8zCnSJ8D44ZxUEvvkgaXCMVUALAj0NJGBiOg/8C J/SWy0J3om2NleGnrXuUw2cj8xtagizsjtD9aYxNIGdsL3g7NkBZZAJP+Gg2gKOXxKS0nLpN18gaR ebBj+229kfCLvoE3pri4zXm2KJL858T1ZYNZrmZBMsMne70gAI2qPM/PiLxyyqGaJzmk2pPKLWytG oej9auiq5h/XJn35RgHg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rVrEE-0000000BDcQ-2yk7; Fri, 02 Feb 2024 10:57:02 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rVrEB-0000000BDaT-1dPv; Fri, 02 Feb 2024 10:57:01 +0000 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 E2B1EDA7; Fri, 2 Feb 2024 02:57:36 -0800 (PST) Received: from pluto (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1895D3F738; Fri, 2 Feb 2024 02:56:52 -0800 (PST) Date: Fri, 2 Feb 2024 10:56:50 +0000 From: Cristian Marussi To: Pin-Chuan Liu Cc: Sudeep Holla , Matthias Brugger , AngeloGioacchino Del Regno , wsd_upstream@mediatek.com, cylen.yao@mediatek.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH v2] firmware: arm_scmi: Avoid to call mbox_client_txdone on txdone_irq mode Message-ID: References: <20240201095754.25374-1-flash.liu@mediatek.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240201095754.25374-1-flash.liu@mediatek.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240202_025659_500075_83851429 X-CRM114-Status: GOOD ( 14.50 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Feb 01, 2024 at 05:57:52PM +0800, Pin-Chuan Liu wrote: > On txdone_irq mode, tx_tick is done from mbox_chan_txdone. > Calling to mbox_client_txdone could get error message > and return directly, add a check to avoid this. > > Signed-off-by: Pin-Chuan Liu Hi Pin-Chuan, thanks for this, it was indeed sort of on my todo-list too, to allow MHUs equipped with Tx-Ack IRQ to work with SCMI. Having said that, this looks good to me in general, my only pain points are: the fact that we have to peek into the controller structures to know how it is configured, BUT I wouldn't know how to do it in any other way in fact as pof now...; and the fact that there is a constant runtime conditional check for each message sent even though the tx_ack irq presence can be detected once for all at setup time, BUT even this is not easily solvable as of now in the SCMI stack. So, after all of this babbling of mine, I would say that your patch is fine as it is, also because it is easy to backport; next week when I am back I'll give it a go on a couple of platforms and get back to you with a proper review/test. Thanks again ! Cristian _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel