- __loopscycles++;
- if (!(__loopscycles)) {
- if(timeout_remaining) timeout_remaining--;
- else stayinloader&=0xf1;
+# ifdef CONFIG_HAVE__BOOTLOADER_ABORTTIMEOUTONACT
+ if (stayinloader != 0x0e) {
+ /* can be reached, since high-nibble is decreased every cycle... */
+#else
+ if (stayinloader & 0x01) {
+#endif
+ timeout_remaining = BOOTLOADER_LOOPCYCLES_TIMEOUT;
+ } else {
+ __loopscycles++;
+ if (!(__loopscycles)) {
+ if(timeout_remaining) timeout_remaining--;
+ else stayinloader&=0xf1;
+ }