aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/events/ring_buffer.c
diff options
context:
space:
mode:
authorWill Deacon <will.deacon@arm.com>2016-08-16 11:53:15 -0400
committerWill Deacon <will.deacon@arm.com>2017-10-18 07:53:30 -0400
commitbc1d202023eb66f088f736ba423bee1cf135c720 (patch)
tree98664ac30eeca124f3d0ff9d2f3d1ac896574f3f /kernel/events/ring_buffer.c
parent5ffeb0501c6b36d080de78372fdb70b404b91e9d (diff)
perf/core: Export AUX buffer helpers to modules
Perf PMU drivers using AUX buffers cannot be built as modules unless the AUX helpers are exported. This patch exports perf_aux_output_{begin,end,skip} and perf_get_aux to modules. Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'kernel/events/ring_buffer.c')
-rw-r--r--kernel/events/ring_buffer.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/kernel/events/ring_buffer.c b/kernel/events/ring_buffer.c
index f684d8e5fa2b..6d9bffe4d6cc 100644
--- a/kernel/events/ring_buffer.c
+++ b/kernel/events/ring_buffer.c
@@ -411,6 +411,7 @@ err:
411 411
412 return NULL; 412 return NULL;
413} 413}
414EXPORT_SYMBOL_GPL(perf_aux_output_begin);
414 415
415static bool __always_inline rb_need_aux_wakeup(struct ring_buffer *rb) 416static bool __always_inline rb_need_aux_wakeup(struct ring_buffer *rb)
416{ 417{
@@ -480,6 +481,7 @@ void perf_aux_output_end(struct perf_output_handle *handle, unsigned long size)
480 rb_free_aux(rb); 481 rb_free_aux(rb);
481 ring_buffer_put(rb); 482 ring_buffer_put(rb);
482} 483}
484EXPORT_SYMBOL_GPL(perf_aux_output_end);
483 485
484/* 486/*
485 * Skip over a given number of bytes in the AUX buffer, due to, for example, 487 * Skip over a given number of bytes in the AUX buffer, due to, for example,
@@ -505,6 +507,7 @@ int perf_aux_output_skip(struct perf_output_handle *handle, unsigned long size)
505 507
506 return 0; 508 return 0;
507} 509}
510EXPORT_SYMBOL_GPL(perf_aux_output_skip);
508 511
509void *perf_get_aux(struct perf_output_handle *handle) 512void *perf_get_aux(struct perf_output_handle *handle)
510{ 513{
@@ -514,6 +517,7 @@ void *perf_get_aux(struct perf_output_handle *handle)
514 517
515 return handle->rb->aux_priv; 518 return handle->rb->aux_priv;
516} 519}
520EXPORT_SYMBOL_GPL(perf_get_aux);
517 521
518#define PERF_AUX_GFP (GFP_KERNEL | __GFP_ZERO | __GFP_NOWARN | __GFP_NORETRY) 522#define PERF_AUX_GFP (GFP_KERNEL | __GFP_ZERO | __GFP_NOWARN | __GFP_NORETRY)
519 523