projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e41c641
)
habanalabs: check fence pointer before use
author
Oded Gabbay
<ogabbay@kernel.org>
Sun, 19 Jun 2022 09:35:06 +0000
(12:35 +0300)
committer
Oded Gabbay
<ogabbay@kernel.org>
Tue, 12 Jul 2022 06:09:23 +0000
(09:09 +0300)
fence pointer can be NULL in this path, as shown by an earlier check.
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/misc/habanalabs/common/command_submission.c
patch
|
blob
|
history
diff --git
a/drivers/misc/habanalabs/common/command_submission.c
b/drivers/misc/habanalabs/common/command_submission.c
index c050f38b7091f833c392b1c4127ae208f9bb9663..e5549a9da42e24ca0dae0b5d9aad7f2d37cc7851 100644
(file)
--- a/
drivers/misc/habanalabs/common/command_submission.c
+++ b/
drivers/misc/habanalabs/common/command_submission.c
@@
-2581,7
+2581,7
@@
static int hl_cs_poll_fences(struct multi_cs_data *mcs_data, struct multi_cs_com
* For this we have to validate that the timestamp is
* earliest of all timestamps so far.
*/
- if (mcs_data->update_ts &&
+ if (
fence &&
mcs_data->update_ts &&
(ktime_compare(fence->timestamp, first_cs_time) < 0))
first_cs_time = fence->timestamp;
break;