Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755277AbdLUSLV (ORCPT ); Thu, 21 Dec 2017 13:11:21 -0500 Received: from mga04.intel.com ([192.55.52.120]:49740 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753944AbdLUSJy (ORCPT ); Thu, 21 Dec 2017 13:09:54 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,437,1508828400"; d="scan'208";a="186146365" From: kan.liang@intel.com To: acme@kernel.org, peterz@infradead.org, mingo@redhat.com, linux-kernel@vger.kernel.org Cc: wangnan0@huawei.com, jolsa@kernel.org, namhyung@kernel.org, ak@linux.intel.com, yao.jin@linux.intel.com, Kan Liang Subject: [PATCH V3 09/12] perf evsel: expose perf_missing_features.write_backward Date: Thu, 21 Dec 2017 10:08:51 -0800 Message-Id: <1513879734-237492-10-git-send-email-kan.liang@intel.com> X-Mailer: git-send-email 2.5.5 In-Reply-To: <1513879734-237492-1-git-send-email-kan.liang@intel.com> References: <1513879734-237492-1-git-send-email-kan.liang@intel.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1085 Lines: 39 From: Kan Liang perf top need it to handle overwrite fallback later. Signed-off-by: Kan Liang --- tools/perf/util/evsel.c | 5 +++++ tools/perf/util/evsel.h | 2 ++ 2 files changed, 7 insertions(+) diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index a4d256e..be67149 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c @@ -1669,6 +1669,11 @@ static bool ignore_missing_thread(struct perf_evsel *evsel, return true; } +bool is_write_backward_fail(void) +{ + return perf_missing_features.write_backward; +} + int perf_evsel__open(struct perf_evsel *evsel, struct cpu_map *cpus, struct thread_map *threads) { diff --git a/tools/perf/util/evsel.h b/tools/perf/util/evsel.h index 846e416..1f46728 100644 --- a/tools/perf/util/evsel.h +++ b/tools/perf/util/evsel.h @@ -448,4 +448,6 @@ int perf_event_attr__fprintf(FILE *fp, struct perf_event_attr *attr, struct perf_env *perf_evsel__env(struct perf_evsel *evsel); +bool is_write_backward_fail(void); + #endif /* __PERF_EVSEL_H */ -- 2.5.5