summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>1999-03-03 20:40:51 +0000
committerMartin Mares <mj@ucw.cz>1999-03-03 20:40:51 +0000
commit0e889c52542508dd49433bed1785072cb7799009 (patch)
tree063c3f8e43638a8249ce99497c88237c4f4ba7b7
parent2d14045224f2233aed386eddf155d10a81892c3f (diff)
Added a hack forcing protocols with priority>0 to be started up
immediately. Grrr, need to find a real solution some day.
-rw-r--r--nest/proto.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/nest/proto.c b/nest/proto.c
index 76120fa8..cbafeb39 100644
--- a/nest/proto.c
+++ b/nest/proto.c
@@ -319,6 +319,12 @@ proto_notify_state(struct proto *p, unsigned ps)
ASSERT(ops == PS_DOWN || ops == PS_START);
ASSERT(cs == FS_HUNGRY);
DBG("%s: Scheduling meal\n", p->name);
+ if (p->proto->priority) /* FIXME: Terrible hack to get synchronous device/kernel startup! */
+ {
+ p->core_state = FS_FEEDING;
+ proto_feed(p);
+ return;
+ }
cs = FS_FEEDING;
p->attn->hook = proto_feed;
ev_schedule(p->attn);