John D. Ramsdell
2006-Jul-18 11:41 UTC
[Xen-devel] Re: [RFC PATCH 24/33] Add support for Xen event channels.
Chris, I read with interest your patch for adding support for Xen event channels. I notice that evtchn.h uses an int to represent a port, as demonstrated, for example, in the following two declarations:> +extern void mask_evtchn(int port); > +extern void unmask_evtchn(int port);Using a signed integer is good because negative numbers can be use to return error conditions from functions that cannot be confused with valid port numbers. For code used within Mini-OS, I''ve been using evtchn_port_t, which is defined in xen-unstable/xen/include/public/event_channel.h as: typedef uint32_t evtchn_port_t; Is there a plan to harmonize this representation of a port with yours, and make it a signed integer? I also notice that xen-unstable/xen/include/public/grant_table.h defines grant_ref_t and grant_handle_t to be unsigned. Once again, having a representation of these items that unambiguously represent error codes and not valid data seems to me to be very useful. John _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Reasonably Related Threads
- [PATCH] linux-2.6.18/backends: use xenbus_be.ko interfaces instead of open-coding them
- [PATCH] PVWin: Fix warnings
- [PATCH 3/3] gnttab: cleanup
- [PATCH] xenconsoled: ignore spurious watch event
- [PATCH] Xenconsoled should ignore spurious watch event. Otherwise, it can rebind to the same evtchn of a dying domU during suspending and cause below error message: