Commit 83042d1e authored by Wei Chen's avatar Wei Chen Committed by Will Deacon
Browse files

arm: Allow all terminal ports to be bi-directional

In kvmtool, the terminal has 4 term-devices at most. And these term-devices
can connect to serial8250 or virtio console ports. The kvmtool has a loop
thread to detect the incoming data on these term-devices and then send the
data to guest through serial8250 or virtio console ports. On x86, kvmtool
allow to read data from all 4 term-devices. But on ARM, we only support reading
data from the first term-devices. The data from the other term-devices will
be ignored.

Currently, we're adding the kvmtool support to runv (a kind of hyper container)
with Hyperhq guys. Here we're using 3 serial ports in guest to communicate with
host (Container runtime). On x86, it works fine, but on ARM it could not work.
Because we're using terminal 2 to send/receive control message, but terminal 2
is single direction.

In this case, we change the kvm__arch_read_term for ARM to allow reading data
from all term-devices.

Signed-off-by: default avatarWei Chen <>
Signed-off-by: default avatarWill Deacon <>
parent 84d77496
......@@ -49,10 +49,8 @@ void kvm__arch_delete_ram(struct kvm *kvm)
void kvm__arch_read_term(struct kvm *kvm)
if (term_readable(0)) {
void kvm__arch_set_cmdline(char *cmdline, bool video)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment