gpu: nvgpu: Add thermal alert limit IOCTL for UMD

Added the thermal alert lmit IOCTL for UMD

JIRA DNVGPU-130
Bug 200231080

Change-Id: I4a84157d90b12b576fa144567a3bdd5d39f5278e
Signed-off-by: Lakshmanan M <lm@nvidia.com>
Reviewed-on: http://git-master/r/1249483
(cherry picked from commit d3458008cc3dd98d3a51841b6ed8cea1aed9eb89)
Reviewed-on: http://git-master/r/1253457
GVS: Gerrit_Virtual_Submit
Reviewed-by: Vijayakumar Subbu <vsubbu@nvidia.com>
This commit is contained in:
Lakshmanan M
2016-11-08 11:15:56 +05:30
committed by mobile promotions
parent eaeb5ff20f
commit 8a63a431c4
2 changed files with 41 additions and 1 deletions

View File

@@ -777,6 +777,14 @@ struct nvgpu_gpu_get_temperature_args {
__s32 temp_f24_8;
};
struct nvgpu_gpu_set_therm_alert_limit_args {
__u32 reserved[3];
/* Temperature in signed fixed point format SFXP24.8
* Celsius = temp_f24_8 / 256.
*/
__s32 temp_f24_8;
};
#define NVGPU_GPU_IOCTL_ZCULL_GET_CTX_SIZE \
_IOR(NVGPU_GPU_IOCTL_MAGIC, 1, struct nvgpu_gpu_zcull_get_ctx_size_args)
#define NVGPU_GPU_IOCTL_ZCULL_GET_INFO \
@@ -858,8 +866,11 @@ struct nvgpu_gpu_get_temperature_args {
_IOWR(NVGPU_GPU_IOCTL_MAGIC, 37, struct nvgpu_gpu_get_temperature_args)
#define NVGPU_GPU_IOCTL_GET_FBP_L2_MASKS \
_IOWR(NVGPU_GPU_IOCTL_MAGIC, 38, struct nvgpu_gpu_get_fbp_l2_masks_args)
#define NVGPU_GPU_IOCTL_SET_THERM_ALERT_LIMIT \
_IOWR(NVGPU_GPU_IOCTL_MAGIC, 39, \
struct nvgpu_gpu_set_therm_alert_limit_args)
#define NVGPU_GPU_IOCTL_LAST \
_IOC_NR(NVGPU_GPU_IOCTL_GET_FBP_L2_MASKS)
_IOC_NR(NVGPU_GPU_IOCTL_SET_THERM_ALERT_LIMIT)
#define NVGPU_GPU_IOCTL_MAX_ARG_SIZE \
sizeof(struct nvgpu_gpu_get_cpu_time_correlation_info_args)