All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] perf/x86: Trivial cleanups
@ 2015-06-24 10:05 Alexander Shishkin
  2015-06-24 10:05 ` [PATCH 1/2] perf/x86/intel/bts: Cleanup: drop redundant declarations Alexander Shishkin
  2015-06-24 10:05 ` [PATCH 2/2] perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good Alexander Shishkin
  0 siblings, 2 replies; 5+ messages in thread
From: Alexander Shishkin @ 2015-06-24 10:05 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar
  Cc: linux-kernel, adrian.hunter, x86, hpa, acme, Alexander Shishkin

Hi Peter and Ingo,

Here are two simple cleanups from my initial AUX/PT/BTS patchset.

Alexander Shishkin (2):
  perf/x86/intel/bts: Cleanup: drop redundant declarations
  perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good

 arch/x86/kernel/cpu/perf_event.h           | 14 --------------
 arch/x86/kernel/cpu/perf_event_intel_bts.c |  3 ---
 2 files changed, 17 deletions(-)

-- 
2.1.4


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/2] perf/x86/intel/bts: Cleanup: drop redundant declarations
  2015-06-24 10:05 [PATCH 0/2] perf/x86: Trivial cleanups Alexander Shishkin
@ 2015-06-24 10:05 ` Alexander Shishkin
  2015-08-04  8:53   ` [tip:perf/core] perf/x86/intel/bts: Drop " tip-bot for Alexander Shishkin
  2015-06-24 10:05 ` [PATCH 2/2] perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good Alexander Shishkin
  1 sibling, 1 reply; 5+ messages in thread
From: Alexander Shishkin @ 2015-06-24 10:05 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar
  Cc: linux-kernel, adrian.hunter, x86, hpa, acme, Alexander Shishkin

Both intel_pmu_enable_bts() and intel_pmu_disable_bts() are in perf_event.h
header file, no need to have them declared again in the driver.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
---
 arch/x86/kernel/cpu/perf_event_intel_bts.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/arch/x86/kernel/cpu/perf_event_intel_bts.c b/arch/x86/kernel/cpu/perf_event_intel_bts.c
index 7795f3f8b1..57479ed49e 100644
--- a/arch/x86/kernel/cpu/perf_event_intel_bts.c
+++ b/arch/x86/kernel/cpu/perf_event_intel_bts.c
@@ -62,9 +62,6 @@ struct bts_buffer {
 
 struct pmu bts_pmu;
 
-void intel_pmu_enable_bts(u64 config);
-void intel_pmu_disable_bts(void);
-
 static size_t buf_size(struct page *page)
 {
 	return 1 << (PAGE_SHIFT + page_private(page));
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/2] perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good
  2015-06-24 10:05 [PATCH 0/2] perf/x86: Trivial cleanups Alexander Shishkin
  2015-06-24 10:05 ` [PATCH 1/2] perf/x86/intel/bts: Cleanup: drop redundant declarations Alexander Shishkin
@ 2015-06-24 10:05 ` Alexander Shishkin
  2015-08-04  8:53   ` [tip:perf/core] perf/x86/intel/lbr: " tip-bot for Alexander Shishkin
  1 sibling, 1 reply; 5+ messages in thread
From: Alexander Shishkin @ 2015-06-24 10:05 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar
  Cc: linux-kernel, adrian.hunter, x86, hpa, acme, Alexander Shishkin

