This is an automated email from the ASF dual-hosted git repository.
GUIDINGLI pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push:
new 67d57303ee9 boards/sim: enable the virtio serial device in rpserver
and rpproxy
67d57303ee9 is described below
commit 67d57303ee991848662b85cc4c84bbc5f6349792
Author: Bowen Wang <[email protected]>
AuthorDate: Tue Nov 24 23:02:13 2026 +0800
boards/sim: enable the virtio serial device in rpserver and rpproxy
The sim rptun resource table has a virtio serial vdev (virtio-serial on
the master, vhost-serial on the slave, forwarded to the slave's
/dev/ttyVH0), but neither config enabled a driver for it. The server
never set DRIVER_OK on that vdev, so the proxy's rptun thread polled for
it until the link went down:
proxy> ps
4 0 0 224 FIFO Kthread - Waiting Signal ... rptun
server
Enable DRIVERS_VIRTIO_SERIAL on sim:rpserver. On sim:rpproxy enable
DRIVERS_VHOST_SERIAL and register a sim UART as /dev/ttyVH0, backed by a
host pseudoterminal, so that the server's /dev/ttyV0 reaches a host pty.
Signed-off-by: Bowen Wang <[email protected]>
---
boards/sim/sim/sim/configs/rpproxy/defconfig | 4 ++++
boards/sim/sim/sim/configs/rpserver/defconfig | 1 +
2 files changed, 5 insertions(+)
diff --git a/boards/sim/sim/sim/configs/rpproxy/defconfig
b/boards/sim/sim/sim/configs/rpproxy/defconfig
index 42e8fe27d2f..3c99b0ffcfa 100644
--- a/boards/sim/sim/sim/configs/rpproxy/defconfig
+++ b/boards/sim/sim/sim/configs/rpproxy/defconfig
@@ -23,6 +23,7 @@ CONFIG_DEV_RPMSG=y
CONFIG_DEV_SIMPLE_ADDRENV=y
CONFIG_DRIVERS_VHOST_RNG=y
CONFIG_DRIVERS_VHOST_RPMSG=y
+CONFIG_DRIVERS_VHOST_SERIAL=y
CONFIG_ETC_ROMFS=y
CONFIG_EXAMPLES_HELLO=y
CONFIG_EXAMPLES_RPMSGSOCKET=y
@@ -73,6 +74,9 @@ CONFIG_SENSORS=y
CONFIG_SENSORS_RPMSG=y
CONFIG_SIG_DEFAULT=y
CONFIG_SIM_M32=y
+CONFIG_SIM_UART0_NAME="/dev/ttyVH0"
+CONFIG_SIM_UART_NUMBER=1
+CONFIG_SIM_UART_PTY=y
CONFIG_SYSLOG_PREFIX=y
CONFIG_SYSLOG_PREFIX_STRING="proxy"
CONFIG_SYSLOG_RPMSG=y
diff --git a/boards/sim/sim/sim/configs/rpserver/defconfig
b/boards/sim/sim/sim/configs/rpserver/defconfig
index abfdcf2c3c0..c53258a5b68 100644
--- a/boards/sim/sim/sim/configs/rpserver/defconfig
+++ b/boards/sim/sim/sim/configs/rpserver/defconfig
@@ -24,6 +24,7 @@ CONFIG_DEV_RPMSG_SERVER=y
CONFIG_DEV_SIMPLE_ADDRENV=y
CONFIG_DRIVERS_VIRTIO_RNG=y
CONFIG_DRIVERS_VIRTIO_RPMSG=y
+CONFIG_DRIVERS_VIRTIO_SERIAL=y
CONFIG_ETC_ROMFS=y
CONFIG_EXAMPLES_RPMSGSOCKET=y
CONFIG_EXPERIMENTAL=y