diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
commit | fc22b3d6507c6745911b9dfcc68f1e665ae13dbc (patch) | |
tree | ce1e3bce06471410239a6f41282e328770aa404a /templates/man2/eventfd.2.pot | |
parent | Initial commit. (diff) | |
download | manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.tar.xz manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.zip |
Adding upstream version 4.22.0.upstream/4.22.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'templates/man2/eventfd.2.pot')
-rw-r--r-- | templates/man2/eventfd.2.pot | 991 |
1 files changed, 991 insertions, 0 deletions
diff --git a/templates/man2/eventfd.2.pot b/templates/man2/eventfd.2.pot new file mode 100644 index 00000000..e4dc1cd8 --- /dev/null +++ b/templates/man2/eventfd.2.pot @@ -0,0 +1,991 @@ +# SOME DESCRIPTIVE TITLE +# Copyright (C) YEAR Free Software Foundation, Inc. +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"POT-Creation-Date: 2024-03-01 16:55+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. type: TH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "eventfd" +msgstr "" + +#. type: TH +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "2023-10-31" +msgstr "" + +#. type: TH +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "Linux man-pages 6.06" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "NAME" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "eventfd - create a file descriptor for event notification" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "LIBRARY" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "Standard C library (I<libc>, I<-lc>)" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "SYNOPSIS" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<#include E<lt>sys/eventfd.hE<gt>>\n" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<int eventfd(unsigned int >I<initval>B<, int >I<flags>B<);>\n" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "DESCRIPTION" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"B<eventfd>() creates an \"eventfd object\" that can be used as an event " +"wait/notify mechanism by user-space applications, and by the kernel to " +"notify user-space applications of events. The object contains an unsigned " +"64-bit integer (I<uint64_t>) counter that is maintained by the kernel. " +"This counter is initialized with the value specified in the argument " +"I<initval>." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"As its return value, B<eventfd>() returns a new file descriptor that can be " +"used to refer to the eventfd object." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The following values may be bitwise ORed in I<flags> to change the behavior " +"of B<eventfd>():" +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EFD_CLOEXEC> (since Linux 2.6.27)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Set the close-on-exec (B<FD_CLOEXEC>) flag on the new file descriptor. See " +"the description of the B<O_CLOEXEC> flag in B<open>(2) for reasons why this " +"may be useful." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EFD_NONBLOCK> (since Linux 2.6.27)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Set the B<O_NONBLOCK> file status flag on the open file description (see " +"B<open>(2)) referred to by the new file descriptor. Using this flag saves " +"extra calls to B<fcntl>(2) to achieve the same result." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EFD_SEMAPHORE> (since Linux 2.6.30)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Provide semaphore-like semantics for reads from the new file descriptor. " +"See below." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Up to Linux 2.6.26, the I<flags> argument is unused, and must be specified " +"as zero." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The following operations can be performed on the file descriptor returned by " +"B<eventfd>():" +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<read>(2)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Each successful B<read>(2) returns an 8-byte integer. A B<read>(2) fails " +"with the error B<EINVAL> if the size of the supplied buffer is less than 8 " +"bytes." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The value returned by B<read>(2) is in host byte order\\[em]that is, the " +"native byte order for integers on the host machine." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The semantics of B<read>(2) depend on whether the eventfd counter currently " +"has a nonzero value and whether the B<EFD_SEMAPHORE> flag was specified when " +"creating the eventfd file descriptor:" +msgstr "" + +#. type: IP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "\\[bu]" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"If B<EFD_SEMAPHORE> was not specified and the eventfd counter has a nonzero " +"value, then a B<read>(2) returns 8 bytes containing that value, and the " +"counter's value is reset to zero." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"If B<EFD_SEMAPHORE> was specified and the eventfd counter has a nonzero " +"value, then a B<read>(2) returns 8 bytes containing the value 1, and the " +"counter's value is decremented by 1." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"If the eventfd counter is zero at the time of the call to B<read>(2), then " +"the call either blocks until the counter becomes nonzero (at which time, the " +"B<read>(2) proceeds as described above) or fails with the error B<EAGAIN> " +"if the file descriptor has been made nonblocking." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<write>(2)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A B<write>(2) call adds the 8-byte integer value supplied in its buffer to " +"the counter. The maximum value that may be stored in the counter is the " +"largest unsigned 64-bit value minus 1 (i.e., 0xfffffffffffffffe). If the " +"addition would cause the counter's value to exceed the maximum, then the " +"B<write>(2) either blocks until a B<read>(2) is performed on the file " +"descriptor, or fails with the error B<EAGAIN> if the file descriptor has " +"been made nonblocking." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A B<write>(2) fails with the error B<EINVAL> if the size of the supplied " +"buffer is less than 8 bytes, or if an attempt is made to write the value " +"0xffffffffffffffff." +msgstr "" + +#. type: TP +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "B<poll>(2)" +msgstr "" + +#. type: TQ +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "B<select>(2)" +msgstr "" + +#. type: TQ +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "(and similar)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The returned file descriptor supports B<poll>(2) (and analogously " +"B<epoll>(7)) and B<select>(2), as follows:" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The file descriptor is readable (the B<select>(2) I<readfds> argument; the " +"B<poll>(2) B<POLLIN> flag) if the counter has a value greater than 0." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The file descriptor is writable (the B<select>(2) I<writefds> argument; the " +"B<poll>(2) B<POLLOUT> flag) if it is possible to write a value of at least " +"\"1\" without blocking." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"If an overflow of the counter value was detected, then B<select>(2) " +"indicates the file descriptor as being both readable and writable, and " +"B<poll>(2) returns a B<POLLERR> event. As noted above, B<write>(2) can " +"never overflow the counter. However an overflow can occur if 2\\[ha]64 " +"eventfd \"signal posts\" were performed by the KAIO subsystem (theoretically " +"possible, but practically unlikely). If an overflow has occurred, then " +"B<read>(2) will return that maximum I<uint64_t> value (i.e., " +"0xffffffffffffffff)." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The eventfd file descriptor also supports the other file-descriptor " +"multiplexing APIs: B<pselect>(2) and B<ppoll>(2)." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<close>(2)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"When the file descriptor is no longer required it should be closed. When " +"all file descriptors associated with the same eventfd object have been " +"closed, the resources for object are freed by the kernel." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A copy of the file descriptor created by B<eventfd>() is inherited by the " +"child produced by B<fork>(2). The duplicate file descriptor is associated " +"with the same eventfd object. File descriptors created by B<eventfd>() are " +"preserved across B<execve>(2), unless the close-on-exec flag has been set." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "RETURN VALUE" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"On success, B<eventfd>() returns a new eventfd file descriptor. On error, " +"-1 is returned and I<errno> is set to indicate the error." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "ERRORS" +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EINVAL>" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "An unsupported value was specified in I<flags>." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EMFILE>" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The per-process limit on the number of open file descriptors has been " +"reached." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENFILE>" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The system-wide limit on the total number of open files has been reached." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENODEV>" +msgstr "" + +#. Note from Davide: +#. The ENODEV error is basically never going to happen if +#. the kernel boots correctly. That error happen only if during +#. the kernel initialization, some error occur in the anonymous +#. inode source initialization. +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "Could not mount (internal) anonymous inode device." +msgstr "" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENOMEM>" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "There was insufficient memory to create a new eventfd file descriptor." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "ATTRIBUTES" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"For an explanation of the terms used in this section, see B<attributes>(7)." +msgstr "" + +#. type: tbl table +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Interface" +msgstr "" + +#. type: tbl table +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Attribute" +msgstr "" + +#. type: tbl table +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Value" +msgstr "" + +#. type: tbl table +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-tumbleweed +#, no-wrap +msgid ".na\n" +msgstr "" + +#. type: tbl table +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-tumbleweed +#, no-wrap +msgid ".nh\n" +msgstr "" + +#. #-#-#-#-# archlinux: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# debian-bookworm: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: tbl table +#. #-#-#-#-# debian-unstable: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# fedora-40: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# fedora-rawhide: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# mageia-cauldron: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# opensuse-leap-15-6: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#. #-#-#-#-# opensuse-tumbleweed: eventfd.2.pot (PACKAGE VERSION) #-#-#-#-# +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<eventfd>()" +msgstr "" + +#. type: tbl table +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Thread safety" +msgstr "" + +#. type: tbl table +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "MT-Safe" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "VERSIONS" +msgstr "" + +#. type: SS +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "C library/kernel differences" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"There are two underlying Linux system calls: B<eventfd>() and the more " +"recent B<eventfd2>(). The former system call does not implement a I<flags> " +"argument. The latter system call implements the I<flags> values described " +"above. The glibc wrapper function will use B<eventfd2>() where it is " +"available." +msgstr "" + +#. type: SS +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Additional glibc features" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The GNU C library defines an additional type, and two functions that attempt " +"to abstract some of the details of reading and writing on an eventfd file " +"descriptor:" +msgstr "" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-tumbleweed +#, no-wrap +msgid "" +"typedef uint64_t eventfd_t;\n" +"\\&\n" +"int eventfd_read(int fd, eventfd_t *value);\n" +"int eventfd_write(int fd, eventfd_t value);\n" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The functions perform the read and write operations on an eventfd file " +"descriptor, returning 0 if the correct number of bytes was transferred, or " +"-1 otherwise." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "STANDARDS" +msgstr "" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +msgid "Linux, GNU." +msgstr "" + +#. type: SH +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "HISTORY" +msgstr "" + +#. eventfd() is in glibc 2.7, but reportedly does not build +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +msgid "Linux 2.6.22, glibc 2.8." +msgstr "" + +#. type: TP +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<eventfd2>()" +msgstr "" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Linux 2.6.27 (see VERSIONS). Since glibc 2.9, the B<eventfd>() wrapper " +"will employ the B<eventfd2>() system call, if it is supported by the kernel." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "NOTES" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Applications can use an eventfd file descriptor instead of a pipe (see " +"B<pipe>(2)) in all cases where a pipe is used simply to signal events. The " +"kernel overhead of an eventfd file descriptor is much lower than that of a " +"pipe, and only one file descriptor is required (versus the two required for " +"a pipe)." +msgstr "" + +#. or eventually syslets/threadlets +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"When used in the kernel, an eventfd file descriptor can provide a bridge " +"from kernel to user space, allowing, for example, functionalities like KAIO " +"(kernel AIO) to signal to a file descriptor that some operation is complete." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A key point about an eventfd file descriptor is that it can be monitored " +"just like any other file descriptor using B<select>(2), B<poll>(2), or " +"B<epoll>(7). This means that an application can simultaneously monitor the " +"readiness of \"traditional\" files and the readiness of other kernel " +"mechanisms that support the eventfd interface. (Without the B<eventfd>() " +"interface, these mechanisms could not be multiplexed via B<select>(2), " +"B<poll>(2), or B<epoll>(7).)" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The current value of an eventfd counter can be viewed via the entry for the " +"corresponding file descriptor in the process's I</proc/>pidI</fdinfo> " +"directory. See B<proc>(5) for further details." +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "EXAMPLES" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The following program creates an eventfd file descriptor and then forks to " +"create a child process. While the parent briefly sleeps, the child writes " +"each of the integers supplied in the program's command-line arguments to the " +"eventfd file descriptor. When the parent has finished sleeping, it reads " +"from the eventfd file descriptor." +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The following shell session shows a sample run of the program:" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "" +"$B< ./a.out 1 2 4 7 14>\n" +"Child writing 1 to efd\n" +"Child writing 2 to efd\n" +"Child writing 4 to efd\n" +"Child writing 7 to efd\n" +"Child writing 14 to efd\n" +"Child completed write loop\n" +"Parent about to read\n" +"Parent read 28 (0x1c) from efd\n" +msgstr "" + +#. type: SS +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "Program source" +msgstr "" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-tumbleweed +#, no-wrap +msgid "" +"#include E<lt>err.hE<gt>\n" +"#include E<lt>inttypes.hE<gt>\n" +"#include E<lt>stdio.hE<gt>\n" +"#include E<lt>stdlib.hE<gt>\n" +"#include E<lt>sys/eventfd.hE<gt>\n" +"#include E<lt>unistd.hE<gt>\n" +"\\&\n" +"int\n" +"main(int argc, char *argv[])\n" +"{\n" +" int efd;\n" +" uint64_t u;\n" +" ssize_t s;\n" +"\\&\n" +" if (argc E<lt> 2) {\n" +" fprintf(stderr, \"Usage: %s E<lt>numE<gt>...\\en\", argv[0]);\n" +" exit(EXIT_FAILURE);\n" +" }\n" +"\\&\n" +" efd = eventfd(0, 0);\n" +" if (efd == -1)\n" +" err(EXIT_FAILURE, \"eventfd\");\n" +"\\&\n" +" switch (fork()) {\n" +" case 0:\n" +" for (size_t j = 1; j E<lt> argc; j++) {\n" +" printf(\"Child writing %s to efd\\en\", argv[j]);\n" +" u = strtoull(argv[j], NULL, 0);\n" +" /* strtoull() allows various bases */\n" +" s = write(efd, &u, sizeof(uint64_t));\n" +" if (s != sizeof(uint64_t))\n" +" err(EXIT_FAILURE, \"write\");\n" +" }\n" +" printf(\"Child completed write loop\\en\");\n" +"\\&\n" +" exit(EXIT_SUCCESS);\n" +"\\&\n" +" default:\n" +" sleep(2);\n" +"\\&\n" +" printf(\"Parent about to read\\en\");\n" +" s = read(efd, &u, sizeof(uint64_t));\n" +" if (s != sizeof(uint64_t))\n" +" err(EXIT_FAILURE, \"read\");\n" +" printf(\"Parent read %\"PRIu64\" (%#\"PRIx64\") from efd\\en\", u, u);\n" +" exit(EXIT_SUCCESS);\n" +"\\&\n" +" case -1:\n" +" err(EXIT_FAILURE, \"fork\");\n" +" }\n" +"}\n" +msgstr "" + +#. SRC END +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "SEE ALSO" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"B<futex>(2), B<pipe>(2), B<poll>(2), B<read>(2), B<select>(2), " +"B<signalfd>(2), B<timerfd_create>(2), B<write>(2), B<epoll>(7), " +"B<sem_overview>(7)" +msgstr "" + +#. type: TH +#: debian-bookworm +#, no-wrap +msgid "2023-02-10" +msgstr "" + +#. type: TH +#: debian-bookworm +#, no-wrap +msgid "Linux man-pages 6.03" +msgstr "" + +#. type: TP +#: debian-bookworm debian-unstable opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<poll>(2), B<select>(2) (and similar)" +msgstr "" + +#. eventfd() is in glibc 2.7, but reportedly does not build +#. type: Plain text +#: debian-bookworm +msgid "" +"B<eventfd>() is available since Linux 2.6.22. Working support is provided " +"since glibc 2.8. The B<eventfd2>() system call (see NOTES) is available " +"since Linux 2.6.27. Since glibc 2.9, the B<eventfd>() wrapper will employ " +"the B<eventfd2>() system call, if it is supported by the kernel." +msgstr "" + +#. type: Plain text +#: debian-bookworm +msgid "B<eventfd>() and B<eventfd2>() are Linux-specific." +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "typedef uint64_t eventfd_t;\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"int eventfd_read(int fd, eventfd_t *value);\n" +"int eventfd_write(int fd, eventfd_t value);\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"#include E<lt>err.hE<gt>\n" +"#include E<lt>inttypes.hE<gt>\n" +"#include E<lt>stdio.hE<gt>\n" +"#include E<lt>stdlib.hE<gt>\n" +"#include E<lt>sys/eventfd.hE<gt>\n" +"#include E<lt>unistd.hE<gt>\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"int\n" +"main(int argc, char *argv[])\n" +"{\n" +" int efd;\n" +" uint64_t u;\n" +" ssize_t s;\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" if (argc E<lt> 2) {\n" +" fprintf(stderr, \"Usage: %s E<lt>numE<gt>...\\en\", argv[0]);\n" +" exit(EXIT_FAILURE);\n" +" }\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" efd = eventfd(0, 0);\n" +" if (efd == -1)\n" +" err(EXIT_FAILURE, \"eventfd\");\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" switch (fork()) {\n" +" case 0:\n" +" for (size_t j = 1; j E<lt> argc; j++) {\n" +" printf(\"Child writing %s to efd\\en\", argv[j]);\n" +" u = strtoull(argv[j], NULL, 0);\n" +" /* strtoull() allows various bases */\n" +" s = write(efd, &u, sizeof(uint64_t));\n" +" if (s != sizeof(uint64_t))\n" +" err(EXIT_FAILURE, \"write\");\n" +" }\n" +" printf(\"Child completed write loop\\en\");\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid " exit(EXIT_SUCCESS);\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" default:\n" +" sleep(2);\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" printf(\"Parent about to read\\en\");\n" +" s = read(efd, &u, sizeof(uint64_t));\n" +" if (s != sizeof(uint64_t))\n" +" err(EXIT_FAILURE, \"read\");\n" +" printf(\"Parent read %\"PRIu64\" (%#\"PRIx64\") from efd\\en\", u, u);\n" +" exit(EXIT_SUCCESS);\n" +msgstr "" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" case -1:\n" +" err(EXIT_FAILURE, \"fork\");\n" +" }\n" +"}\n" +msgstr "" + +#. type: TH +#: debian-unstable opensuse-tumbleweed +#, no-wrap +msgid "2023-07-20" +msgstr "" + +#. type: TH +#: debian-unstable opensuse-tumbleweed +#, no-wrap +msgid "Linux man-pages 6.05.01" +msgstr "" + +#. type: TH +#: opensuse-leap-15-6 +#, no-wrap +msgid "2023-03-30" +msgstr "" + +#. type: TH +#: opensuse-leap-15-6 +#, no-wrap +msgid "Linux man-pages 6.04" +msgstr "" |