drivers: thermal: Ignore spurious BCL interrupts whenever BCL is in polling

Whenever BCL interrupt triggers, it notifies thermal framework.
The framework disables the BCL interrupt and initiates a passive
polling to monitor clear threshold. But BCL peripheral interrupts
are lazy IRQ disable in nature by default. Even if BCL has initiated
disable interrupt, there is a chance it may take some time to disable
in hardware. During this time hardware can trigger interrupt again.
But BCL driver assumes it as spurious interrupt and disables the
interrupt again which will cause permanent disablement of that
interrupt.

If BCL interrupt is triggering again post BCL interrupt
disable, just ignore that interrupt to avoid nested interrupt
disablement. From above scenario, BCL is already in polling mode,
ignoring this spurious interrupt doesn't cause any issue.

Change-Id: Ia77fc66eaf66f97bacee96906cc6a5735a6ed158
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
1 file changed