[msm8660] Add support for reboot reason code

Linux kernel writes to shared location in APPSBL EBI; apps bootloader
reads this location the reboot reason, scrubs it and acts accordingly.

This location may move to IMEM area in future once room is made for
HLOS in IMEM.

Change-Id: I39b45cad6bbd25fdbc513ef74eb2608fc8b37cf8
diff --git a/app/aboot/aboot.c b/app/aboot/aboot.c
index 2e51ea9..5fdf7ab 100644
--- a/app/aboot/aboot.c
+++ b/app/aboot/aboot.c
@@ -646,18 +646,19 @@
 		goto fastboot;
 	#endif
 
+	reboot_mode = check_reboot_mode();
+	if (reboot_mode == RECOVERY_MODE) {
+		boot_into_recovery = 1;
+	} else if(reboot_mode == FASTBOOT_MODE) {
+		goto fastboot;
+	}
+
 	if (target_is_emmc_boot())
 	{
 		boot_linux_from_mmc();
 	}
 	else
 	{
-		reboot_mode = check_reboot_mode();
-		if (reboot_mode == RECOVERY_MODE) {
-			boot_into_recovery = 1;
-		} else if(reboot_mode == FASTBOOT_MODE) {
-			goto fastboot;
-		}
 		recovery_init();
 		boot_linux_from_flash();
 	}