accel/habanalabs: prevent sending heartbeat before events are enabled
authorfarah kassabri <fkassabri@habana.ai>
Sun, 27 Aug 2023 16:01:20 +0000 (19:01 +0300)
committerOded Gabbay <ogabbay@kernel.org>
Mon, 9 Oct 2023 09:37:21 +0000 (12:37 +0300)
commit051868d93cfd342b4ff8e6297b93a6a43dbe81b3
treed1e8be371a20ba38c3343b091c82bf99aa9ff94e
parent764bfd138f359423b299b7bf3fcbabb56b981ef5
accel/habanalabs: prevent sending heartbeat before events are enabled

After the heartbeat mechanism is now expanded to be used also
for EQ health check, we shouldn't send heartbeat messages
to FW before driver allow events to be received from FW.

Because if the driver will send two heartbeats before it enables
events to be received from FW, then the EQ health check
will fail and reset the device.

Signed-off-by: farah kassabri <fkassabri@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/accel/habanalabs/common/device.c