]>
Commit | Line | Data |
---|---|---|
7eda085c | 1 | #include <stdio.h> |
66ee8158 | 2 | #include <stdlib.h> |
7eda085c KZ |
3 | #include <string.h> |
4 | #include <errno.h> /* for errno, EPERM, EINVAL, ENOENT */ | |
5 | #include <time.h> | |
6 | ||
7 | struct clock_ops { | |
8 | char *interface_name; | |
9 | int (*get_permissions)(void); | |
10 | int (*read_hardware_clock)(struct tm *tm); | |
11 | int (*set_hardware_clock)(const struct tm *tm); | |
12 | int (*synchronize_to_clock_tick)(void); | |
13 | }; | |
14 | ||
15 | extern struct clock_ops *probe_for_cmos_clock(void); | |
16 | extern struct clock_ops *probe_for_rtc_clock(void); | |
17 | extern struct clock_ops *probe_for_kd_clock(void); | |
18 | ||
19 | typedef int bool; | |
20 | #define TRUE 1 | |
21 | #define FALSE 0 | |
22 | ||
23 | /* hwclock.c */ | |
24 | extern char *progname; | |
25 | extern int debug; | |
22853e4a | 26 | extern int epoch_option; |
66ee8158 | 27 | extern void outsyserr(char *msg, ...); |
7eda085c KZ |
28 | |
29 | /* cmos.c */ | |
30 | extern void set_cmos_epoch(int ARCconsole, int SRM); | |
31 | extern void set_cmos_access(int Jensen, int funky_toy); | |
32 | ||
33 | /* rtc.c */ | |
34 | extern int get_epoch_rtc(unsigned long *epoch, int silent); | |
35 | extern int set_epoch_rtc(unsigned long epoch); |