[Xen-devel] [PATCH] libxl: libxl__ev_fd_callback: Document perhaps-no-retry semantics

2018-10-15 Thread Ian Jackson
Signed-off-by: Ian Jackson 
CC: Anthony PERARD 
---
 tools/libxl/libxl_internal.h | 8 
 1 file changed, 8 insertions(+)

diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h
index 43947b1b07..153566acd0 100644
--- a/tools/libxl/libxl_internal.h
+++ b/tools/libxl/libxl_internal.h
@@ -232,6 +232,14 @@ typedef void libxl__ev_fd_callback(libxl__egc *egc, 
libxl__ev_fd *ev,
* It is not permitted to listen for the same or overlapping events
* on the same fd using multiple different libxl__ev_fd's.
*
+   * Note that (depending on the underlying event loop implementation)
+   * it is possible that a the fd callback system is `level triggered'
+   * or `event triggered'.  That is, the callback may be called only
+   * once for each transition from not ready to ready.  So the
+   * callback must generally contain a loop which exhausts the fd,
+   * rather than relying on being called again if the fd is still
+   * ready.
+   *
* (Spurious wakeups, and spurious bits set in revents, are
* suppressed by the libxl event core.)
*/
-- 
2.11.0


___
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Re: [Xen-devel] [PATCH] libxl: libxl__ev_fd_callback: Document perhaps-no-retry semantics

2018-10-30 Thread Wei Liu
On Mon, Oct 15, 2018 at 03:01:07PM +0100, Ian Jackson wrote:
> Signed-off-by: Ian Jackson 
> CC: Anthony PERARD 

I think you understand the event machinery more than I do, so feel free
to apply this patch.

Wei.

___
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Re: [Xen-devel] [PATCH] libxl: libxl__ev_fd_callback: Document perhaps-no-retry semantics

2018-10-30 Thread Ian Jackson
Wei Liu writes ("Re: [PATCH] libxl: libxl__ev_fd_callback: Document 
perhaps-no-retry semantics"):
> On Mon, Oct 15, 2018 at 03:01:07PM +0100, Ian Jackson wrote:
> > Signed-off-by: Ian Jackson 
> > CC: Anthony PERARD 
> 
> I think you understand the event machinery more than I do, so feel free
> to apply this patch.

Thanks.  Done, and the other two.

Ian.

___
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel