|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From 3144ebcad37422dd85220915d37e7e9eea36564a Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Date: Thu, 25 Sep 2014 17:27:27 -0400
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Subject: [PATCH] man: add sd_event_add_signal(3)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
---
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Makefile-man.am | 7 ++
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_add_signal.xml | 196 ++++++++++++++++++++++++++++++++++++++++++++
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_add_time.xml | 24 ++++--
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
3 files changed, 221 insertions(+), 6 deletions(-)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
create mode 100644 man/sd_event_add_signal.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/Makefile-man.am b/Makefile-man.am
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index 199c731e7e..85a3612f39 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/Makefile-man.am
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/Makefile-man.am
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -741,6 +741,7 @@ MANPAGES += \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_open_user.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_path_encode.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_request_name.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ man/sd_event_add_signal.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_add_time.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_new.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/systemd-bus-proxyd.8 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -802,6 +803,7 @@ MANPAGES_ALIAS += \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_unref.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_default.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_ref.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ man/sd_event_source_get_signal.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time_accuracy.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time_clock.3 \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -865,6 +867,7 @@ man/sd_bus_release_name.3: man/sd_bus_request_name.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_unref.3: man/sd_bus_new.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_default.3: man/sd_event_new.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_ref.3: man/sd_event_new.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+man/sd_event_source_get_signal.3: man/sd_event_add_signal.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time.3: man/sd_event_add_time.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time_accuracy.3: man/sd_event_add_time.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time_clock.3: man/sd_event_add_time.3
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -1040,6 +1043,9 @@ man/sd_event_default.html: man/sd_event_new.html
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_ref.html: man/sd_event_new.html
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
$(html-alias)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+man/sd_event_source_get_signal.html: man/sd_event_add_signal.html
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ $(html-alias)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_source_get_time.html: man/sd_event_add_time.html
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
$(html-alias)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -1542,6 +1548,7 @@ EXTRA_DIST += \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_open_user.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_path_encode.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_bus_request_name.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ man/sd_event_add_signal.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_add_time.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_event_new.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
man/sd_get_seats.xml \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/man/sd_event_add_signal.xml b/man/sd_event_add_signal.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
new file mode 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index 0000000000..2344fb3c02
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- /dev/null
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/man/sd_event_add_signal.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -0,0 +1,196 @@
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+This file is part of systemd.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+Copyright 2014 Zbigniew Jędrzejewski-Szmek
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+systemd is free software; you can redistribute it and/or modify it
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+under the terms of the GNU Lesser General Public License as published by
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+the Free Software Foundation; either version 2.1 of the License, or
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+(at your option) any later version.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+systemd is distributed in the hope that it will be useful, but
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+Lesser General Public License for more details.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+You should have received a copy of the GNU Lesser General Public License
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+along with systemd; If not, see <http://www.gnu.org/licenses/>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+-->
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+<refentry id="sd_event_add_signal" conditional="ENABLE_KDBUS">
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refentryinfo>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>sd_event_add_signal</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <productname>systemd</productname>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <authorgroup>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <author>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <contrib>More text</contrib>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <firstname>Zbigniew</firstname>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <surname>Jędrzejewski-Szmek</surname>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <email>zbyszek@in.waw.pl</email>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </author>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </authorgroup>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refentryinfo>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refmeta>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refentrytitle>sd_event_add_signal</refentrytitle>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <manvolnum>3</manvolnum>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refmeta>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refnamediv>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refname>sd_event_add_signal</refname>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refname>sd_event_source_get_signal</refname>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refpurpose>Add a signal event source to an event loop</refpurpose>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refnamediv>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsynopsisdiv>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcsynopsis>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcsynopsisinfo>#include <systemd/sd-bus.h></funcsynopsisinfo>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcdef>int <function>sd_event_add_signal</function></funcdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event *<parameter>event</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event_source **<parameter>source</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>int <parameter>signal</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event_signal_handler_t <parameter>handler</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>void *<parameter>userdata</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcdef>typedef int (*<function>sd_event_signal_handler_t</function>)</funcdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event_source *<parameter>s</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>const struct signalfd_siginfo *<parameter>si</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>void *<parameter>userdata</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcdef>int <function>sd_event_source_get_signal</function></funcdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event_source *<parameter>source</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </funcsynopsis>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsynopsisdiv>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>Description</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para><function>sd_event_add_signal()</function> adds a new signal
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ event source to an event loop object. The event loop is specified
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ in <parameter>event</parameter>, the event source is returned in
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ the <parameter>source</parameter> parameter. The
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <parameter>signal</parameter> parameter specifies the signal to be handled
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ (see
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>signal</refentrytitle><manvolnum>7</manvolnum></citerefentry>).
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ The <parameter>handler</parameter> must reference a function to
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ call when the signal is delivered or be <constant>NULL</constant>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ The handler function will be passed the
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <parameter>userdata</parameter> pointer, which may be chosen
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ freely by the caller. The handler also receives a pointer to a
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <structname>const struct signalfd_siginfo</structname> containing
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ the information about the received signal. See
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>signalfd</refentrytitle><manvolnum>2</manvolnum></citerefentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ for futher information.</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para>Only a single handler may be installed for a specific
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ signal. The signal will be unblocked, and must be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ blocked when the function is called. If the handler is not
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ specified (<parameter>handler</parameter> is
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <constant>NULL</constant>), a default handler which causes the
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ program to exit will be used. By default, the handler is enabled
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ permanently (<constant>SD_EVENT_ON</constant>), but this may be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ changed with
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_source_set_enabled</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ If the handler function returns a negative error code, it will be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ disabled after the invocation, even if
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <constant>SD_EVENT_ON</constant> mode is set.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para><function>sd_event_source_get_signal()</function> retrieves
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ the configured signal number of a signal event source created
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ previously with <function>sd_event_add_signal()</function>. It
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ takes the event source object as the <parameter>source</parameter>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ parameter.</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>Return Value</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para>On success, these functions return 0 or a positive
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ integer. On failure, they return a negative errno-style error
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ code. </para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>Errors</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para>Returned errors may indicate the following problems:</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <variablelist>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <term><varname>-ENOMEM</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>Not enough memory to allocate an object.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <term><varname>-EINVAL</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>An invalid argument has been passed.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <term><varname>-EBUSY</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>An handler is already installed for this
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ signal or the signal was not blocked previously.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <term><varname>-ESTALE</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>The event loop is already terminated.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <term><varname>-ECHILD</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>The event loop has been created in a different process.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </variablelist>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>Notes</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para><function>sd_event_add_signal()</function> and the other functions
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ described here are available as a shared library, which can be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ compiled and linked to with the
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <constant>libsystemd</constant> <citerefentry project='die-net'><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ file.</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <title>See Also</title>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd-event</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_new</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_add_time</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_source_set_enabled</refentrytitle><manvolnum>3</manvolnum></citerefentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </refsect1>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+</refentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/man/sd_event_add_time.xml b/man/sd_event_add_time.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index a3304f7985..d3775e5d5f 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/man/sd_event_add_time.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/man/sd_event_add_time.xml
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -69,6 +69,13 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
</funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcdef>typedef int (*<function>sd_event_time_handler_t</function>)</funcdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>sd_event_source *<parameter>s</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>uint64_t <parameter>usec</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <paramdef>void *<parameter>userdata</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ </funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <funcprototype>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<funcdef>int <function>sd_event_source_get_time</function></funcdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<paramdef>sd_event_source *<parameter>source</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<paramdef>usec_t *<parameter>usec</parameter></paramdef>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -132,11 +139,15 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
actually have been called at a slightly later time, subject to the
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
specified accuracy value, the kernel timer slack (see
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>prctl</refentrytitle><manvolnum>2</manvolnum></citerefentry>)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- and additional scheduling latencies. By default, the timer will
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- elapse once (SD_EVENT_ONESHOT), but this may be changed with
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- <citerefentry><refentrytitle>sd_event_source_set_enabled</refentrytitle><manvolnum>3</manvolnum></citerefentry>. If
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- the handler function returns a negative error code, it will be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- disabled after the invocation, even if SD_EVENT_ON mode is set.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ and additional scheduling latencies.</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <para>By default, the timer will elapse once
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ (<constant>SD_EVENT_ONESHOT</constant>), but this may be changed
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ with
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_source_set_enabled</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ If the handler function returns a negative error code, it will be
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ disabled after the invocation, even if
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <constant>SD_EVENT_ON</constant> mode is set.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
</para>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<para><function>sd_event_source_get_time()</function> retrieves
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -187,7 +198,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<term><varname>-ENOMEM</varname></term>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- <listitem><para>Not enough memory to allocate object.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <listitem><para>Not enough memory to allocate an object.</para></listitem>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
</varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<varlistentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -237,6 +248,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>sd-event</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>sd_event_new</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ <citerefentry><refentrytitle>sd_event_add_signal</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>clock_gettime</refentrytitle><manvolnum>2</manvolnum></citerefentry>,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
<citerefentry><refentrytitle>sd_event_source_set_enabled</refentrytitle><manvolnum>3</manvolnum></citerefentry>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
</para>
|