WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] Send event-channel notification from console daemon

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Send event-channel notification from console daemon
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 05 Oct 2005 15:46:11 +0000
Delivery-date: Wed, 05 Oct 2005 15:43:42 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 438f1b53682b8b796be5374e5f148f0617829a28
# Parent  072fb38810a60dcfd14b599f0dcdf2eac89a1143
Send event-channel notification from console daemon
to guest console driver when the output ring is
emptied. This can be used to kick transmission of
more characters without needing to poll.

Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>

diff -r 072fb38810a6 -r 438f1b53682b tools/console/daemon/io.c
--- a/tools/console/daemon/io.c Wed Oct  5 14:15:50 2005
+++ b/tools/console/daemon/io.c Wed Oct  5 15:32:07 2005
@@ -86,8 +86,11 @@
        struct ring_head *ring = (struct ring_head *)dom->page;
        size_t size;
        u32 oldcons;
+       int notify = 0;
 
        while ((size = ring->prod - ring->cons) != 0) {
+               notify = 1;
+
                if ((buffer->capacity - buffer->size) < size) {
                        buffer->capacity += (size + 1024);
                        buffer->data = realloc(buffer->data, buffer->capacity);
@@ -115,6 +118,9 @@
                        buffer->capacity = buffer->max_capacity;
                }
        }
+
+       if (notify)
+               xc_evtchn_send(xc, dom->local_port);
 }
 
 static bool buffer_empty(struct buffer *buffer)

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Send event-channel notification from console daemon, Xen patchbot -unstable <=