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-devel

[Xen-devel] [PATCH] mini-os: fbfront shouldn't send unsolicited updates

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] mini-os: fbfront shouldn't send unsolicited updates
From: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>
Date: Fri, 29 Feb 2008 12:35:41 +0000
Delivery-date: Fri, 29 Feb 2008 04:36:40 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Mail-followup-to: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.12-2006-07-14
mini-os: fbfront shouldn't send unsolicited updates

Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>

diff -r 067d8f19e78a extras/mini-os/fbfront.c
--- a/extras/mini-os/fbfront.c  Thu Feb 28 13:55:37 2008 +0000
+++ b/extras/mini-os/fbfront.c  Fri Feb 29 12:33:08 2008 +0000
@@ -245,6 +245,7 @@ struct fbfront_dev {
 
     char *nodename;
     char *backend;
+    int request_update;
 
     char *data;
     int width;
@@ -379,7 +380,7 @@ done:
     printk("backend at %s\n", dev->backend);
 
     {
-        char path[strlen(dev->backend) + 1 + 6 + 1];
+        char path[strlen(dev->backend) + 1 + 14 + 1];
 
         snprintf(path, sizeof(path), "%s/state", dev->backend);
 
@@ -390,6 +391,9 @@ done:
         printk("%s connected\n", dev->backend);
 
         xenbus_unwatch_path(XBT_NIL, path);
+
+        snprintf(path, sizeof(path), "%s/request-update", dev->backend);
+        dev->request_update = xenbus_read_integer(path);
 
         err = xenbus_printf(XBT_NIL, nodename, "state", "%u", 4); /* connected 
*/
     }
@@ -404,6 +408,9 @@ void fbfront_update(struct fbfront_dev *
     struct xenfb_page *page = dev->page;
     uint32_t prod;
     DEFINE_WAIT(w);
+
+    if (dev->request_update <= 0)
+        return;
 
     if (x < 0) {
         width += x;

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] mini-os: fbfront shouldn't send unsolicited updates, Samuel Thibault <=