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

Commit e38ccc9e authored by Rama Krishna Phani A's avatar Rama Krishna Phani A
Browse files

thermal: tsens: Update condition in critical_irq



Device crash is observed when the critical_irq is triggered because of
accessing uninitialized completion variable.

Update condition in critical_irq such that the completion variable will be
accessed only when initialized.

Change-Id: I0cba089882024bbe36ac4798866af4e33ee02fa2
Signed-off-by: default avatarRama Krishna Phani A <rphani@codeaurora.org>
parent a4165c57
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -2453,7 +2453,7 @@ static irqreturn_t tsens_tm_critical_irq_thread(int irq, void *data)
	tm->crit_timestamp_last_interrupt_handled.time_stmp[idx%10] =
							sched_clock();
	tm->qtimer_val_last_detection_interrupt = arch_counter_get_cntpct();

	if (tsens_poll_check)
		complete(&tm->tsens_rslt_completion);
	/* Mask critical interrupt */
	mb();