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 X-Spam-Level: X-Spam-Status: No, score=-9.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 05175C433ED for ; Thu, 13 May 2021 16:55:56 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 625B76143B for ; Thu, 13 May 2021 16:55:55 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 625B76143B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:Cc:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=z7Jk0iq2rR2UtSzIZ02aUNIoFvq0vooCOY+mVRNw4AE=; b=a1IS/HH4AT81niKFqWEDvCi3L 0ewKVgjBPtJYYkDmoKKRpdapopJ6tjHMCeykecrWEKKyYpITV3eAd0yVe80ewDThwtphNLYutbISq O/zVpKSTdysOvrix3Rc/bhGQsd2XyYxCk6ifxAQt74i48i+kxb6qk32H8bLixwyIuiMCbAU1xIPpI oKYg1PeBGULeha8U9s5heKmz1J0LeGTrqosJ3kPW/xXvnhGV6BgQr2PHF7lPJcSOsnO5vTTwEOltV /t40PnNgoQ47kmvFIIec25sPxViU3fr+UIMKtyBF5RqJJKpGyDC3uQYQGOQqJIpW4ysHNyR36Qf/2 y7jyohwQQ==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lhEb5-0060ZE-Qf; Thu, 13 May 2021 16:54:03 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhEb3-0060Z9-49 for linux-arm-kernel@desiato.infradead.org; Thu, 13 May 2021 16:54:01 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Type:Cc:To:Subject:Message-ID :Date:From:In-Reply-To:References:MIME-Version:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=fXOCIh/8X6FpnfkQeuVTS8n8UQM1AyFURvEhVvo80QE=; b=xE/Z7KviL5PMAT+XURkuCqYZao xtD9SYyAyG0OEZ2XB+Juvn03QomBz5ucNs5CzPE55eerUH6s/iCmAGG6AjNzE3E+F1bZoJbPMmK3x esFrweUs4J2m7/VjcuyqUPEvQlVKd/RhxpnCK/OT1CnGEDu66MAjIvvpwZLcKE5KYMJg4tGRQ+csV zH1rBu7QYdaXR4fzF+UcDjIhg2jbg70dSs87NfGrmgQmT94AEd6I8CMqDLpjyflC3GoCijXMzIkXl s1I5n5xKBl6d8I+6SfQrG91yna4wgTFEWSqHBqHf1bYCUpnu2Z7jrO77GtQt1utAGksRG6q+JPRNP Z1hyrIng==; Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhEb0-00BOhL-0M for linux-arm-kernel@lists.infradead.org; Thu, 13 May 2021 16:53:59 +0000 Received: by mail-wm1-x334.google.com with SMTP id j3-20020a05600c4843b02901484662c4ebso171429wmo.0 for ; Thu, 13 May 2021 09:53:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fXOCIh/8X6FpnfkQeuVTS8n8UQM1AyFURvEhVvo80QE=; b=ZYoMBYkZxruYlia654MdD1Ar2BMxPn5/C9CC4rh3O325+FC1TH//lu2h3Kc9uQEdK4 R7nn70JbEKp7urG97vFzi9ilwpt6v/KAYipVpcuwLYn4CUm038Du/5BiShYg1AyN7zzj 9yEnMslRg3B6OyEnnqHKY7bfa/32fNmDQEDaImyOcrT/OQqSZcF2JCX8ZqpuOBDEt6Gs Uc/esjy+gH6gwrqqc0JhlecdL8K+1NFH8tNSOs/6Bp7dO1bs8shO2akUSZFaLdxBiEz2 /B3C/a5WFEKs0Ce+1r1sb8D6phFFZOTwkJxrW27rRXpUHK67h1lU18nSvmMt6U+AlD2e pS7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=fXOCIh/8X6FpnfkQeuVTS8n8UQM1AyFURvEhVvo80QE=; b=qrB9ueNMN65gu9BJgyjtccPOymHBYNJK6h6+ltlcuriKBV0KDDFrrQVXidvPteF4CF 3aa/Su2xbhTZELG3jLAiSMq/3F88BunILSdX7SxuYXZkJCixA1CtUjh4e/HnUyJW1y43 TJTDQBM0He49aQukGMsm8R1sy4Jxok7yysypTrWnMGiSYkBwV1xiFvosj73jibH4yFzv oy/CsuFuJA5sxOvJVTtak4jfjyZ0YVOtOiXYRLMwDcErnUJbhBXuOfI15+59hMFuOqUq eni8cDt4tboCC5oBr+M8RDF7MWNt+riXF5g18UW0aIDTlxhZUVvNckk8J0WoTEz8+gjP aO3g== X-Gm-Message-State: AOAM531KN/ZECm1wIYRv+o/5uTTuJIwpg7UwBzf73bEYmedHuKQsD0qn M96QAE04ezZYXxSDR1VwCXib/n5AHD0zxaVnzW5IMQ== X-Google-Smtp-Source: ABdhPJwxFKen/M9jQISmgwvfd6CGIu6h33L9f2Zteuz4J/i76S4CCCcG0uot5WOosoJ/7Ge1iQk5m91lH6CbpBj6xeo= X-Received: by 2002:a1c:f219:: with SMTP id s25mr4781680wmc.31.1620924826812; Thu, 13 May 2021 09:53:46 -0700 (PDT) MIME-Version: 1.0 References: <20210512211752.4103-1-mike.leach@linaro.org> <20210513155633.GA225418@xps15> In-Reply-To: <20210513155633.GA225418@xps15> From: Mike Leach Date: Thu, 13 May 2021 17:53:36 +0100 Message-ID: Subject: Re: [RFC PATCH 0/8] coresight: syscfg: dynamic load, resource management To: Mathieu Poirier Cc: Coresight ML , linux-arm-kernel , "Suzuki K. Poulose" , Leo Yan X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210513_095358_105170_18FCB97B X-CRM114-Status: GOOD ( 28.74 ) 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 Hi Mathieu, On Thu, 13 May 2021 at 16:56, Mathieu Poirier wrote: > > Hey Mike, > > On Wed, May 12, 2021 at 10:17:44PM +0100, Mike Leach wrote: > > This patchset represents the second phase of CoreSight configuration > > management. > > > > 1) API updated to allow dynamic load and unload of configurations and > > features. Dependency management between loaded sets is added. > > > > 2) New configuration and feature sets can be added using a loadable module. > > An example in /samples/coresight is provided to demonstrate this. > > > > I tried to compile the sample module and I get: > > samples/coresight/coresight-cfg-sample.c:7:10: fatal error: coresight-config.h: No such file or directory > #include "coresight-config.h" > ^~~~~~~~~~~~~~~~~~~~ > compilation terminated. > > Can you reproduce on your side? > No problem here. I cleaned and rechecked I had the sample selected in my .config (CONFIG_SAMPLE_CORESIGHT_SYSCFG=m) and it built just fine. Regards Mike > Thanks, > Mathieu > > > 3) Resource management API is added. This allows the system to ensure that > > loaded configurations and features are only loaded onto devices that can > > support them. > > > > Further - it ensures that configurations with multiple features cannot over > > allocate resources. > > > > 4) configfs can be used to activate a configuration which will then be used > > when controlling tracing using sysfs. > > > > 5) Resource management is added to ETMv4 configurations. This allows current > > and future features and configurations to be defined in terms of resources > > used as well as registers to be programmed. > > > > Defining features in this way allows the resource management to operate > > correctly. > > > > The perf event parsing is also adjusted to allow the ETM resources requested > > on the command line (e.g. address filters, etc) to be correctly handled > > using resoruce management alongside the complex configurations such as > > autofdo. > > > > Applies to coresight/next - which is 5.13-rc1 + initial Coresight configuration > > patchset. > > > > To follow in future revisions / sets:- > > a) load of additional config and features by configfs > > b) ECT and CTI and other Coresight components support for configuration and > > features. > > > > > > Mike Leach (8): > > coresight: syscfg: Update API to allow dynamic load and unload > > coresight: syscfg: Update load API for config loadable modules > > coresight: syscfg: Example CoreSight configuration loadable module > > coresight: configfs: Allow configfs to activate configuration. > > coresight: syscfg: Add API to check and validate device resources. > > coresight: etm4x: syscfg: Add resource management to etm4x. > > coresight: etm4x: Update perf event resource handling. > > coresight: etm4x: Update configuration example. > > > > MAINTAINERS | 1 + > > .../hwtracing/coresight/coresight-cfg-afdo.c | 38 +- > > .../coresight/coresight-cfg-preload.c | 9 +- > > .../hwtracing/coresight/coresight-config.c | 71 ++- > > .../hwtracing/coresight/coresight-config.h | 45 +- > > .../hwtracing/coresight/coresight-etm4x-cfg.c | 533 ++++++++++++++++++ > > .../hwtracing/coresight/coresight-etm4x-cfg.h | 196 ++++++- > > .../coresight/coresight-etm4x-core.c | 250 +++----- > > .../coresight/coresight-syscfg-configfs.c | 87 +++ > > .../coresight/coresight-syscfg-configfs.h | 4 + > > .../hwtracing/coresight/coresight-syscfg.c | 390 +++++++++++-- > > .../hwtracing/coresight/coresight-syscfg.h | 38 +- > > include/linux/coresight.h | 2 + > > samples/Kconfig | 9 + > > samples/Makefile | 1 + > > samples/coresight/Makefile | 4 + > > samples/coresight/coresight-cfg-sample.c | 73 +++ > > 17 files changed, 1511 insertions(+), 240 deletions(-) > > create mode 100644 samples/coresight/Makefile > > create mode 100644 samples/coresight/coresight-cfg-sample.c > > > > -- > > 2.17.1 > > -- Mike Leach Principal Engineer, ARM Ltd. Manchester Design Centre. UK _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel