diff options
author | Deepak Nibade <dnibade@nvidia.com> | 2017-11-03 08:36:10 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-11-06 14:20:01 -0500 |
commit | 1480afeb013decec1d5451fd0d3eeaffa8e17bb6 (patch) | |
tree | 41325c4bb8b45ae9f98febc85dd6634c5113d5b9 /drivers/gpu/nvgpu/common/linux/ioctl_channel.h | |
parent | 69c301a99201d6945fb3bd4df821aedf6d590d46 (diff) |
gpu: nvgpu: define EVENT_IDs in common code
All the event ids NVGPU_IOCTL_CHANNEL_EVENT_ID_* are defined in linux
specific user header uapi/linux/nvgpu.h and can't be used in common
code
Hence add new definitions of type NVGPU_EVENT_ID_* for all the events
in common code and use them wherever required in common code
For future additions to event ids, we need to update both
NVGPU_IOCTL_CHANNEL_EVENT_ID_* and NVGPU_EVENT_ID_* fields
Also add new API nvgpu_event_id_to_ioctl_channel_event_id() to convert
common event_id of the form NVGPU_EVENT_ID_* to Linux specific event_id
of the form NVGPU_IOCTL_CHANNEL_EVENT_ID_*
Use this API in gk20a_channel/tsg_event_id_post_event() to get correct
event_id
Jira NVGPU-259
Change-Id: I15a7f41181fdbb8f1876f88bbcd044447d88325f
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1591434
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/common/linux/ioctl_channel.h')
-rw-r--r-- | drivers/gpu/nvgpu/common/linux/ioctl_channel.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/ioctl_channel.h b/drivers/gpu/nvgpu/common/linux/ioctl_channel.h index 1aac04aa..8cfce7e1 100644 --- a/drivers/gpu/nvgpu/common/linux/ioctl_channel.h +++ b/drivers/gpu/nvgpu/common/linux/ioctl_channel.h | |||
@@ -23,4 +23,5 @@ int gk20a_channel_open_ioctl(struct gk20a *g, | |||
23 | extern const struct file_operations gk20a_event_id_ops; | 23 | extern const struct file_operations gk20a_event_id_ops; |
24 | extern const struct file_operations gk20a_channel_ops; | 24 | extern const struct file_operations gk20a_channel_ops; |
25 | 25 | ||
26 | u32 nvgpu_event_id_to_ioctl_channel_event_id(u32 event_id); | ||
26 | #endif | 27 | #endif |