ARM: OMAP3+: SmartReflex: clear ERRCONFIG_VPBOUNDINTST only on a need
authorNishanth Menon <nm@ti.com>
Wed, 29 Feb 2012 22:33:42 +0000 (23:33 +0100)
committerGrazvydas Ignotas <notasas@gmail.com>
Sun, 15 May 2016 12:43:21 +0000 (15:43 +0300)
commit7c211f00ae84306696b7287fb230b0fae035b7d5
treef71cf6856a9bd0e939223574e059d587f9858089
parentb245e671d2e6b8a897f950ec7b094f6d33477f3b
ARM: OMAP3+: SmartReflex: clear ERRCONFIG_VPBOUNDINTST only on a need

The VPBOUNDINTST field of the ERRCONFIG register has an additional
functional meaning of force clearing the SR internal signal with VP
(sr_interruptz).
This can result in scenarios where the VP->SR protocol is violated
because the SR internal signal with VP is already high and VP will
never clear the vpirqclr signal.
Therefore during the next force update to reset to nominal voltage,
VP cannot pulse vpirqclr, so the PRCM HW cannot generate the tranxdone
IRQ and the situation is not recoverable until a cold reset is invoked.

To prevent this situation, check if status is set before clearing it
as this needs to be done only on a need basis.

Reported-by: Vincent Bour <v-bour@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Jean Pihet <j-pihet@ti.com>
Reviewed-by: Kevin Hilman <khilman@ti.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
arch/arm/mach-omap2/smartreflex.c