]> git.proxmox.com Git - qemu.git/commit
char: don't limit data sent to backends to 1k per buffer
authorAmit Shah <amit.shah@redhat.com>
Tue, 3 Nov 2009 14:29:54 +0000 (19:59 +0530)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 17 Nov 2009 14:03:30 +0000 (08:03 -0600)
commit9bd7854e1e5d6f4cfe4558090bbd9493c12bf846
tree3f26f286806d4b2bee83eef75faa38884e5bf725
parent0ef849d751408a7d0c769807af037de31b88f761
char: don't limit data sent to backends to 1k per buffer

chardevs have a 'can_read' function via which backends specify
the amount of data they can receive. When can_read returns > 0,
apps can start sending data. However, each chardev driver here
allows a max. of 1k bytes inspite of the backend being able to
receive more.

The best we can do here is to allocate s->max_size bytes from
the heap on each call (which is the number returned by the
backend from the can_read call).

This is an intermediate step to bump up the bytes written in
each call to 4k.

Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
qemu-char.c