Commit ea3d1606fd32059461309099e8856c6652888a79
Committed by
Linus Torvalds
1 parent
dac94d9ec9
Exists in
master
and in
7 other branches
rtc: document the sysfs interface
The sysfs interface to the RTC class drivers is currently undocumented. Add some basic documentation defining the semantics of the fields. Signed-off-by: Matthew Garrett <mjg@redhat.com> Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Alessandro Zummo <a.zummo@towertech.it> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 1 changed file with 22 additions and 0 deletions Side-by-side Diff
Documentation/rtc.txt
... | ... | @@ -135,6 +135,28 @@ |
135 | 135 | the system clock from the discrete RTC, but use the integrated one for all |
136 | 136 | other tasks, because of its greater functionality. |
137 | 137 | |
138 | +SYSFS INTERFACE | |
139 | +--------------- | |
140 | + | |
141 | +The sysfs interface under /sys/class/rtc/rtcN provides access to various | |
142 | +rtc attributes without requiring the use of ioctls. All dates and times | |
143 | +are in the RTC's timezone, rather than in system time. | |
144 | + | |
145 | +date: RTC-provided date | |
146 | +max_user_freq: The maximum interrupt rate an unprivileged user may request | |
147 | + from this RTC. | |
148 | +name: The name of the RTC corresponding to this sysfs directory | |
149 | +since_epoch: The number of seconds since the epoch according to the RTC | |
150 | +time: RTC-provided time | |
151 | +wakealarm: The time at which the clock will generate a system wakeup | |
152 | + event. This is a one shot wakeup event, so must be reset | |
153 | + after wake if a daily wakeup is required. Format is either | |
154 | + seconds since the epoch or, if there's a leading +, seconds | |
155 | + in the future. | |
156 | + | |
157 | +IOCTL INTERFACE | |
158 | +--------------- | |
159 | + | |
138 | 160 | The ioctl() calls supported by /dev/rtc are also supported by the RTC class |
139 | 161 | framework. However, because the chips and systems are not standardized, |
140 | 162 | some PC/AT functionality might not be provided. And in the same way, some |