From 68eeda3ebdd6ca20289fb0af22a0ca593198bc63 Mon Sep 17 00:00:00 2001 From: Thomas Fleury Date: Fri, 18 Nov 2016 09:11:45 -0800 Subject: gpu: nvgpu: alarm/event interface cleanup use CPU timestamp in nanoseconds define last event/alarm number Jira DNVGPU-186 Change-Id: I769c8a7a41ac1fb49234f0d5144a78fa657ec230 Signed-off-by: Thomas Fleury Reviewed-on: http://git-master/r/1260799 (cherry picked from commit 379171b43cb20d7a31b3966cad3696525e8cf7d9) Reviewed-on: http://git-master/r/1267159 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom --- include/uapi/linux/nvgpu.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/uapi/linux/nvgpu.h b/include/uapi/linux/nvgpu.h index 4c4b0f8c..649cdf02 100644 --- a/include/uapi/linux/nvgpu.h +++ b/include/uapi/linux/nvgpu.h @@ -695,7 +695,7 @@ struct nvgpu_gpu_get_event_fd_args { /* in: Flags (not currently used). */ __u32 flags; - /* out: File descriptor for events, i.e. clock update. + /* out: File descriptor for events, e.g. clock update. * On successful polling of this event_fd, application is * expected to read status (nvgpu_gpu_event_info), * which provides detailed event information @@ -873,14 +873,16 @@ struct nvgpu_gpu_get_temperature_args { /* Alarm on power condition */ #define NVGPU_GPU_EVENT_ALARM_POWER_ABOVE_THRESHOLD 6 -/* Non recoverable alarm (POLLUP) */ +/* Non recoverable alarm (POLLHUP) */ /* Alarm on GPU shutdown/fall from bus */ #define NVGPU_GPU_EVENT_ALARM_GPU_LOST 7 +#define NVGPU_GPU_EVENT_LAST NVGPU_GPU_EVENT_ALARM_GPU_LOST + struct nvgpu_gpu_event_info { __u32 event_id; /* NVGPU_GPU_EVENT_* */ __u32 reserved; - __u64 timestamp; /* GPU timestamp */ + __u64 timestamp; /* CPU timestamp (in nanoseconds) */ }; struct nvgpu_gpu_set_event_filter_args { -- cgit v1.2.2