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

[Xen-changelog] [xen-unstable] ioemu: limit xen-console buffering



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1214908731 -3600
# Node ID 73a4fbdfe0c4f3a840fbf322993750fe4e2c8704
# Parent  763c32fdbd13111cfc0f5eca0d858ff3d5732207
ioemu: limit xen-console buffering
Set dom->buffer.max_capacity to xend configured limit.

Signed-off-by: Pat Campbell <plc@xxxxxxxxxx>
---
 tools/ioemu/hw/xen_console.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff -r 763c32fdbd13 -r 73a4fbdfe0c4 tools/ioemu/hw/xen_console.c
--- a/tools/ioemu/hw/xen_console.c      Tue Jul 01 10:59:09 2008 +0100
+++ b/tools/ioemu/hw/xen_console.c      Tue Jul 01 11:38:51 2008 +0100
@@ -160,16 +160,18 @@ int xs_gather(struct xs_handle *xs, cons
 
 static int domain_create_ring(struct domain *dom)
 {
-       int err, remote_port, ring_ref, rc;
+       int err, remote_port, ring_ref, limit, rc;
 
        err = xs_gather(dom->xsh, dom->serialpath,
                        "ring-ref", "%u", &ring_ref,
                        "port", "%i", &remote_port,
+                       "limit", "%i", &limit,
                        NULL);
        if (err) {
                err = xs_gather(dom->xsh, dom->conspath,
                                "ring-ref", "%u", &ring_ref,
                                "port", "%i", &remote_port,
+                               "limit", "%i", &limit,
                                NULL);
                if (err) {
                        fprintf(stderr, "Console: failed to find ring-ref/port 
yet\n");
@@ -178,7 +180,9 @@ static int domain_create_ring(struct dom
                dom->use_consolepath = 1;
        } else
                dom->use_consolepath = 0;
-       fprintf(stderr, "Console: got ring-ref %d port %d\n", ring_ref, 
remote_port);
+       dom->buffer.max_capacity = limit;
+       fprintf(stderr, "Console: got ring-ref %d port %d limit %d\n", 
+               ring_ref, remote_port, limit);
 
        if ((ring_ref == dom->ring_ref) && (remote_port == dom->remote_port))
                goto out;

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.