mirror of
https://github.com/torvalds/linux.git
synced 2024-12-11 13:41:55 +00:00
habanalabs: fix soft reset flow in case of failure
In case of soft reset failure, hard reset should be initiated, but reset flags were not set to enable it, which caused another soft reset followed by another failure. Updated reset flags to enable hard reset flow in case of soft reset failure. Signed-off-by: Dani Liberman <dliberman@habana.ai> Reviewed-by: Oded Gabbay <ogabbay@kernel.org> Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
This commit is contained in:
parent
aa3e1f12a2
commit
15f8eb1905
@ -1293,11 +1293,14 @@ out_err:
|
||||
hdev->reset_info.hard_reset_cnt++;
|
||||
} else if (reset_upon_device_release) {
|
||||
dev_err(hdev->dev, "Failed to reset device after user release\n");
|
||||
flags |= HL_DRV_RESET_HARD;
|
||||
flags &= ~HL_DRV_RESET_DEV_RELEASE;
|
||||
hard_reset = true;
|
||||
goto again;
|
||||
} else {
|
||||
dev_err(hdev->dev, "Failed to do soft-reset\n");
|
||||
hdev->reset_info.soft_reset_cnt++;
|
||||
flags |= HL_DRV_RESET_HARD;
|
||||
hard_reset = true;
|
||||
goto again;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user