162306a36Sopenharmony_ciWhat: /dev/rtcX 262306a36Sopenharmony_ciDate: April 2005 362306a36Sopenharmony_ciKernelVersion: 2.6.12 462306a36Sopenharmony_ciContact: linux-rtc@vger.kernel.org 562306a36Sopenharmony_ciDescription: 662306a36Sopenharmony_ci The ioctl interface to drivers for real-time clocks (RTCs). 762306a36Sopenharmony_ci Following actions are supported: 862306a36Sopenharmony_ci 962306a36Sopenharmony_ci * RTC_RD_TIME, RTC_SET_TIME: Read or set the RTC time. Time 1062306a36Sopenharmony_ci format is a Gregorian calendar date and 24 hour wall clock 1162306a36Sopenharmony_ci time. 1262306a36Sopenharmony_ci 1362306a36Sopenharmony_ci * RTC_AIE_ON, RTC_AIE_OFF: Enable or disable the alarm interrupt 1462306a36Sopenharmony_ci for RTCs that support alarms 1562306a36Sopenharmony_ci 1662306a36Sopenharmony_ci * RTC_ALM_READ, RTC_ALM_SET: Read or set the alarm time for 1762306a36Sopenharmony_ci RTCs that support alarms. Can be set upto 24 hours in the 1862306a36Sopenharmony_ci future. Requires a separate RTC_AIE_ON call to enable the 1962306a36Sopenharmony_ci alarm interrupt. (Prefer to use RTC_WKALM_*) 2062306a36Sopenharmony_ci 2162306a36Sopenharmony_ci * RTC_WKALM_RD, RTC_WKALM_SET: For RTCs that support a more 2262306a36Sopenharmony_ci powerful interface, which can issue alarms beyond 24 hours and 2362306a36Sopenharmony_ci enable IRQs in the same request. 2462306a36Sopenharmony_ci 2562306a36Sopenharmony_ci * RTC_PIE_ON, RTC_PIE_OFF: Enable or disable the periodic 2662306a36Sopenharmony_ci interrupt for RTCs that support periodic interrupts. 2762306a36Sopenharmony_ci 2862306a36Sopenharmony_ci * RTC_UIE_ON, RTC_UIE_OFF: Enable or disable the update 2962306a36Sopenharmony_ci interrupt for RTCs that support it. 3062306a36Sopenharmony_ci 3162306a36Sopenharmony_ci * RTC_IRQP_READ, RTC_IRQP_SET: Read or set the frequency for 3262306a36Sopenharmony_ci periodic interrupts for RTCs that support periodic interrupts. 3362306a36Sopenharmony_ci Requires a separate RTC_PIE_ON call to enable the periodic 3462306a36Sopenharmony_ci interrupts. 3562306a36Sopenharmony_ci 3662306a36Sopenharmony_ci * RTC_VL_READ: Read the voltage inputs status of the RTC when 3762306a36Sopenharmony_ci supported. The value is a bit field of RTC_VL_*, giving the 3862306a36Sopenharmony_ci status of the main and backup voltages. 3962306a36Sopenharmony_ci 4062306a36Sopenharmony_ci * RTC_VL_CLEAR: Clear the voltage status of the RTC. Some RTCs 4162306a36Sopenharmony_ci need user interaction when the backup power provider is 4262306a36Sopenharmony_ci replaced or charged to be able to clear the status. 4362306a36Sopenharmony_ci 4462306a36Sopenharmony_ci The ioctl() calls supported by the older /dev/rtc interface are 4562306a36Sopenharmony_ci also supported by the newer RTC class framework. However, 4662306a36Sopenharmony_ci because the chips and systems are not standardized, some PC/AT 4762306a36Sopenharmony_ci functionality might not be provided. And in the same way, some 4862306a36Sopenharmony_ci newer features -- including those enabled by ACPI -- are exposed 4962306a36Sopenharmony_ci by the RTC class framework, but can't be supported by the older 5062306a36Sopenharmony_ci driver. 51