diff options
Diffstat (limited to 'man7/epoll.7')
-rw-r--r-- | man7/epoll.7 | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/man7/epoll.7 b/man7/epoll.7 index bc5fa9b27e..ffb409a51e 100644 --- a/man7/epoll.7 +++ b/man7/epoll.7 @@ -29,14 +29,14 @@ API is the .IR instance , an in-kernel data structure which, from a user-space perspective, can be considered as a container for two lists: -.IP \(bu 3 +.IP \[bu] 3 The .I interest list (sometimes also called the .B epoll set): the set of file descriptors that the process has registered an interest in monitoring. -.IP \(bu +.IP \[bu] The .I ready list: the set of file descriptors that are "ready" for I/O. @@ -50,7 +50,7 @@ The following system calls are provided to create and manage an .B epoll instance: -.IP \(bu 3 +.IP \[bu] 3 .BR epoll_create (2) creates a new .B epoll @@ -59,13 +59,13 @@ instance and returns a file descriptor referring to that instance. .BR epoll_create1 (2) extends the functionality of .BR epoll_create (2).) -.IP \(bu +.IP \[bu] Interest in particular file descriptors is then registered via .BR epoll_ctl (2), which adds items to the interest list of the .B epoll instance. -.IP \(bu +.IP \[bu] .BR epoll_wait (2) waits for I/O events, blocking the calling thread if no events are currently available. @@ -355,7 +355,7 @@ calling with .BR EPOLL_CTL_MOD . .SS Questions and answers -.IP \(bu 3 +.IP \[bu] 3 What is the key used to distinguish the file descriptors registered in an interest list? .IP @@ -363,7 +363,7 @@ The key is the combination of the file descriptor number and the open file description (also known as an "open file handle", the kernel's internal representation of an open file). -.IP \(bu +.IP \[bu] What happens if you register the same file descriptor on an .B epoll instance twice? @@ -397,7 +397,7 @@ This can be a useful technique for filtering events, if the duplicate file descriptors are registered with different .I events masks. -.IP \(bu +.IP \[bu] Can two .B epoll instances wait for the same file descriptor? @@ -407,7 +407,7 @@ file descriptors? .IP Yes, and events would be reported to both. However, careful programming may be needed to do this correctly. -.IP \(bu +.IP \[bu] Is the .B epoll file descriptor itself poll/epoll/selectable? @@ -417,7 +417,7 @@ If an .B epoll file descriptor has events waiting, then it will indicate as being readable. -.IP \(bu +.IP \[bu] What happens if one attempts to put an .B epoll file descriptor into its own file descriptor set? @@ -431,14 +431,14 @@ However, you can add an file descriptor inside another .B epoll file descriptor set. -.IP \(bu +.IP \[bu] Can I send an .B epoll file descriptor over a UNIX domain socket to another process? .IP Yes, but it does not make sense to do this, since the receiving process would not have copies of the file descriptors in the interest list. -.IP \(bu +.IP \[bu] Will closing a file descriptor cause it to be removed from all .B epoll interest lists? @@ -477,13 +477,13 @@ behind the scenes by library functions that used .BR dup (2) or .BR fork (2)). -.IP \(bu +.IP \[bu] If more than one event occurs between .BR epoll_wait (2) calls, are they combined or reported separately? .IP They will be combined. -.IP \(bu +.IP \[bu] Does an operation on a file descriptor affect the already collected but not yet reported events? .IP @@ -491,7 +491,7 @@ You can do two operations on an existing file descriptor. Remove would be meaningless for this case. Modify will reread available I/O. -.IP \(bu +.IP \[bu] Do I need to continuously read/write a file descriptor until .B EAGAIN @@ -530,7 +530,7 @@ The same is true when writing using (Avoid this latter technique if you cannot guarantee that the monitored file descriptor always refers to a stream-oriented file.) .SS Possible pitfalls and ways to avoid them -.IP \(bu 3 +.IP \[bu] 3 .B Starvation (edge-triggered) .IP If there is a large amount of I/O space, @@ -546,7 +546,7 @@ remember which files need to be processed but still round robin amongst all the ready files. This also supports ignoring subsequent events you receive for file descriptors that are already ready. -.IP \(bu +.IP \[bu] .B If using an event cache... .IP If you use an event cache or store all the file descriptors returned from |