cmd: terminal: avoid serial_reinit_all() with DM_SERIAL enabled

serial_reinit_all() is only available when CONFIG DM_SERIAL is disabled
and CONFIG_SERIAL is enabled.

Signed-off-by: Aditya Dutt <duttaditya18@gmail.com>
This commit is contained in:
Aditya Dutt
2025-09-05 19:36:11 +05:30
committed by Tom Rini
parent 41d9ac1025
commit bbc9347a98

View File

@@ -24,7 +24,7 @@ int do_terminal(struct cmd_tbl *cmd, int flag, int argc, char *const argv[])
if (!dev)
return -1;
if (IS_ENABLED(CONFIG_SERIAL))
if (IS_ENABLED(CONFIG_SERIAL) && !IS_ENABLED(CONFIG_DM_SERIAL))
serial_reinit_all();
printf("Entering terminal mode for port %s\n", dev->name);