power: pm8xxx-ccadc: fix irq race condition
There could be an interrupt triggered right after requesting it and
before disabling it in the probe function. The invoking of interrupt
also disables itself. The net result is that we end up disabling
the interrupt twice. We would need two enables to really enable the
interrupt. The result of this is that we would never program the
offset value unless calibration is called twice.
Fix this by checking if the invocation is while in the probe function.
We can use the_chip pointer and simply return if it is not initialized.
Change-Id: Ifa70a4daf01414dfafed7830e3a6a682c42e9364
Signed-off-by:
Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Loading
Please register or sign in to comment