summaryrefslogtreecommitdiffstats
path: root/include/linux/coresight.h
diff options
context:
space:
mode:
authorMathieu Poirier <mathieu.poirier@linaro.org>2019-04-25 13:53:01 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-04-25 22:00:17 +0200
commita0f08a6a9fee0ce3f2d36e3e30799e4c1ec171f4 (patch)
tree2857a8f2ca1f542ec1cc4b3453f9fb0a39025557 /include/linux/coresight.h
parentf5200aa9831f38271c8104565fdcae4401658475 (diff)
downloadlinux-a0f08a6a9fee0ce3f2d36e3e30799e4c1ec171f4.tar.gz
linux-a0f08a6a9fee0ce3f2d36e3e30799e4c1ec171f4.tar.bz2
linux-a0f08a6a9fee0ce3f2d36e3e30799e4c1ec171f4.zip
coresight: Communicate perf event to sink buffer allocation functions
Make struct perf_event available to sink buffer allocation functions in order to use the pid they carry to allocate and free buffer memory along with regimenting access to what source a sink can collect data for. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Tested-by: Leo Yan <leo.yan@linaro.org> Tested-by: Robert Walker <robert.walker@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/coresight.h')
-rw-r--r--include/linux/coresight.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/linux/coresight.h b/include/linux/coresight.h
index 189cc6ddc92b..62a520df8add 100644
--- a/include/linux/coresight.h
+++ b/include/linux/coresight.h
@@ -193,8 +193,9 @@ struct coresight_device {
struct coresight_ops_sink {
int (*enable)(struct coresight_device *csdev, u32 mode, void *data);
int (*disable)(struct coresight_device *csdev);
- void *(*alloc_buffer)(struct coresight_device *csdev, int cpu,
- void **pages, int nr_pages, bool overwrite);
+ void *(*alloc_buffer)(struct coresight_device *csdev,
+ struct perf_event *event, void **pages,
+ int nr_pages, bool overwrite);
void (*free_buffer)(void *config);
unsigned long (*update_buffer)(struct coresight_device *csdev,
struct perf_output_handle *handle,