Amit Shah
2010-May-05 20:35 UTC
[PATCH 0/3] virtio: console: Handle multiple console port resizes
Hello, This series adds resize support for multiple console ports. The size for each console is stored in its structure and the host informs the guest about size changes via the VIRTIO_CONSOLE_RESIZE control message. This is easily tested by the qemu patches provided by Kusanagi Kouichi with some updates, which I will shortly send to the qemu-devel list. Please apply, Amit. Amit Shah (3): virtio: console: Resize console port 0 on config intr only if multiport is off virtio: console: Store each console's size in the console structure virtio: console: Accept console size along with resize control message drivers/char/virtio_console.c | 71 ++++++++++++++++++++++++++++++----------- 1 files changed, 52 insertions(+), 19 deletions(-)
Amit Shah
2010-May-05 20:35 UTC
[PATCH 1/3] virtio: console: Resize console port 0 on config intr only if multiport is off
When using multiport, we'll use control messages. Ensure we don't accidentally update port 0 size on config interrupts. Signed-off-by: Amit Shah <amit.shah at redhat.com> CC: Christian Borntraeger <borntraeger at de.ibm.com> CC: linuxppc-dev at ozlabs.org CC: Kusanagi Kouichi <slash at ac.auone-net.jp> --- drivers/char/virtio_console.c | 17 ++++++++++------- 1 files changed, 10 insertions(+), 7 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index a64558f..e2d05ea 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1319,13 +1319,16 @@ static void config_intr(struct virtio_device *vdev) portdev = vdev->priv; - /* - * We'll use this way of resizing only for legacy support. - * For newer userspace (VIRTIO_CONSOLE_F_MULTPORT+), use - * control messages to indicate console size changes so that - * it can be done per-port - */ - resize_console(find_port_by_id(portdev, 0)); + if (!use_multiport(portdev)) { + /* + * We'll use this way of resizing only for legacy + * support. For newer userspace + * (VIRTIO_CONSOLE_F_MULTPORT+), use control messages + * to indicate console size changes so that it can be + * done per-port. + */ + resize_console(find_port_by_id(portdev, 0)); + } } static int init_vqs(struct ports_device *portdev) -- 1.6.2.5
Rusty Russell
2010-May-06 02:27 UTC
[PATCH 0/3] virtio: console: Handle multiple console port resizes
On Thu, 6 May 2010 06:05:06 am Amit Shah wrote:> Hello, > > This series adds resize support for multiple console ports. The size > for each console is stored in its structure and the host informs the > guest about size changes via the VIRTIO_CONSOLE_RESIZE control > message.Thanks, applied! Rusty.
Seemingly Similar Threads
- [PATCH 0/3] virtio: console: Handle multiple console port resizes
- virtio: console: Return -EFAULT on copy_xx_user errors, allow larger writes
- virtio: console: Return -EFAULT on copy_xx_user errors, allow larger writes
- [PATCH 4/4] virtio: disable multiport console support.
- [PATCH 4/4] virtio: disable multiport console support.