Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp69111imm; Mon, 1 Oct 2018 06:50:37 -0700 (PDT) X-Google-Smtp-Source: ACcGV63IA6yF9T5KIBfIBUizQirog9XmJ5b78A/L/nyvRIuOgTPxglJL5KngkCRHWYQ83oB6i8rD X-Received: by 2002:a65:6499:: with SMTP id e25-v6mr10068000pgv.224.1538401837207; Mon, 01 Oct 2018 06:50:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538401837; cv=none; d=google.com; s=arc-20160816; b=saKHc8HADUfNsylLJJeQaLZ5RLbfY+jOvr9c4E87KJUo8Np7et5T7ry4zCB1rtLUxv dmQvzkANu2sCut3Y4HOG9xcbchYzrwP6yCo96rXgBQ+YkwqFeMZ3qdmX51dHMJVlBhnI 8WSsd0GWEDWGDofFZImyBLG7lMfP1n4Ru8v6HxiN9W9eTnkH/2oeMhB6qPnUZnapo2Vz OwDsKlR7gOFgO0sYgu4NnC/praQZUUN86dLOfHBjpCiEitMMVJS6egiItAO1df2X1yTC YqPq/ffeXc9AHfvN4zOPots1X1WxlrL5bhttDaPDBJxhF+quGOhVIH7ovOM68/YWbWri 9rkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id; bh=3L89PcRw4NrFIyeraD48pBYNWKSO8La/rysSf8RBGkk=; b=cOqdQd2cWXDVMos8tmTlBnJyDtu7EwbN0IvRCOEySNHXA7fV5/MomzyXbAwvcTMWhA 0WgpNmP4M8bIf9IcA9NgFGlEstz/whRF1pNQe0a0cWZkx7XBpDLaWZdRnFnaK8ikG0MO rhK8jyUs2O3123fw7H/NxFsqgctSPAZSHJ9LWf8tAag62C+qeLkW0somu6c/3LLwd7kd L7wU+fz1kKevKKo7/cIeowGIyzcT9CdPTXxz08aFlxreUIqORAwzc91W98oNOgu7fCSP EnSlJGYm8u72x0/0zYm4Ji25vLDSqS3yVLkrr9EJwvjfh+k1mCFn1hgiktXvpWjkpPj3 1zUA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ay4-v6si12617184plb.410.2018.10.01.06.50.22; Mon, 01 Oct 2018 06:50:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729443AbeJAU12 (ORCPT + 99 others); Mon, 1 Oct 2018 16:27:28 -0400 Received: from mga02.intel.com ([134.134.136.20]:24322 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729291AbeJAU12 (ORCPT ); Mon, 1 Oct 2018 16:27:28 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 01 Oct 2018 06:49:34 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,327,1534834800"; d="scan'208";a="77544806" Received: from rchan-mobl1.amr.corp.intel.com ([10.252.138.92]) by orsmga007.jf.intel.com with ESMTP; 01 Oct 2018 06:49:24 -0700 Message-ID: Subject: Re: [RFC PATCH 0/5] tracing: Unifying dynamic event interface From: Tom Zanussi To: Masami Hiramatsu , Steven Rostedt Cc: linux-kernel@vger.kernel.org, Ingo Molnar , Ravi Bangoria Date: Mon, 01 Oct 2018 08:49:24 -0500 In-Reply-To: <153806391326.18458.3927382953014694981.stgit@devbox> References: <153806391326.18458.3927382953014694981.stgit@devbox> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5 (3.28.5-1.fc28) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Masami, On Fri, 2018-09-28 at 00:58 +0900, Masami Hiramatsu wrote: > Hi, > > This is an RFC series of unifying dynamic event interface on ftrace. > Currently ftrace has 3 dynamic event interfaces, kprobes, uprobes > and synthetic. This series unifies kprobes and uprobes event > interface on "dynamic_events". This enables us to add new dynamic > events easily on same interface, e.g. function events. This seems like a nice idea to me and I don't see any problems with the patches themselves, so consider it Acked-by: Tom Zanussi > The older interfaces are left on the tracefs for backward > compatibility at this moment. > > dynamic_events syntax has no different from kprobe_events and > uprobe_events. You can use same syntax for dynamic_events interface. > > I think we can integrate synthetic events to this dynamic_events > interface but it will requires new syntax. e.g. > > echo "s: " >> dynamic_events > So that's just the existing syntax, prefaced by s: , right? > If it is OK, I'll add it in next version. > Makes sense to me. > BTW, since this dynamic_events interface derived from *probe_events, > it inherits "all clear when truncate file open" behavior. But if you > think this is too aggressive, I can drop it. (even in that case, > kprobe_events/uprobe_events behavior is not changed) > > I also introduced a widely used way to erase entries in other > interfaces of ftrace, that is '!'. So you can now use '!event-name' > or '!group/event' to erase an entry in dynamic_events. > (Wait... it has to be '!p:event' as others do??) > I'd think the full form should always be accepted, but would only be necessary in cases requiring disambiguation. Thanks, Tom > Any thought? > > Thank you, > > --- > > Masami Hiramatsu (5): > tracing/uprobes: Add busy check when cleanup all uprobes > tracing: Add a unified dynamic event framework > tracing/kprobes: Use dyn_event framework for kprobe events > tracing/uprobes: Use dyn_event framework for uprobe events > tracing: Add generic event-name based remove event method > > > Documentation/trace/kprobetrace.rst | 3 + > Documentation/trace/uprobetracer.rst | 4 + > kernel/trace/Kconfig | 4 + > kernel/trace/Makefile | 1 > kernel/trace/trace.c | 4 + > kernel/trace/trace_dynevent.c | 183 > +++++++++++++++++++++++++++++++++ > kernel/trace/trace_dynevent.h | 89 ++++++++++++++++ > kernel/trace/trace_kprobe.c | 191 +++++++++++++++++++++++- > ---------- > kernel/trace/trace_uprobe.c | 175 +++++++++++++++++++++++- > ------- > 9 files changed, 547 insertions(+), 107 deletions(-) > create mode 100644 kernel/trace/trace_dynevent.c > create mode 100644 kernel/trace/trace_dynevent.h > > -- > Masami Hiramatsu (Linaro)