# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1204542293 0
# Node ID 56a7feb9de1457a646a5438c9668c2d835cb02f5
# Parent 703afd373e33178b51301691fa70a9864f5e10ed
mini-os: fbfront shouldn't send unsolicited updates
Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>
---
extras/mini-os/fbfront.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletion(-)
diff -r 703afd373e33 -r 56a7feb9de14 extras/mini-os/fbfront.c
--- a/extras/mini-os/fbfront.c Mon Mar 03 11:02:58 2008 +0000
+++ b/extras/mini-os/fbfront.c Mon Mar 03 11:04:53 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-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|