|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] Re: [PATCH] Mini-OS to use evtchn_port_t for ports and other
> > Why maybe_bind? Do you ever expect to need to allocate an unbound
> > event channel before you know what handler to use for it?
> I wanted to capture the usual pattern of immediately binding a port
> after it's allocated, without forcing programmers to follow that
> pattern.
That's not a bad idea, but I'd rather leave this until we have an
example of some actual code which needs it.
> > > + evtchn_port_t port = op.u.bind_interdomain.local_port;
> > > + clear_evtchn(port); /* Without, handler gets invoked now! */
> > Invoking the handler as soon as you bind the interdomain channel is
> > a mostly-deliberate part of the interface. If the other end makes
> > notifications before you get around to binding they can get lost,
> > and forcing the channel to fire as soon as you bind to it avoids
> > some potential lost wakeups.
> It's easy to simulate the case of a handler call on binding with
> clear_evtchn included, but a pain to handle the case in which one
> wants the handler to be invoked only when a notification arrives,
> when it is omitted.
I think you have a point here. Consider my objection withdrawn.
Steven.
signature.asc
Description: Digital signature
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|