ARM: EXYNOS: Fix thermal throttle once tripping

Once TMU_STATUS_TRIPPED was reached, thermal_throttle() was not
being called.

Bug: 7958312
Change-Id: I93f7825dacc62867036dbf75d14f7aaf1007d699
Signed-off-by: JP Abgrall <jpa@google.com>
diff --git a/arch/arm/mach-exynos/tmu-exynos.c b/arch/arm/mach-exynos/tmu-exynos.c
index 58a31bf..da38e82 100644
--- a/arch/arm/mach-exynos/tmu-exynos.c
+++ b/arch/arm/mach-exynos/tmu-exynos.c
@@ -107,10 +107,10 @@
 		enable_irq(info->irq);
 		goto out;
 	case TMU_STATUS_THROTTLED:
+		if (cur_temp > data->ts.stop_throttle)
+			exynos_thermal_throttle();
 		if (cur_temp >= data->ts.start_tripping)
 			info->tmu_state = TMU_STATUS_TRIPPED;
-		else if (cur_temp > data->ts.stop_throttle)
-			exynos_thermal_throttle();
 		else
 			info->tmu_state = TMU_STATUS_NORMAL;
 		break;
@@ -118,10 +118,15 @@
 		if (cur_temp >= data->ts.start_emergency)
 			panic("Emergency thermal shutdown: temp=%d\n",
 			      cur_temp);
-		if (cur_temp >= data->ts.start_tripping)
+		if (cur_temp >= data->ts.start_tripping) {
 			pr_err("thermal tripped: temp=%d\n", cur_temp);
-		else
+			/* Throttle twice while tripping */
+			exynos_thermal_throttle();
+		} else {
 			info->tmu_state = TMU_STATUS_THROTTLED;
+		}
+		/* Throttle when tripped */
+		exynos_thermal_throttle();
 		break;
 	default:
 		break;