sjur.brandeland at stericsson.com
2013-Feb-12 14:34 UTC
[PATCH] virtio_console: Initialize guest_connected=true for rproc_serial
From: Sjur Br?ndeland <sjur.brandeland at stericsson.com> When rproc_serial is initialized, guest_connected should be set to true. We can then revert the extra checks introduced in commit: "virtio_console: Let unconnected rproc device receive data." Signed-off-by: Sjur Br?ndeland <sjur.brandeland at stericsson.com> --- drivers/char/virtio_console.c | 7 ++----- 1 files changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 2cfd5a0..5afc8f6 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1436,7 +1436,7 @@ static int add_port(struct ports_device *portdev, u32 id) * rproc_serial does not want the console port, only * the generic port implementation. */ - port->host_connected = true; + port->host_connected = port->guest_connected = true; else if (!use_multiport(port->portdev)) { /* * If we're not using multiport support, @@ -1757,11 +1757,8 @@ static void in_intr(struct virtqueue *vq) * tty is spawned) and the host sends out data to console * ports. For generic serial ports, the host won't * (shouldn't) send data till the guest is connected. - * However a remote device might send data before the port is - * connected. So don't remove data from a rproc_serial device. */ - - if (!port->guest_connected && !is_rproc_serial(port->portdev->vdev)) + if (!port->guest_connected) discard_port_data(port); spin_unlock_irqrestore(&port->inbuf_lock, flags); -- 1.7.5.4
Rusty Russell
2013-Feb-13 10:28 UTC
[PATCH] virtio_console: Initialize guest_connected=true for rproc_serial
sjur.brandeland at stericsson.com writes:> From: Sjur Br?ndeland <sjur.brandeland at stericsson.com> > > When rproc_serial is initialized, guest_connected should be set > to true. We can then revert the extra checks introduced in > commit: "virtio_console: Let unconnected rproc device receive data." > > Signed-off-by: Sjur Br?ndeland <sjur.brandeland at stericsson.com>Thanks, applied. Cheers, Rusty.
Reasonably Related Threads
- [PATCH] virtio_console: Initialize guest_connected=true for rproc_serial
- [PATCH] Revert "virtio_console: Initialize guest_connected=true for rproc_serial"
- [PATCH] Revert "virtio_console: Initialize guest_connected=true for rproc_serial"
- [PATCH] virtio_console: Let unconnected rproc device receive data.
- [PATCH] virtio_console: Let unconnected rproc device receive data.