Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp3435146pxb; Tue, 20 Apr 2021 08:16:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyRi+417Q5ODBIB9oFqjeyc6eBs2Wv7e9b7SJKpnyE9L7kJ7QZ/hl+H5G1VpvzOfSaIul6f X-Received: by 2002:a17:90a:bf16:: with SMTP id c22mr5659649pjs.177.1618931768823; Tue, 20 Apr 2021 08:16:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618931768; cv=none; d=google.com; s=arc-20160816; b=WkFCOWseLj1zRLMeCB8gOEoDCMnDf6Z2hw7/gI/gB57j30ePap11tepBvrpYuQK+BS q0eCZtsLmZjYiyRw42gQEZx3PwTP6SEVK4aVAhSnER5Bpjx2D7WvzrVGL4/zRz6GREeX 5U4xhhdLR7hZolgzCrJxzshUWZ9lg0pPk2C0fbULcxsUgCkCIGNoZoEbSpJNYuu2l6ah c0ylyMIgn1gtolxKFvO8G7jF51qyqmbMc8lJKuf/j3w6fMl/JU8AVDJQ2BfAeZwt7AUp cZujN6aB+OHMIq7nSaT/HsOtnWSSQXugd6SPUFG2wqOV6sWqy6TmI1C4iyb7W1mqgr8n MJMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:thread-index:thread-topic :content-transfer-encoding:mime-version:subject:references :in-reply-to:message-id:cc:to:from:date:dkim-signature:dkim-filter; bh=9jmTl63ejRoEGDH7Iz+Ejiz0VcBL3V+jrgoAm8jUmpY=; b=J9HdU0dKhV+ff9XEkMc4fWjuH25RFPCYmMVS3ynj6fPAyVeAEldLUP7f7gAzepE605 hBn71xYcWxYgIIBY8rcyzFF7WkOrJRF+CZcoHAC9qoYuVXFdqpFHXtcLgLZwEIzaOmQB I0Y/FFUCcjFg9v7L9ROu3CmflILGcjlJxuSMCK0ao5dLLjSyNR8ydMaUYzIxMfr5mXul nJcALYcZRduktQZ08p67oRPC6O80zH6jYBGXMk/7WgqFTh3W7K6uizc/3/4iZnbauMuL FkrvC9Xa+EZGfoPcUGn4XpIseIqcbTRwFluskTOJeUnkXRDpiKMk01B6w71El9dlsOya /CXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@efficios.com header.s=default header.b=M63n3KlX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=efficios.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d10si22311539plh.41.2021.04.20.08.15.55; Tue, 20 Apr 2021 08:16:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@efficios.com header.s=default header.b=M63n3KlX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=efficios.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232758AbhDTPPs (ORCPT + 99 others); Tue, 20 Apr 2021 11:15:48 -0400 Received: from mail.efficios.com ([167.114.26.124]:35252 "EHLO mail.efficios.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230260AbhDTPPn (ORCPT ); Tue, 20 Apr 2021 11:15:43 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.efficios.com (Postfix) with ESMTP id 032EA2FFB10; Tue, 20 Apr 2021 11:15:12 -0400 (EDT) Received: from mail.efficios.com ([127.0.0.1]) by localhost (mail03.efficios.com [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id YViuQ0V-iCvr; Tue, 20 Apr 2021 11:15:11 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mail.efficios.com (Postfix) with ESMTP id F11EF2FF6E7; Tue, 20 Apr 2021 11:15:10 -0400 (EDT) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.efficios.com F11EF2FF6E7 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=efficios.com; s=default; t=1618931711; bh=9jmTl63ejRoEGDH7Iz+Ejiz0VcBL3V+jrgoAm8jUmpY=; h=Date:From:To:Message-ID:MIME-Version; b=M63n3KlXl3yXGgfWiE6tYiU7C9+neliWTS0XbarLUcH3O3nD6dAMSVuNebxkoNwfI 1xqfRU+hzVCGA9JKUKeG3DEr0I17KPId7k4GxpTTHirjf4l1YNoQWRY4vpE6VAtepN igjzrrrN5gXFVSkp8YJ1+uCsod7RWesdEN6K2KfKHXuipYecU8HeLSUm5QocXLayG5 yuEjNfyz2aco/yk01zBjm/L8ypHseinDYKSM1pnsz78lpfksLLGucnCtjUxd+njoC1 o0141zWmCo8MQDTnskeZHmmiw3XITCtx60RlWuqQCjMBelllSfPNJKj9UP2lAuw75Z 6AG7Z48qbwwDA== X-Virus-Scanned: amavisd-new at efficios.com Received: from mail.efficios.com ([127.0.0.1]) by localhost (mail03.efficios.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id NgK35Tnf0dea; Tue, 20 Apr 2021 11:15:10 -0400 (EDT) Received: from mail03.efficios.com (mail03.efficios.com [167.114.26.124]) by mail.efficios.com (Postfix) with ESMTP id E09AA2FF8AA; Tue, 20 Apr 2021 11:15:10 -0400 (EDT) Date: Tue, 20 Apr 2021 11:15:10 -0400 (EDT) From: Mathieu Desnoyers To: rostedt Cc: Dan Williams , fweisbec , Jessica Yu , linux-kernel , Ingo Molnar , chris , yuanhan liu , Emmanuel Grumbach Message-ID: <1672102317.2266.1618931710794.JavaMail.zimbra@efficios.com> In-Reply-To: <20210420105511.65490e8d@gandalf.local.home> References: <1299622684.20306.77.camel@gandalf.stny.rr.com> <20130814233228.778f25d0@gandalf.local.home> <77a6e40b57df092d1bd8967305906a210f286111.camel@intel.com> <20210419181111.5eb582e8@gandalf.local.home> <20210420085532.4062b15e@gandalf.local.home> <1154727029.2004.1618925367044.JavaMail.zimbra@efficios.com> <20210420105511.65490e8d@gandalf.local.home> Subject: Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [167.114.26.124] X-Mailer: Zimbra 8.8.15_GA_4018 (ZimbraWebClient - FF87 (Linux)/8.8.15_GA_4007) Thread-Topic: tracing: Enable tracepoints via module parameters Thread-Index: r4NP/v2czuZt4JWbk4RSvFnbBsSZqw== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ----- On Apr 20, 2021, at 10:55 AM, rostedt rostedt@goodmis.org wrote: > On Tue, 20 Apr 2021 09:29:27 -0400 (EDT) > Mathieu Desnoyers wrote: > >> ----- On Apr 20, 2021, at 8:55 AM, rostedt rostedt@goodmis.org wrote: >> [...] >> > >> > Would adding automatic module parameters be an issue? That is, you can add >> > in the insmod command line a parameter that will enable tracepoints. We >> > could have a way to even see them from the modinfo. I think I had that >> > working once, and it wasn't really that hard to do. >> >> There is one thing we should consider here in terms of namespacing: those module >> command line parameters should be specific to each tracer (e.g. ftrace, perf, >> ebpf). >> >> LTTng for instance already tackles early module load tracing in a different >> way: users can enable instrumentation of yet-to-be loaded kernel modules. So >> it would not make sense in that scheme to have module load parameters. >> >> It's a different trade-off in terms of error reporting though: for instance, >> LTTng won't report an error if a user does a typo when entering an event name. >> >> So I think those command line parameters should be tracer-specific, do you agree >> ? > > > No, I do not agree. I would like to make it consistent with the kernel > command line. As you can put in: "trace_event=sched_switch" and the > sched_switch trace point will be enable (for the tracefs directory) on boot > up. The same should be for modules as well. > > It shouldn't affect LTTng, as you already have a way to enable them as they > get loaded. That sounds fine. So that would be within the "trace_event" (and not tracepoint) namespace for module load parameters as well ? Thanks, Mathieu -- Mathieu Desnoyers EfficiOS Inc. http://www.efficios.com