Skip to content

Commit ac38214

Browse files
kivikakktrini
authored andcommitted
terminal: only serial_reinit_all if available
serial_reinit_all() is only available if CONFIG_SERIAL is defined (i.e. !CONFIG_DM_SERIAL). Signed-off-by: Asherah Connor <[email protected]> Reviewed-by: Simon Glass <[email protected]>
1 parent 5c935eb commit ac38214

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

cmd/terminal.c

+3-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,9 @@ int do_terminal(struct cmd_tbl *cmd, int flag, int argc, char *const argv[])
2525
if (!dev)
2626
return -1;
2727

28-
serial_reinit_all();
28+
if (IS_ENABLED(CONFIG_SERIAL))
29+
serial_reinit_all();
30+
2931
printf("Entering terminal mode for port %s\n", dev->name);
3032
puts("Use '~.' to leave the terminal and get back to u-boot\n");
3133

0 commit comments

Comments
 (0)