0 | module System.Linux.Eventfd.Eventfd
 1 |
 2 | import Data.C.Ptr
 3 | import System.Posix.File.FileDesc
 4 |
 5 | %default total
 6 |
 7 | ||| A file descriptor for basic file events.
 8 | |||
 9 | ||| This can be used as an event wait/notify mechanism similar to
10 | ||| a `Condition` variable.
11 | export
12 | record Eventfd where
13 |   constructor EFD
14 |   fd : Bits32
15 |
16 | export %inline
17 | Cast Eventfd Fd where cast = MkFd . fd
18 |
19 | export %inline
20 | Cast CInt Eventfd where cast = EFD . cast
21 |