serial/uart_rpmsg: use config option for console registration

Parameter isconsole in uart_rpmsg_init() has two effects: set uart
terminal flags for typical console use and register the device as
/dev/console. These are separate things. The latter might not be
wanted in all cases.

Use the already existing config option CONFIG_RPMSG_UART_CONSOLE to
conditionally register the uart as console device.

Signed-off-by: Maarten Zanders <maarten@zanders.be>
This commit is contained in:
Maarten Zanders
2026-02-18 16:52:20 +01:00
committed by Alan C. Assis
parent 9e063b1784
commit be66d39552
+2
View File
@@ -458,10 +458,12 @@ int uart_rpmsg_init(FAR const char *cpuname, FAR const char *devname,
UART_RPMSG_DEV_PREFIX, devname);
uart_register(name, dev);
#ifdef CONFIG_RPMSG_UART_CONSOLE
if (dev->isconsole)
{
uart_register(UART_RPMSG_DEV_CONSOLE, dev);
}
#endif
return 0;
}