Commit abe85a9c authored by Oded Gabbay's avatar Oded Gabbay

habanalabs: check fence pointer before use

fence pointer can be NULL in this path, as shown by an earlier check.
Signed-off-by: default avatarOded Gabbay <ogabbay@kernel.org>
parent e41c6418
......@@ -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;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment