From: Tomer Tayar Date: Tue, 17 Jan 2023 13:50:41 +0000 (+0200) Subject: habanalabs: run error handling if scrub_device_mem fails after reset X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=0c93eb098f21074555b9b08ab60d1c3e3129f3da;p=linux.git habanalabs: run error handling if scrub_device_mem fails after reset If device memory scrubbing from hl_device_reset() fails, we return with an error code but not perform error handling code. Signed-off-by: Tomer Tayar Reviewed-by: Oded Gabbay Signed-off-by: Oded Gabbay --- diff --git a/drivers/accel/habanalabs/common/device.c b/drivers/accel/habanalabs/common/device.c index 9a9c494b08a40..edeec35fd9c6c 100644 --- a/drivers/accel/habanalabs/common/device.c +++ b/drivers/accel/habanalabs/common/device.c @@ -1738,7 +1738,7 @@ kill_processes: rc = hdev->asic_funcs->scrub_device_mem(hdev); if (rc) { dev_err(hdev->dev, "scrub mem failed from device reset (%d)\n", rc); - return rc; + goto out_err; } spin_lock(&hdev->reset_info.lock);