summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/os/linux/ioctl_channel.h
diff options
context:
space:
mode:
authorThomas Fleury <tfleury@nvidia.com>2018-12-20 23:34:27 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2020-07-27 17:55:01 -0400
commit5ecc45b5e7f16e00b2407d4259759228ccbdcf4b (patch)
tree57335f1b1a7c11836eeecd41a4dea8220fb90d59 /drivers/gpu/nvgpu/os/linux/ioctl_channel.h
parente878686302f126fc09d336310651ebe0f857576c (diff)
gpu: nvgpu: add cycle stats to debugger node
Add NVGPU_DBG_GPU_IOCTL_CYCLE_STATS to debugger node, to install/uninstall a buffer for cycle stats. Add NVGPU_DBG_GPU_IOCTL_CYCLE_STATS_SNAPSHOT to debugger node, to attach/flush/detach a buffer for Mode-E streamout. Those ioctls will apply to the first channel in the debug session. Bug 2660206 Bug 200464613 Change-Id: I0b96d9a07c016690140292fa5886fda545697ee6 Signed-off-by: Thomas Fleury <tfleury@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2002060 (cherry picked from commit 90b0bf98ac01d7fa24c40f6a1f20bfe5fa481d36) Signed-off-by: Gagan Grover <ggrover@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2092008 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: Peter Daifuku <pdaifuku@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/os/linux/ioctl_channel.h')
-rw-r--r--drivers/gpu/nvgpu/os/linux/ioctl_channel.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/os/linux/ioctl_channel.h b/drivers/gpu/nvgpu/os/linux/ioctl_channel.h
index 48cff1ea..3e802899 100644
--- a/drivers/gpu/nvgpu/os/linux/ioctl_channel.h
+++ b/drivers/gpu/nvgpu/os/linux/ioctl_channel.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright (c) 2017, NVIDIA CORPORATION. All rights reserved. 2 * Copyright (c) 2017-2020, NVIDIA CORPORATION. All rights reserved.
3 * 3 *
4 * This program is free software; you can redistribute it and/or modify it 4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms and conditions of the GNU General Public License, 5 * under the terms and conditions of the GNU General Public License,
@@ -36,9 +36,16 @@ long gk20a_channel_ioctl(struct file *filp,
36int gk20a_channel_open_ioctl(struct gk20a *g, 36int gk20a_channel_open_ioctl(struct gk20a *g,
37 struct nvgpu_channel_open_args *args); 37 struct nvgpu_channel_open_args *args);
38 38
39int gk20a_channel_free_cycle_stats_snapshot(struct channel_gk20a *ch); 39int gk20a_channel_cycle_stats(struct channel_gk20a *ch, int dmabuf_fd);
40void gk20a_channel_free_cycle_stats_buffer(struct channel_gk20a *ch); 40void gk20a_channel_free_cycle_stats_buffer(struct channel_gk20a *ch);
41 41
42int gk20a_attach_cycle_stats_snapshot(struct channel_gk20a *ch,
43 u32 dmabuf_fd,
44 u32 perfmon_id_count,
45 u32 *perfmon_id_start);
46int gk20a_flush_cycle_stats_snapshot(struct channel_gk20a *ch);
47int gk20a_channel_free_cycle_stats_snapshot(struct channel_gk20a *ch);
48
42extern const struct file_operations gk20a_channel_ops; 49extern const struct file_operations gk20a_channel_ops;
43 50
44u32 nvgpu_get_common_runlist_level(u32 level); 51u32 nvgpu_get_common_runlist_level(u32 level);