Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 666a457b authored by Sowmya Pandiri's avatar Sowmya Pandiri
Browse files

msm: vidc: Bail out of work handler if device is in DEINIT state



This change makes sure that worker thread doesn't handle any
interrupts if core is not in valid state.

Change-Id: If5493d277f4aa80df98640ed4c3854f34c12ad38
Signed-off-by: default avatarSowmya Pandiri <spandiri@codeaurora.org>
parent 095c42a3
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -3663,6 +3663,12 @@ static void venus_hfi_core_work_handler(struct work_struct *work)
	mutex_lock(&device->lock);

	dprintk(VIDC_INFO, "Handling interrupt\n");

	if (!__core_in_valid_state(device)) {
		dprintk(VIDC_DBG, "%s - Core not in init state\n", __func__);
		goto err_no_work;
	}

	if (!device->callback) {
		dprintk(VIDC_ERR, "No interrupt callback function: %p\n",
				device);