Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp75104imm; Wed, 5 Sep 2018 15:15:13 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZDjnQV7jOyIuKj4VuX6dMepjNxa1uy7N5xtRpq/ZNIREBmz+w96XvaomvkvrNrT9itXUoo X-Received: by 2002:a63:380d:: with SMTP id f13-v6mr38660052pga.124.1536185713760; Wed, 05 Sep 2018 15:15:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536185713; cv=none; d=google.com; s=arc-20160816; b=NIJ8e/YXVaQ6ZMAZyk4xJuqDLlIamQe4HRQiLDMEVo47qXDybHo9dpjKbPuHYCEX2N xjYfvkbCCSLccjZyoIK0bHRiZ9mkSlTsbgmlOF9rQRrOguI+NF4eT+ZZYyC7QNw7Rhmw 3aDQZ+zw3MZ9qYPNwMiXb0IM6OLGXHPxAMgY/J6JwRBueCllnS6bqZmVRYtgtePsjasP 54F1aEAs0EKkf2JzqTOmemG93oTjW5YaolcpYseq5ws3/Qwqb+AV1C1Kywd32SfI50jj INWRh1iN8tuaOrRx0QygYnLrZjElKr6bPejnUFrrw3F4t1MZqMMPNC+7jcdt+dK7SeZK JtKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=e63Mqye0Tjh6xNIRob+/NNz+JLC855rN+Bq/JLdzN1c=; b=HaZdumWvAdT9jtYcEqWGGoGKPxlC02WGftIqZeJFzM7+LcjH+Lz6OL5LKKQHE1Bhw+ ynUkS9kqMEZn9iAQkaenXTPqHN49J9Fk7h7QNkRjPpb3QDZIT6BGn/ydRyYY5uA16CYU qaEq/nDmmW4Ub1GmXFoi7/FBGH+vFJgdi2XvtaOCxt7Zmb9sBVejvUYCkNB7yDJzKVw0 7fxkClzUuXrTLsvfO+robU52BF6n9qbukvU4mzfiQ/fh4aFFIGyqexFnLbRPtyJnJMcQ FARHprMP8o2hx1RMFNOnMnqWW7liXtNdbesGO89xQCtkODo/TjVgza88pi/j+F9C0Dzd hhVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Mdkrv2KM; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e8-v6si3199829plb.83.2018.09.05.15.14.57; Wed, 05 Sep 2018 15:15:13 -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; dkim=pass header.i=@kernel.org header.s=default header.b=Mdkrv2KM; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728403AbeIFCiG (ORCPT + 99 others); Wed, 5 Sep 2018 22:38:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:52484 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728389AbeIFCiG (ORCPT ); Wed, 5 Sep 2018 22:38:06 -0400 Received: from jouet.infradead.org (unknown [179.97.41.186]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E5F2C20652; Wed, 5 Sep 2018 22:05:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1536185154; bh=yjdjdpNxb89Nyrv0jmX4CWa9+202tJP1jdNRZ8WTDD8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Mdkrv2KMCsMyqiBvxysCvZAX+US41XM97rJVgiOn2usP3zqqhHmg8aN0obUJeUyNN k9APMAkQlh/mUWzlGsaVIFg+keXHu7Qbw/VDkNzBsEDOMWQL5AQyHOYRLP+cG2tkTN W5hemQTdREZbrleJsEzAuRDRDunZ++n/xFQw5hxM= From: Arnaldo Carvalho de Melo To: Ingo Molnar Cc: Clark Williams , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, Arnaldo Carvalho de Melo , Adrian Hunter , David Ahern , Jiri Olsa , Namhyung Kim , Wang Nan Subject: [PATCH 23/77] perf trace augmented_syscalls: Rename augmented_*_syscall__enter to just *_syscall Date: Wed, 5 Sep 2018 19:03:46 -0300 Message-Id: <20180905220440.20256-24-acme@kernel.org> X-Mailer: git-send-email 2.14.4 In-Reply-To: <20180905220440.20256-1-acme@kernel.org> References: <20180905220440.20256-1-acme@kernel.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnaldo Carvalho de Melo As we'll also hook into the syscalls:sys_exit_SYSCALL for which there are enter hooks. This way we'll be able to iterate the ELF file for the eBPF program, find the syscalls that have hooks and filter them out from the general raw_syscalls:sys_{enter,exit} tracepoint for not-yet-augmented (the ones with pointer arguments not yet being attached to the usual syscalls tracepoint payload) and non augmentable syscalls (syscalls without pointer arguments). Cc: Adrian Hunter Cc: David Ahern Cc: Jiri Olsa Cc: Namhyung Kim Cc: Wang Nan Link: https://lkml.kernel.org/n/tip-cl1xyghwb1usp500354mv37h@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/examples/bpf/augmented_syscalls.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/tools/perf/examples/bpf/augmented_syscalls.c b/tools/perf/examples/bpf/augmented_syscalls.c index bfa28eaf27b3..253b3ccbd17d 100644 --- a/tools/perf/examples/bpf/augmented_syscalls.c +++ b/tools/perf/examples/bpf/augmented_syscalls.c @@ -32,7 +32,7 @@ struct augmented_filename { char value[256]; }; -#define augmented_filename_syscall_enter(syscall) \ +#define augmented_filename_syscall(syscall) \ struct augmented_enter_##syscall##_args { \ struct syscall_enter_##syscall##_args args; \ struct augmented_filename filename; \ @@ -60,7 +60,7 @@ struct syscall_enter_openat_args { long mode; }; -augmented_filename_syscall_enter(openat); +augmented_filename_syscall(openat); struct syscall_enter_open_args { unsigned long long common_tp_fields; @@ -70,7 +70,7 @@ struct syscall_enter_open_args { long mode; }; -augmented_filename_syscall_enter(open); +augmented_filename_syscall(open); struct syscall_enter_inotify_add_watch_args { unsigned long long common_tp_fields; @@ -80,7 +80,7 @@ struct syscall_enter_inotify_add_watch_args { long mask; }; -augmented_filename_syscall_enter(inotify_add_watch); +augmented_filename_syscall(inotify_add_watch); struct statbuf; @@ -91,13 +91,13 @@ struct syscall_enter_newstat_args { struct stat *statbuf; }; -augmented_filename_syscall_enter(newstat); +augmented_filename_syscall(newstat); #ifndef _K_SS_MAXSIZE #define _K_SS_MAXSIZE 128 #endif -#define augmented_sockaddr_syscall_enter(syscall) \ +#define augmented_sockaddr_syscall(syscall) \ struct augmented_enter_##syscall##_args { \ struct syscall_enter_##syscall##_args args; \ struct sockaddr_storage addr; \ @@ -128,7 +128,7 @@ struct syscall_enter_bind_args { unsigned long addrlen; }; -augmented_sockaddr_syscall_enter(bind); +augmented_sockaddr_syscall(bind); struct syscall_enter_connect_args { unsigned long long common_tp_fields; @@ -138,7 +138,7 @@ struct syscall_enter_connect_args { unsigned long addrlen; }; -augmented_sockaddr_syscall_enter(connect); +augmented_sockaddr_syscall(connect); struct syscall_enter_sendto_args { unsigned long long common_tp_fields; @@ -151,6 +151,6 @@ struct syscall_enter_sendto_args { long addr_len; }; -augmented_sockaddr_syscall_enter(sendto); +augmented_sockaddr_syscall(sendto); license(GPL); -- 2.14.4