diff options
author | Matt Mackall <mpm@selenic.com> | 2006-03-28 04:56:09 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-28 12:16:01 -0500 |
commit | 41623b064fbd76de5901da7c0e3cd2136617d787 (patch) | |
tree | f96bb5c45d7fa4a899af2be27a3bbdca079b023a /arch/ppc | |
parent | 4c2e6f6a06cdd239ec17e195e7868ce0171ea154 (diff) |
[PATCH] RTC: Fix up some RTC whitespace and style
Fix up some RTC whitespace and style
Signed-off-by: Matt Mackall <mpm@selenic.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/ppc')
-rw-r--r-- | arch/ppc/platforms/chrp_time.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/arch/ppc/platforms/chrp_time.c b/arch/ppc/platforms/chrp_time.c index e103a36e11a5..51e06ad66168 100644 --- a/arch/ppc/platforms/chrp_time.c +++ b/arch/ppc/platforms/chrp_time.c | |||
@@ -129,16 +129,18 @@ unsigned long chrp_get_rtc_time(void) | |||
129 | year = chrp_cmos_clock_read(RTC_YEAR); | 129 | year = chrp_cmos_clock_read(RTC_YEAR); |
130 | } while (sec != chrp_cmos_clock_read(RTC_SECONDS)); | 130 | } while (sec != chrp_cmos_clock_read(RTC_SECONDS)); |
131 | 131 | ||
132 | if (!(chrp_cmos_clock_read(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 132 | if (!(chrp_cmos_clock_read(RTC_CONTROL) & RTC_DM_BINARY) |
133 | { | 133 | || RTC_ALWAYS_BCD) { |
134 | BCD_TO_BIN(sec); | 134 | BCD_TO_BIN(sec); |
135 | BCD_TO_BIN(min); | 135 | BCD_TO_BIN(min); |
136 | BCD_TO_BIN(hour); | 136 | BCD_TO_BIN(hour); |
137 | BCD_TO_BIN(day); | 137 | BCD_TO_BIN(day); |
138 | BCD_TO_BIN(mon); | 138 | BCD_TO_BIN(mon); |
139 | BCD_TO_BIN(year); | 139 | BCD_TO_BIN(year); |
140 | } | 140 | } |
141 | if ((year += 1900) < 1970) | 141 | |
142 | year += 1900; | ||
143 | if (year < 1970) | ||
142 | year += 100; | 144 | year += 100; |
143 | return mktime(year, mon, day, hour, min, sec); | 145 | return mktime(year, mon, day, hour, min, sec); |
144 | } | 146 | } |