nmhw21,26: fix incorrect indentation
This commit is contained in:
parent
e0f24ed684
commit
e2bf817634
|
|
@ -1356,9 +1356,9 @@ static int check_break_length(int time, bool rx_line)
|
|||
duration += RESET_CHECK_PERIOD;
|
||||
|
||||
if (duration == DURATION_FACTORY_RESET) {
|
||||
/* Indicate factory reset threshold */
|
||||
blink_led(1);
|
||||
}
|
||||
/* Indicate factory reset threshold */
|
||||
blink_led(1);
|
||||
}
|
||||
else if (duration == DURATION_RECOVERY_BOOT) {
|
||||
/* Indicate recovery boot threshold and leave state */
|
||||
blink_led(2);
|
||||
|
|
@ -1473,10 +1473,10 @@ static int check_break_command(int time, int has_input, int c)
|
|||
state = DONE;
|
||||
}
|
||||
else if (c == 'r') {
|
||||
blink_led(2);
|
||||
blink_led(2);
|
||||
act = RECOVERY_BOOT;
|
||||
state = DONE;
|
||||
}
|
||||
}
|
||||
else {
|
||||
/* Unknown command */
|
||||
act = NONE;
|
||||
|
|
@ -1486,7 +1486,7 @@ static int check_break_command(int time, int has_input, int c)
|
|||
|
||||
if (wait_time > 0) {
|
||||
wait_time -= RESET_CHECK_PERIOD;
|
||||
}
|
||||
}
|
||||
else {
|
||||
/* puts("character timeout\n"); */
|
||||
act = NONE;
|
||||
|
|
@ -1565,23 +1565,23 @@ static void check_reset_button(void)
|
|||
|
||||
switch (action) {
|
||||
case FACTORY_RESET: {
|
||||
char new_bootargs[512];
|
||||
char *bootargs = getenv("bootargs");
|
||||
char new_bootargs[512];
|
||||
char *bootargs = getenv("bootargs");
|
||||
|
||||
puts("Do factory reset during boot...\n");
|
||||
puts("Do factory reset during boot...\n");
|
||||
|
||||
if (bootargs == 0) bootargs = "";
|
||||
strncpy(new_bootargs, bootargs, sizeof(new_bootargs));
|
||||
strncat(new_bootargs, " factory-reset", sizeof(new_bootargs));
|
||||
strncpy(new_bootargs, bootargs, sizeof(new_bootargs));
|
||||
strncat(new_bootargs, " factory-reset", sizeof(new_bootargs));
|
||||
|
||||
setenv("bootargs", new_bootargs);
|
||||
setenv("bootargs", new_bootargs);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
case RECOVERY_BOOT:
|
||||
puts("Booting recovery image...\n");
|
||||
puts("Booting recovery image...\n");
|
||||
|
||||
setenv("bootcmd", "run recovery");
|
||||
setenv("bootcmd", "run recovery");
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
|
|||
Loading…
Reference in New Issue