Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp4682488rdh; Wed, 29 Nov 2023 07:57:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IEvqqRtgXkUAfMv/8CsL/nvrpR4uE58vg7Msp1iwM4Xk8KqRDEk6b8A8AQz+znEzRW1VH6F X-Received: by 2002:a17:90b:1b44:b0:285:b0fa:f7c6 with SMTP id nv4-20020a17090b1b4400b00285b0faf7c6mr15394523pjb.10.1701273430928; Wed, 29 Nov 2023 07:57:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701273430; cv=none; d=google.com; s=arc-20160816; b=A+xIO1ijmLhIBVWAhMVhPH8s/7m0QlIIYH4DUd7f186pQPeKiYJPDMr1JVNtc9iDMe F1T5g7evOrUUaFiuWLU1RG2Fp/AfI/ME0jl+QG4ejAY0o6OowVUC+NS0w2knEVhgfQQ0 jiPSvOYEkBJPet56o7W9/wW7dUUJAocDJ4YbXsu3k7k4aH6xRPKvHcqw60wXTjxhAY2s sGuD1TXb8g0/zGB+ts9cJbgAgaabOU5zFhxKqyzIMT8hVle3I49d1Cgt+dqAlc+tQA6Z KPnJw7Z/OtYxP8VSiDwqLOdvWLWw1fPRGnvbvQEZz9/LBOH6mnWeUu0NoWi/HpsaYhaF w26w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=kTV/H4uBsFBsxR4a7VdzlLEZwfAKrhMJOMx/ruCkXh4=; fh=s/qgI0ixBNrKgtggrKcDZsbKAL3r7pkxf9cLWUFtGJI=; b=jbOKBedeWEfO3hSCChVqtshw2eVYNcB0tSfGIvcTBPM8RdmT0GI9fM3yE8Nb/W7m2u f63h91tGmyNg6l7VCtFaUc/BenwujS44zIUwV2Dq5s6tsyba+Lj1R6qGWzD8FLppScTM 01QvsDjoy/47gg3ZHF0JI2fw6xkPo1idpuMbFhy+MZH8O+CRZYXqiP6og2vjoJadPAfA Y5uX1r/hKA+MzkxNb9BimBYzH4C589C0N9FXxnGs0kWhHhW1BI0W7loXWsAJrMcSbjh8 lI5h4lWntgkLcRqBd/WzsrhnlYOSWNcMAKuHiuWLuwKMEzmkUaUW30P2U0hw4Fd3Nstf sgPg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id h5-20020a170902b94500b001c5de4a5b4esi13999759pls.597.2023.11.29.07.57.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Nov 2023 07:57:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id EEBF88033891; Wed, 29 Nov 2023 07:57:01 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343964AbjK2P0J (ORCPT + 99 others); Wed, 29 Nov 2023 10:26:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235067AbjK2PZl (ORCPT ); Wed, 29 Nov 2023 10:25:41 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 22B321BD1 for ; Wed, 29 Nov 2023 07:25:25 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8283AC43391; Wed, 29 Nov 2023 15:25:23 +0000 (UTC) Date: Wed, 29 Nov 2023 10:25:45 -0500 From: Steven Rostedt To: "Masami Hiramatsu (Google)" Cc: LKML , Linux Trace Kernel , Mark Rutland , Mathieu Desnoyers , dmaluka@google.com, Sean Paul , Arun Easi , Daniel Wagner Subject: Re: [PATCH] tracing: Allow creating instances with specified system events Message-ID: <20231129102545.56901df5@gandalf.local.home> In-Reply-To: <20231129235821.d99da161644525a2fa988938@kernel.org> References: <20231128122117.2276f4a7@gandalf.local.home> <20231129235821.d99da161644525a2fa988938@kernel.org> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.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 (pete.vger.email [0.0.0.0]); Wed, 29 Nov 2023 07:57:02 -0800 (PST) On Wed, 29 Nov 2023 23:58:21 +0900 Masami Hiramatsu (Google) wrote: > > - Dynamic events had to be specified directly to still allow them to be > > created. > > I have a question about this point. Does this mean the dynamic event files > will be created in the instance which limits the "system"? > For this point, I would like to allow limiting dynamic events on instance too. > If user needs to use specific one, e.g. synthetic, then it is possible to > add it to the filter. I'm going back and forth on this. Here's my thoughts about it. Arguments for allowing all dynamic events: 1. There's not many. This code is basically a way to keep the overhead of an instance down. By removing all static events, it can substantially lower the memory footprint. As synthetic events are user created, there shouldn't be too many that would cause a memory foot print issue, and the user also has a bit of control of what events are created. 2. We have no idea what a user may want to do with those events. What if the user wants to see an event in that buffer and creates a synthetic event for it? Should the kernel create a policy for that? Arguments against defaulting dynamic events in: 1. The list is created in the kernel. The instance is not created by the user and thus the kernel could have more control over it. 2. If the user really wants to have dynamic events, they can create another instance with the needed events or use the top level. Hmm, writing this out, I am now leaning more toward not defaulting dynamic events in. And if we can create a way to dynamically add and remove events systems from an instance (via mkdir and rmdir), this should not be an issue. Anyone else have any thoughts about this? -- Steve