diff options
Diffstat (limited to 'arch/mips/lasat/sysctl.c')
-rw-r--r-- | arch/mips/lasat/sysctl.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/arch/mips/lasat/sysctl.c b/arch/mips/lasat/sysctl.c index 4575a829766d..389336c4ecc5 100644 --- a/arch/mips/lasat/sysctl.c +++ b/arch/mips/lasat/sysctl.c | |||
@@ -32,6 +32,8 @@ | |||
32 | #include <linux/mutex.h> | 32 | #include <linux/mutex.h> |
33 | #include <linux/uaccess.h> | 33 | #include <linux/uaccess.h> |
34 | 34 | ||
35 | #include <asm/time.h> | ||
36 | |||
35 | #include "sysctl.h" | 37 | #include "sysctl.h" |
36 | #include "ds1603.h" | 38 | #include "ds1603.h" |
37 | 39 | ||
@@ -106,7 +108,7 @@ int proc_dolasatrtc(ctl_table *table, int write, struct file *filp, | |||
106 | 108 | ||
107 | mutex_lock(&lasat_info_mutex); | 109 | mutex_lock(&lasat_info_mutex); |
108 | if (!write) { | 110 | if (!write) { |
109 | rtctmp = ds1603_read(); | 111 | rtctmp = read_persistent_clock(); |
110 | /* check for time < 0 and set to 0 */ | 112 | /* check for time < 0 and set to 0 */ |
111 | if (rtctmp < 0) | 113 | if (rtctmp < 0) |
112 | rtctmp = 0; | 114 | rtctmp = 0; |
@@ -116,7 +118,7 @@ int proc_dolasatrtc(ctl_table *table, int write, struct file *filp, | |||
116 | mutex_unlock(&lasat_info_mutex); | 118 | mutex_unlock(&lasat_info_mutex); |
117 | return r; | 119 | return r; |
118 | } | 120 | } |
119 | ds1603_set(rtctmp); | 121 | rtc_mips_set_mmss(rtctmp); |
120 | mutex_unlock(&lasat_info_mutex); | 122 | mutex_unlock(&lasat_info_mutex); |
121 | 123 | ||
122 | return 0; | 124 | return 0; |
@@ -152,7 +154,7 @@ int sysctl_lasat_rtc(ctl_table *table, int *name, int nlen, | |||
152 | int r; | 154 | int r; |
153 | 155 | ||
154 | mutex_lock(&lasat_info_mutex); | 156 | mutex_lock(&lasat_info_mutex); |
155 | rtctmp = ds1603_read(); | 157 | rtctmp = read_persistent_clock(); |
156 | if (rtctmp < 0) | 158 | if (rtctmp < 0) |
157 | rtctmp = 0; | 159 | rtctmp = 0; |
158 | r = sysctl_intvec(table, name, nlen, oldval, oldlenp, newval, newlen); | 160 | r = sysctl_intvec(table, name, nlen, oldval, oldlenp, newval, newlen); |
@@ -161,7 +163,7 @@ int sysctl_lasat_rtc(ctl_table *table, int *name, int nlen, | |||
161 | return r; | 163 | return r; |
162 | } | 164 | } |
163 | if (newval && newlen) | 165 | if (newval && newlen) |
164 | ds1603_set(rtctmp); | 166 | rtc_mips_set_mmss(rtctmp); |
165 | mutex_unlock(&lasat_info_mutex); | 167 | mutex_unlock(&lasat_info_mutex); |
166 | 168 | ||
167 | return 1; | 169 | return 1; |