[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] Re: Extending virtio_console to support multiple ports
From: |
Amit Shah |
Subject: |
[Qemu-devel] Re: Extending virtio_console to support multiple ports |
Date: |
Sun, 30 Aug 2009 15:40:57 +0530 |
User-agent: |
Mutt/1.5.19 (2009-01-05) |
On (Fri) Aug 28 2009 [12:00:08], Anthony Liguori wrote:
> Amit Shah wrote:
>> On (Tue) Aug 25 2009 [11:47:20], Amit Shah wrote:
>>
>>> Hello all,
>>>
>>> Here is a new iteration of the patch series that implements a
>>> transport for guest and host communications.
>>>
>>> The code has been updated to reuse the virtio-console device instead
>>> of creating a new virtio-serial device.
>>>
>>
>> And the problem now is that hvc calls the put_chars function with
>> spinlocks held and we now allocate pages in send_buf(), called from
>> put_chars.
>>
>
> Don't allocate pages in send_buf. There's a fixed number of possible
> entries on the ring. Preallocate them up front and then you don't need
> to sleep.
I did think about that as well, but there are problems:
- vnc clients (at least tigervnc) wants to receive the entire clipboard
in a single flush command. So in the pre-allocated buffers scenario we
could run short of the available buffers in some cases. So there will
have to be a flag with each buffer that says 'there's more data
pending for this particular write' which will have to be passed on to
qemu and qemu will then flush it once it receives all the data
- A lock has to be introduced to fetch one unused buffer from the list
and pass it on to the host. And this lock has to be a spinlock, just
because writes can be called from irq context.
We're basically just turning a simple transport into more and more
complex code just to handle this special case.
Amit
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, (continued)
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Benjamin Herrenschmidt, 2009/08/27
- Re: [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/27
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Alan Cox, 2009/08/28
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Benjamin Herrenschmidt, 2009/08/27
- [Qemu-devel] [PATCH] hvc_console: provide (un)locked version for hvc_resize(), Hendrik Brueckner, 2009/08/28
- Re: [Qemu-devel] Re: Extending virtio_console to support multiple ports, Jamie Lokier, 2009/08/28
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Michael Ellerman, 2009/08/28
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/27
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Ryan Arnold, 2009/08/28
[Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/28
- [Qemu-devel] Re: Extending virtio_console to support multiple ports,
Amit Shah <=
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/30
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/30
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Amit Shah, 2009/08/31
- [Qemu-devel] Re: Extending virtio_console to support multiple ports, Anthony Liguori, 2009/08/31