OSDN Git Service

habanalabs/gaudi: invoke device reset from one code block
authorTal Cohen <talcohen@habana.ai>
Wed, 8 Jun 2022 13:02:09 +0000 (16:02 +0300)
committerOded Gabbay <ogabbay@kernel.org>
Tue, 12 Jul 2022 06:09:22 +0000 (09:09 +0300)
commitbe572e67dafbf8004d46a2c9d97338c107efb60e
treee44e645f4276837d00249d721937a9620d20bfdb
parent647469148360dc873405acc6fcf63772e9e401f4
habanalabs/gaudi: invoke device reset from one code block

In order to prepare the driver code for device reset event
notification, change the event handler function flow to call
device reset from one code block.

In addition, the commit fixes an issue that reset was performed
w/o checking the 'hard_reset_on_fw_event' state and w/o setting
the HL_DRV_RESET_DELAY flag.

Signed-off-by: Tal Cohen <talcohen@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/misc/habanalabs/gaudi/gaudi.c