Re: [PATCH 8/9] accel/rocket: Add job submission IOCTL

From: Markus Elfring
Date: Wed Sep 11 2024 - 07:28:42 EST



> +++ b/drivers/accel/rocket/rocket_job.c
> @@ -0,0 +1,708 @@

> +static int rocket_job_push(struct rocket_job *job)
> +{

> + mutex_lock(&rdev->sched_lock);
> + drm_sched_job_arm(&job->base);

> + drm_sched_entity_push_job(&job->base);
> +
> + mutex_unlock(&rdev->sched_lock);


Under which circumstances would you become interested to apply a statement
like “guard(mutex)(&rdev->sched_lock);”?
https://elixir.bootlin.com/linux/v6.11-rc7/source/include/linux/mutex.h#L196

Regards,
Markus