Upload Tizen:Base source
[framework/base/util-linux-ng.git] / sys-utils / rtcwake.8
1 .\" Copyright (c) 2007, SUSE LINUX Products GmbH
2 .\"                     Bernhard Walle <bwalle@suse.de>
3 .\"
4 .\" This program is free software; you can redistribute it and/or
5 .\" modify it under the terms of the GNU General Public License
6 .\" as published by the Free Software Foundation; either version 2
7 .\" of the License, or (at your option) any later version.
8 .\"
9 .\" This program is distributed in the hope that it will be useful,
10 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
11 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 .\" GNU General Public License for more details.
13 .\"
14 .\" You should have received a copy of the GNU General Public License
15 .\" along with this program; if not, write to the Free Software
16 .\" Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17 .\" 02110-1301, USA.
18 .\"
19 .TH rtcwake 8 "2007-07-13" "" "Linux Programmer's Manual"
20 .SH NAME
21 rtcwake - enter a system sleep state until specified wakeup time
22 .SH SYNOPSIS
23 .B rtcwake
24 .RB [ \-hvVlua ]
25 .RB [ \-d
26 .IR device ]
27 .RB [ \-m
28 .IR standby_mode ]
29 .RB { "\-t \fItime_t\fP" | "\-s \fIseconds\fP" }
30 .SH DESCRIPTION
31 This program is used to enter a system sleep state until specified wakeup time.
32 .PP
33 This uses cross-platform Linux interfaces to enter a system sleep state, and
34 leave it no later than a specified time.  It uses any RTC framework driver that
35 supports standard driver model wakeup flags.
36 .PP
37 This is normally used like the old \fBapmsleep\fP utility, to wake from a suspend
38 state like ACPI S1 (standby) or S3 (suspend-to-RAM).  Most platforms can
39 implement those without analogues of BIOS, APM, or ACPI.
40 .P
41 On some systems, this can also be used like \fBnvram-wakeup\fP, waking from states
42 like ACPI S4 (suspend to disk).  Not all systems have persistent media that are
43 appropriate for such suspend modes.
44 .SS Options
45 .TP
46 \fB-v\fP | \fB--verbose\fP
47 Be verbose.
48 .TP
49 \fB-h\fP | \fB--help\fP
50 Display a short help message that shows how to use the program.
51 .TP
52 \fB-V\fP | \fB--version\fP
53 Displays version information and exists.
54 .TP
55 \fB-a\fP | \fB--auto\fP
56 Reads the clock mode (whether the hardware clock is set to UTC or local time)
57 from \fI/etc/adjtime\fP. That's the location where the
58 .BR hwclock (8)
59 stores that information.
60 .TP
61 \fB-l\fP | \fB--local\fP
62 Assumes that the hardware clock is set to local time, regardless of the
63 contents of \fI/etc/adjtime\fP.
64 .TP
65 \fB-u\fP | \fB--utc\fP
66 Assumes that the hardware clock is set to UTC (Universal Time Coordinated),
67 regardless of the contents of \fI/etc/adjtime\fP.
68 .TP
69 \fB-d\fP \fIdevice\fP | \fB--device\fP \fIdevice\fP
70 Uses \fIdevice\fP instead of \fIrtc0\fP as realtime clock. This option
71 is only relevant if your system has more than one RTC. You may specify
72 \fIrtc1\fP, \fIrtc2\fP, ... here.
73 .TP
74 \fB-s\fP \fIseconds\fP | \fB--seconds\fP \fIseconds\fP
75 Sets the wakeup time to \fIseconds\fP in future from now.
76 .TP
77 \fB-t\fP \fItime_t\fP | \fB--time\fP \fItime_t\fP
78 Sets the wakeup time to the absolute time \fItime_t\fP. \fItime_t\fP
79 is the time in seconds since 1970-01-01, 00:00 UTC. Use the
80 .BR date (1)
81 tool to convert between human-readable time and \fItime_t\fP.
82 .TP
83 \fB-m\fP \fImode\fP | \fB--mode\fP \fImode\fP
84 Use standby state \fImode\fP. Valid values are:
85 .RS
86 .TP
87 .B standby
88 ACPI state S1. This state offers minimal, though real, power savings, while
89 providing a very low-latency transition back to a working system. This is the
90 default mode.
91 .TP
92 .B mem
93 ACPI state S3 (Suspend-to-RAM). This state offers significant power savings as
94 everything in the system is put into a low-power state, except for memory,
95 which is placed in self-refresh mode to retain its contents.
96 .TP
97 .B disk
98 ACPI state S4 (Suspend-to-disk). This state offers the greatest power savings,
99 and can be used even in the absence of low-level platform support for power
100 management. This state operates similarly to Suspend-to-RAM, but includes a
101 final step of writing memory contents to disk.
102 .TP
103 .B no
104 Don't suspend. The rtcwake command sets RTC wakeup time only.
105 .TP
106 .B on
107 Don't suspend, but read RTC device until alarm time appears. This mode is
108 useful for debugging.
109 .RE
110 .PP
111 .SH NOTES
112 Some PC systems can't currently exit sleep states such as \fImem\fP
113 using only the kernel code accessed by this driver.
114 They need help from userspace code to make the framebuffer work again.
115 .SH HISTORY
116 The program was posted several times on LKML and other lists
117 before appearing in kernel commit message for Linux 2.6 in the GIT
118 commit 87ac84f42a7a580d0dd72ae31d6a5eb4bfe04c6d.
119 .SH AVAILABILITY
120 The rtcwake command is part of the util-linux-ng package and is available from
121 ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng/.
122 .SH AUTHOR
123 The program was written by David Brownell <dbrownell@users.sourceforge.net>
124 and improved by Bernhard Walle <bwalle@suse.de>.
125 .SH COPYRIGHT
126 This is free software.  You may redistribute copies of it  under  the  terms
127 of  the  GNU General  Public  License <http://www.gnu.org/licenses/gpl.html>.
128 There is NO WARRANTY, to the extent permitted by law.
129 .SH "SEE ALSO"
130 .BR hwclock (8),
131 .BR date (1)