From patchwork Mon Aug 5 13:10:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sudeep Holla X-Patchwork-Id: 13753612 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 7F02DC3DA4A for ; Mon, 5 Aug 2024 13:11:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=smrYejN+Q/xmoqsry2VHOXSyxAhsuJaqcXRM2sO3oOw=; b=ffLnjP8qVuRXKNjWKaTdYBzv3u kcJH6EuX6AEBCOg+lBVosw4Diw/CqVSHWa1gq9QmBnSJMTTwc6oDeuVgj5OHCXkzp074+EBDH7NBf /mSUCZMlcMs9tSjYz3XW6r5e8aZeh9CQwUOZe0S29t9DVecILFCab384/jJSMyv2CTRMqLQQ0Fss1 soXST5HY91LBnXYvzaUNLKZOEft8MS/CepopwWSjsRVAZQkcfRqKZb2DxNoCNZGfbojuwMngzKk2Z 2PVjBw5ndv1hqsuNUutrM853yxu1a9NMRQQOpJKQVdMPEyGlgKJk7ber10DnSh7ryKVL/WMxBFy4T 2T0Oaqqw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1saxUD-0000000FtsA-1bFz; Mon, 05 Aug 2024 13:10:53 +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 1saxTg-0000000FtfI-2M2Q for linux-arm-kernel@lists.infradead.org; Mon, 05 Aug 2024 13:10:22 +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 2567E143D; Mon, 5 Aug 2024 06:10:43 -0700 (PDT) Received: from usa.arm.com (e103737-lin.cambridge.arm.com [10.1.197.49]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id A6D643F5A1; Mon, 5 Aug 2024 06:10:16 -0700 (PDT) From: Sudeep Holla To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, arm-scmi@vger.kernel.org Cc: Sudeep Holla , Cristian Marussi Subject: [PATCH v5 0/5] Add per-transport SCMI communication debug statistics Date: Mon, 5 Aug 2024 14:10:07 +0100 Message-ID: <20240805131013.587016-1-sudeep.holla@arm.com> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240805_061020_663725_560F8DFC X-CRM114-Status: GOOD ( 11.29 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This series adds support for SCMI communication debug metrict tracking. I am just sending on behalf of Luke with minor reworks in his absense. Cristian, I have retained your review tags, please shout if you disagree. Regards, Sudeep V4->V5 - Updated/improved some patch titles and commit messages - Moved all debugs strings to an array and changed the creations of the same into a for loop - Minor changes to the debugfs file names itself to improve readability V3->V4 - Rename to counters rather than statistics to reflect the scmi protocol better - Use basic writing rather than custom function on debugfs in patch 5 V2->V3 - Switch statistic counters to an array to store statistics. - Add more statistics - Add the ability to reset statistics, both individually and all V1->V2 - Add a minor fix removing an unneeded call to handle_to_scmi_info - Use new scmi_log_stats op/no-op rather than if(IS_ENABLED) - Drop unneeded atomic_set's - Use a helper function for stats debugfs creation Luke Parkin (5): firmware: arm_scmi: Remove superfluous handle_to_scmi_info firmware: arm_scmi: Add support for debug metrics at the interface firmware: arm_scmi: Track basic SCMI communication debug metrics firmware: arm_scmi: Create debugfs files for SCMI communication debug metrics firmware: arm_scmi: Add support to reset the debug metrics drivers/firmware/arm_scmi/Kconfig | 14 +++++ drivers/firmware/arm_scmi/common.h | 24 +++++++++ drivers/firmware/arm_scmi/driver.c | 83 +++++++++++++++++++++++++++--- 3 files changed, 113 insertions(+), 8 deletions(-) Tested-by: Cristian Marussi