summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/gk20a.h
diff options
context:
space:
mode:
authorKonsta Holtta <kholtta@nvidia.com>2017-07-03 06:49:27 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-07-07 13:35:30 -0400
commitd0a77f558ef8d101059c6238abd46a9a97191564 (patch)
tree76488cf718482c20ff81685f48737eaf63a9b3e7 /drivers/gpu/nvgpu/gk20a/gk20a.h
parent858a204362a385f076b057b6196fd89f7edb839b (diff)
gpu: nvgpu: use u32 for timeout API duration
A negative value in the timeout duration does not have any special uses, so change the duration type to u32 (from just int). Delete some unnecessary typecasts to int. Also change MAX_SCHEDULE_TIMEOUT to ULONG_MAX in default gr idle timeout because the value is in milliseconds instead of scheduling units and to drop unnecessary Linux dependency. Change-Id: I5cf6febd4f1cb00c46fe159603436a9ac3b003ac Signed-off-by: Konsta Holtta <kholtta@nvidia.com> Reviewed-on: https://git-master/r/1512565 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gk20a.h')
-rw-r--r--drivers/gpu/nvgpu/gk20a/gk20a.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h
index f365ac94..dd5f0d17 100644
--- a/drivers/gpu/nvgpu/gk20a/gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/gk20a.h
@@ -1287,7 +1287,7 @@ struct gk20a {
1287static inline unsigned long gk20a_get_gr_idle_timeout(struct gk20a *g) 1287static inline unsigned long gk20a_get_gr_idle_timeout(struct gk20a *g)
1288{ 1288{
1289 return g->timeouts_enabled ? 1289 return g->timeouts_enabled ?
1290 g->gr_idle_timeout_default : MAX_SCHEDULE_TIMEOUT; 1290 g->gr_idle_timeout_default : ULONG_MAX;
1291} 1291}
1292 1292
1293enum BAR0_DEBUG_OPERATION { 1293enum BAR0_DEBUG_OPERATION {