summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/include/nvgpu/timers.h
diff options
context:
space:
mode:
authorKonsta Holtta <kholtta@nvidia.com>2016-12-12 03:10:08 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2016-12-19 18:40:36 -0500
commit92fe0007496fd42983a6849b4f8dd5bc7d124834 (patch)
tree8d8469893fa630f428ba5036c6c63475ccc822d6 /drivers/gpu/nvgpu/include/nvgpu/timers.h
parent8efeebaac53265428848fd64545ca10a6fd6e601 (diff)
gpu: nvgpu: rename timeout_check to timeout_expired
Change "check" to "expired" in nvgpu_timeout_check* and append _expired to nvgpu_timeout_peek to clarify what the boolean-like return value means and thus avoid bugs. Bug 200260715 Change-Id: I47e097ee922e856005a79fa9e27eddb1c8d77f8b Signed-off-by: Konsta Holtta <kholtta@nvidia.com> Reviewed-on: http://git-master/r/1269366 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/include/nvgpu/timers.h')
-rw-r--r--drivers/gpu/nvgpu/include/nvgpu/timers.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/timers.h b/drivers/gpu/nvgpu/include/nvgpu/timers.h
index e46982c9..0ecbc183 100644
--- a/drivers/gpu/nvgpu/include/nvgpu/timers.h
+++ b/drivers/gpu/nvgpu/include/nvgpu/timers.h
@@ -74,21 +74,21 @@ struct nvgpu_timeout {
74 74
75int nvgpu_timeout_init(struct gk20a *g, struct nvgpu_timeout *timeout, 75int nvgpu_timeout_init(struct gk20a *g, struct nvgpu_timeout *timeout,
76 int duration, unsigned long flags); 76 int duration, unsigned long flags);
77int nvgpu_timeout_peek(struct nvgpu_timeout *timeout); 77int nvgpu_timeout_peek_expired(struct nvgpu_timeout *timeout);
78 78
79#define nvgpu_timeout_check(__timeout) \ 79#define nvgpu_timeout_expired(__timeout) \
80 __nvgpu_timeout_check_msg(__timeout, \ 80 __nvgpu_timeout_expired_msg(__timeout, \
81 __builtin_return_address(0), "") 81 __builtin_return_address(0), "")
82 82
83#define nvgpu_timeout_check_msg(__timeout, fmt, args...) \ 83#define nvgpu_timeout_expired_msg(__timeout, fmt, args...) \
84 __nvgpu_timeout_check_msg(__timeout, \ 84 __nvgpu_timeout_expired_msg(__timeout, \
85 __builtin_return_address(0), \ 85 __builtin_return_address(0), \
86 fmt, ##args) 86 fmt, ##args)
87 87
88/* 88/*
89 * Don't use this directly. 89 * Don't use this directly.
90 */ 90 */
91int __nvgpu_timeout_check_msg(struct nvgpu_timeout *timeout, 91int __nvgpu_timeout_expired_msg(struct nvgpu_timeout *timeout,
92 void *caller, const char *fmt, ...); 92 void *caller, const char *fmt, ...);
93 93
94#endif 94#endif