Re: Extending virtio_console to support multiple ports

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On (Sun) Aug 30 2009 [07:48:37], Anthony Liguori wrote:
> Amit Shah wrote:
>> 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
>>   
>
> No flags, assume it's a streaming protocol and don't assume anything  
> about message sizes.  IOW, when you send clipboard data, send size and  
> then the data.  QEMU consumes bytes until it reaches size.

Same intent but a different method: I'll have to specify that particular
data is "size" and that data after this special data is the actual data
stream.

>> - 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.
>
> I don't see a problem here.

You mean you don't see a problem in using a spinlock vs not using one?

Userspace will typically send the entire buffer to be transmitted in one
system call. If it's large, the system call will have to be broken into
several. This results in multiple guest system calls, each one to be
handled with a spinlock held.

Compare this with the entire write handled in one system call in the
current method.

		Amit
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux