linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] perf/core: Don't pass PERF_EF_START to the PMU ->start callback
@ 2016-08-15 10:42 Will Deacon
  2016-09-05 11:53 ` [tip:perf/core] " tip-bot for Will Deacon
  0 siblings, 1 reply; 2+ messages in thread
From: Will Deacon @ 2016-08-15 10:42 UTC (permalink / raw)
  To: linux-kernel; +Cc: mark.rutland, Will Deacon, Peter Zijlstra

PERF_EF_START is a flag to indicate to the PMU ->add callback that, as
well as claiming the PMU resources required by the event being added,
it should also start the PMU.

Passing this flag to the ->start callback doesn't make sense, because
->start always tries to start the PMU. Remove it.

Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 kernel/events/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/events/core.c b/kernel/events/core.c
index 1903b8f3a705..b11504376af7 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -2455,7 +2455,7 @@ static int __perf_event_stop(void *info)
 	 * while restarting.
 	 */
 	if (sd->restart)
-		event->pmu->start(event, PERF_EF_START);
+		event->pmu->start(event, 0);
 
 	return 0;
 }
-- 
2.1.4

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

* [tip:perf/core] perf/core: Don't pass PERF_EF_START to the PMU ->start callback
  2016-08-15 10:42 [PATCH] perf/core: Don't pass PERF_EF_START to the PMU ->start callback Will Deacon
@ 2016-09-05 11:53 ` tip-bot for Will Deacon
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot for Will Deacon @ 2016-09-05 11:53 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: acme, will.deacon, eranian, hpa, tglx, peterz, torvalds, jolsa,
	mingo, vincent.weaver, alexander.shishkin, linux-kernel

Commit-ID:  c9bbdd4830ab06288bb1d8c00ed8c8c6e80e377a
Gitweb:     http://git.kernel.org/tip/c9bbdd4830ab06288bb1d8c00ed8c8c6e80e377a
Author:     Will Deacon <will.deacon@arm.com>
AuthorDate: Mon, 15 Aug 2016 11:42:45 +0100
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Mon, 5 Sep 2016 13:19:18 +0200

perf/core: Don't pass PERF_EF_START to the PMU ->start callback

PERF_EF_START is a flag to indicate to the PMU ->add() callback that, as
well as claiming the PMU resources required by the event being added,
it should also start the PMU.

Passing this flag to the ->start() callback doesn't make sense, because
->start() always tries to start the PMU. Remove it.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vince Weaver <vincent.weaver@maine.edu>
Cc: mark.rutland@arm.com
Link: http://lkml.kernel.org/r/1471257765-29662-1-git-send-email-will.deacon@arm.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 kernel/events/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/events/core.c b/kernel/events/core.c
index dff00c7..74f22a9 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -2492,7 +2492,7 @@ static int __perf_event_stop(void *info)
 	 * while restarting.
 	 */
 	if (sd->restart)
-		event->pmu->start(event, PERF_EF_START);
+		event->pmu->start(event, 0);
 
 	return 0;
 }

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

end of thread, other threads:[~2016-09-05 11:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-15 10:42 [PATCH] perf/core: Don't pass PERF_EF_START to the PMU ->start callback Will Deacon
2016-09-05 11:53 ` [tip:perf/core] " tip-bot for Will Deacon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).