[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-discuss] Redirect one uart output to other uart
From: |
Alexei Colin |
Subject: |
Re: [Qemu-discuss] Redirect one uart output to other uart |
Date: |
Thu, 31 Jan 2019 10:10:18 -0500 |
User-agent: |
Mutt/1.11.2 (2019-01-07) |
On Thu, Jan 31, 2019 at 06:30:24PM +0500, Muhammad Bilal wrote:
> Is it possible in QEMU to loopback UART devices? Like if I have two UARTS
> and I can redirect one to other. Like I connect both serial ports of target
> with each other via NULL modem?
Did you try forwarding both ports to a PTY and then tying the PTY
devices with socat on the host?
$ qemu -serial pty -serial pty ...
qemu: -serial pty: char device redirected to /dev/pts/10 (label serial0)
qemu: -serial pty: char device redirected to /dev/pts/11 (label serial1)
$ socat /dev/pts/10 /dev/pts/11
I have used pty redirection and socat in the past, but I haven't tried
your particular use case. Just giving a possible direction to look into.