The x86_lbr_exclusive commit (4807034248be "perf/x86: Mark Intel PT and
LBR/BTS as mutually exclusive") mistakenly moved intel_pmu_needs_lbr_smpl()
to perf_event.h, while another commit (a46a2300019 "perf: Simplify the
branch stack check") removed it in favor of needs_branch_stack().

This patch gets rid of intel_pmu_needs_lbr_smpl() for good.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
---
 arch/x86/kernel/cpu/perf_event.h | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/arch/x86/kernel/cpu/perf_event.h b/arch/x86/kernel/cpu/perf_event.h
index 06a9ab79d6..0cd854671b 100644
--- a/arch/x86/kernel/cpu/perf_event.h
+++ b/arch/x86/kernel/cpu/perf_event.h
@@ -794,20 +794,6 @@ static inline int amd_pmu_init(void)
 
 #ifdef CONFIG_CPU_SUP_INTEL
 
-static inline bool intel_pmu_needs_lbr_smpl(struct perf_event *event)
-{
-	/* user explicitly requested branch sampling */
-	if (has_branch_stack(event))
-		return true;
-
-	/* implicit branch sampling to correct PEBS skid */
-	if (x86_pmu.intel_cap.pebs_trap && event->attr.precise_ip > 1 &&
-	    x86_pmu.intel_cap.pebs_format < 2)
-		return true;
-
-	return false;
-}
-
 static inline bool intel_pmu_has_bts(struct perf_event *event)
 {
 	if (event->attr.config == PERF_COUNT_HW_BRANCH_INSTRUCTIONS &&
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [tip:perf/core] perf/x86/intel/bts: Drop redundant declarations
  2015-06-24 10:05 ` [PATCH 1/2] perf/x86/intel/bts: Cleanup: drop redundant declarations Alexander Shishkin
@ 2015-08-04  8:53   ` tip-bot for Alexander Shishkin
  0 siblings, 0 replies; 5+ messages in thread
From: tip-bot for Alexander Shishkin @ 2015-08-04  8:53 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: torvalds, hpa, alexander.shishkin, tglx, peterz, linux-kernel, mingo

Commit-ID:  e9b3bd379c283577e102529bfb22484238be7c91
Gitweb:     http://git.kernel.org/tip/e9b3bd379c283577e102529bfb22484238be7c91
Author:     Alexander Shishkin <alexander.shishkin@linux.intel.com>
AuthorDate: Wed, 24 Jun 2015 13:05:48 +0300
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Tue, 4 Aug 2015 10:16:53 +0200

perf/x86/intel/bts: Drop redundant declarations

Both intel_pmu_enable_bts() and intel_pmu_disable_bts() are in perf_event.h
header file, no need to have them declared again in the driver.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: acme@infradead.org
Cc: adrian.hunter@intel.com
Cc: hpa@zytor.com
Link: http://lkml.kernel.org/r/1435140349-32588-2-git-send-email-alexander.shishkin@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 arch/x86/kernel/cpu/perf_event_intel_bts.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/arch/x86/kernel/cpu/perf_event_intel_bts.c b/arch/x86/kernel/cpu/perf_event_intel_bts.c
index 43dd672..54690e8 100644
--- a/arch/x86/kernel/cpu/perf_event_intel_bts.c
+++ b/arch/x86/kernel/cpu/perf_event_intel_bts.c
@@ -62,9 +62,6 @@ struct bts_buffer {
 
 struct pmu bts_pmu;
 
-void intel_pmu_enable_bts(u64 config);
-void intel_pmu_disable_bts(void);
-
 static size_t buf_size(struct page *page)
 {
 	return 1 << (PAGE_SHIFT + page_private(page));

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [tip:perf/core] perf/x86/intel/lbr: Kill off intel_pmu_needs_lbr_smpl for good
  2015-06-24 10:05 ` [PATCH 2/2] perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good Alexander Shishkin
@ 2015-08-04  8:53   ` tip-bot for Alexander Shishkin
  0 siblings, 0 replies; 5+ messages in thread
From: tip-bot for Alexander Shishkin @ 2015-08-04  8:53 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: tglx, mingo, torvalds, linux-kernel, alexander.shishkin, hpa, peterz

Commit-ID:  c749b3e96398fcc39286267b72fb8b85c0f757ea
Gitweb:     http://git.kernel.org/tip/c749b3e96398fcc39286267b72fb8b85c0f757ea
Author:     Alexander Shishkin <alexander.shishkin@linux.intel.com>
AuthorDate: Wed, 24 Jun 2015 13:05:49 +0300
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Tue, 4 Aug 2015 10:16:53 +0200

perf/x86/intel/lbr: Kill off intel_pmu_needs_lbr_smpl for good

The x86_lbr_exclusive commit (4807034248be "perf/x86: Mark Intel PT and
LBR/BTS as mutually exclusive") mistakenly moved intel_pmu_needs_lbr_smpl()
to perf_event.h, while another commit (a46a2300019 "perf: Simplify the
branch stack check") removed it in favor of needs_branch_stack().

This patch gets rid of intel_pmu_needs_lbr_smpl() for good.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: acme@infradead.org
Cc: adrian.hunter@intel.com
Cc: hpa@zytor.com
Link: http://lkml.kernel.org/r/1435140349-32588-3-git-send-email-alexander.shishkin@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 arch/x86/kernel/cpu/perf_event.h | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/arch/x86/kernel/cpu/perf_event.h b/arch/x86/kernel/cpu/perf_event.h
index 3e7fd27..3474cf2 100644
--- a/arch/x86/kernel/cpu/perf_event.h
+++ b/arch/x86/kernel/cpu/perf_event.h
@@ -808,20 +808,6 @@ static inline int amd_pmu_init(void)
 
 #ifdef CONFIG_CPU_SUP_INTEL
 
-static inline bool intel_pmu_needs_lbr_smpl(struct perf_event *event)
-{
-	/* user explicitly requested branch sampling */
-	if (has_branch_stack(event))
-		return true;
-
-	/* implicit branch sampling to correct PEBS skid */
-	if (x86_pmu.intel_cap.pebs_trap && event->attr.precise_ip > 1 &&
-	    x86_pmu.intel_cap.pebs_format < 2)
-		return true;
-
-	return false;
-}
-
 static inline bool intel_pmu_has_bts(struct perf_event *event)
 {
 	if (event->attr.config == PERF_COUNT_HW_BRANCH_INSTRUCTIONS &&

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-08-04  8:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-24 10:05 [PATCH 0/2] perf/x86: Trivial cleanups Alexander Shishkin
2015-06-24 10:05 ` [PATCH 1/2] perf/x86/intel/bts: Cleanup: drop redundant declarations Alexander Shishkin
2015-08-04  8:53   ` [tip:perf/core] perf/x86/intel/bts: Drop " tip-bot for Alexander Shishkin
2015-06-24 10:05 ` [PATCH 2/2] perf/x86/intel: Kill off intel_pmu_needs_lbr_smpl for good Alexander Shishkin
2015-08-04  8:53   ` [tip:perf/core] perf/x86/intel/lbr: " tip-bot for Alexander Shishkin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.