Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp899869ybl; Wed, 28 Aug 2019 06:59:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqyxiGK7e5kt0cbOQJ/0bAPNxDxy5owrpMUOoxniwccK0cfJPG+vjWocvfNtY99VRarxg32F X-Received: by 2002:aa7:8a83:: with SMTP id a3mr4773736pfc.115.1567000761614; Wed, 28 Aug 2019 06:59:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567000761; cv=none; d=google.com; s=arc-20160816; b=Ex9Zj3PXcSxHDK1UhOXML+Lo4paFINrKXb4cnIO5pGQsaES17f5W+y3rywIvz38SHp 19S4VE98pNJxQpvoS8bPfiuzxGpkOgdKi3BCRYt7eFwrL3UbLuVHYPVtLoCacwmrcDSJ 4422gPpzQoRuPXAwT8VuBQZSr+drRBGnexnfKrrmKAteURv06/jY0xaA5pqkLVn1L7z1 uq4aRt7k31B5gCxMH6lrIt+bNHdJ7Mr4C64wFeXNaoWdM4M4aDsiZB56ZlXRISVqUsap Io/YaJ9/qrhVrj5vOgkMwsXOsrbRI3jhN7UnzURCGXdaFmGekQRnriX8+QVOwQLW8OS0 7bLQ== 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:message-id:date:subject:cc:to:from; bh=ogoqhJTnXXtLojZ67KEJIGiaPCYV5igC/0/s+Jv5K5c=; b=rvOctQmaos8rbJEhgG8ErhjWj6PMYb6477Qd7pQlxRTHwdnIacHyPlu3N73zQ0j2sH TJG1NQbNKOLTI7aHewh6PTCm94kX2P6t4haSi2i+NmlGv8ozcVmMp8VzdHxT9GpVdsXp BDcJ1IWRb1+fodUK65FR42VGxO/cwjo5uOrgcb8r/putwFCIfdoSEm25lwn7+/DWzJEg mRFTTjFxLZnrqPu6UrMS2v6O6YnspmltsIHU2zhxjiCpCT+Tux33uO+380wr255qXSQo hDnhDmclpKr8sgI8I3JyV7PjfAjcwYTa96YkJH8jt0MaxNxgF2DJYE4vv/R5jdgzX6/J mKgQ== 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h13si2003430plr.12.2019.08.28.06.59.05; Wed, 28 Aug 2019 06:59:21 -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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727009AbfH1N5y (ORCPT + 99 others); Wed, 28 Aug 2019 09:57:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51250 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726961AbfH1N5s (ORCPT ); Wed, 28 Aug 2019 09:57:48 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B5F4D8980E7; Wed, 28 Aug 2019 13:57:48 +0000 (UTC) Received: from krava.brq.redhat.com (unknown [10.43.17.33]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1D0B61001B00; Wed, 28 Aug 2019 13:57:46 +0000 (UTC) From: Jiri Olsa To: Arnaldo Carvalho de Melo Cc: lkml , Ingo Molnar , Namhyung Kim , Alexander Shishkin , Peter Zijlstra , Michael Petlan Subject: [PATCH 13/23] libperf: Add PERF_RECORD_SWITCH 'struct context_switch_event' to perf/event.h Date: Wed, 28 Aug 2019 15:57:07 +0200 Message-Id: <20190828135717.7245-14-jolsa@kernel.org> In-Reply-To: <20190828135717.7245-1-jolsa@kernel.org> References: <20190828135717.7245-1-jolsa@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.67]); Wed, 28 Aug 2019 13:57:48 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Move the PERF_RECORD_SWITCH event definition to libperf's event.h. In order to keep libperf simple, we switch 'u64/u32/u16/u8' types used events to their generic '__u*' versions. Link: http://lkml.kernel.org/n/tip-hduuqm2bnzbxhhoynf2x3d3q@git.kernel.org Signed-off-by: Jiri Olsa --- tools/perf/lib/include/perf/event.h | 6 ++++++ tools/perf/util/event.h | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/perf/lib/include/perf/event.h b/tools/perf/lib/include/perf/event.h index 3bcbc1eaeb35..a7b0344bb8b4 100644 --- a/tools/perf/lib/include/perf/event.h +++ b/tools/perf/lib/include/perf/event.h @@ -110,6 +110,12 @@ struct perf_record_sample { __u64 array[]; }; +struct context_switch_event { + struct perf_event_header header; + __u32 next_prev_pid; + __u32 next_prev_tid; +}; + struct attr_event { struct perf_event_header header; struct perf_event_attr attr; diff --git a/tools/perf/util/event.h b/tools/perf/util/event.h index f89e8ddadd46..012b2ba9a9a8 100644 --- a/tools/perf/util/event.h +++ b/tools/perf/util/event.h @@ -332,12 +332,6 @@ struct events_stats { u32 nr_proc_map_timeout; }; -struct context_switch_event { - struct perf_event_header header; - u32 next_prev_pid; - u32 next_prev_tid; -}; - struct thread_map_event_entry { u64 pid; char comm[16]; -- 2.21.0