mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 10:04:04 +02:00
accel/ivpu: Trigger engine reset for additional job status codes
Trigger engine reset for any status code in the range. This allows to add additional status codes in the future without breaking compatibility between the firmware and the driver. Signed-off-by: Andrzej Kacprowski <Andrzej.Kacprowski@intel.com> Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com> Signed-off-by: Karol Wachowski <karol.wachowski@linux.intel.com> Link: https://lore.kernel.org/r/20251007083511.2817021-1-karol.wachowski@linux.intel.com
This commit is contained in:
parent
39a0283dba
commit
4139eb2490
|
|
@ -574,7 +574,11 @@ static int ivpu_job_signal_and_destroy(struct ivpu_device *vdev, u32 job_id, u32
|
|||
if (!job)
|
||||
return -ENOENT;
|
||||
|
||||
if (job_status == VPU_JSM_STATUS_MVNCI_CONTEXT_VIOLATION_HW) {
|
||||
switch (job_status) {
|
||||
case VPU_JSM_STATUS_PROCESSING_ERR:
|
||||
case VPU_JSM_STATUS_ENGINE_RESET_REQUIRED_MIN ... VPU_JSM_STATUS_ENGINE_RESET_REQUIRED_MAX:
|
||||
{
|
||||
/* Trigger an engine reset */
|
||||
guard(mutex)(&job->file_priv->lock);
|
||||
|
||||
if (job->file_priv->has_mmu_faults)
|
||||
|
|
@ -589,6 +593,10 @@ static int ivpu_job_signal_and_destroy(struct ivpu_device *vdev, u32 job_id, u32
|
|||
queue_work(system_wq, &vdev->context_abort_work);
|
||||
return 0;
|
||||
}
|
||||
default:
|
||||
/* Complete job with error status, engine reset not required */
|
||||
break;
|
||||
}
|
||||
|
||||
job = ivpu_job_remove_from_submitted_jobs(vdev, job_id);
|
||||
if (!job)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user