From: Oded Gabbay Date: Mon, 12 Jun 2023 11:22:07 +0000 (+0300) Subject: accel/habanalabs: remove pdev check on idle check X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=89803af5355b04f4e2583d5c7170aa3676f9c1b7;p=linux.git accel/habanalabs: remove pdev check on idle check Our simulator supports idle check so no need anymore to check if pdev exists. Signed-off-by: Oded Gabbay Reviewed-by: Ofir Bitton --- diff --git a/drivers/accel/habanalabs/common/device.c b/drivers/accel/habanalabs/common/device.c index 0d02f1f7b994f..5e61761b8c11f 100644 --- a/drivers/accel/habanalabs/common/device.c +++ b/drivers/accel/habanalabs/common/device.c @@ -424,7 +424,7 @@ static void hpriv_release(struct kref *ref) /* Check the device idle status and reset if not idle. * Skip it if already in reset, or if device is going to be reset in any case. */ - if (!hdev->reset_info.in_reset && !reset_device && hdev->pdev && !hdev->pldm) + if (!hdev->reset_info.in_reset && !reset_device && !hdev->pldm) device_is_idle = hdev->asic_funcs->is_device_idle(hdev, idle_mask, HL_BUSY_ENGINES_MASK_EXT_SIZE, NULL); if (!device_is_idle) {