projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fsl_elbc_nand: ecclayout cleanups
[oweals/u-boot.git]
/
drivers
/
rtc
/
mk48t59.c
diff --git
a/drivers/rtc/mk48t59.c
b/drivers/rtc/mk48t59.c
index bacdb5b70bad7516d5cb41f5759b8bc6f317557b..dabf3222b8461114908a84a2a562e811ea2976de 100644
(file)
--- a/
drivers/rtc/mk48t59.c
+++ b/
drivers/rtc/mk48t59.c
@@
-33,8
+33,6
@@
#include <rtc.h>
#include <mk48t59.h>
#include <rtc.h>
#include <mk48t59.h>
-#if defined(CONFIG_RTC_MK48T59)
-
#if defined(CONFIG_BAB7xx)
static uchar rtc_read (short reg)
#if defined(CONFIG_BAB7xx)
static uchar rtc_read (short reg)
@@
-135,7
+133,7
@@
void nvram_write(short dest, const void *src, size_t count)
/* ------------------------------------------------------------------------- */
/* ------------------------------------------------------------------------- */
-
void
rtc_get (struct rtc_time *tmp)
+
int
rtc_get (struct rtc_time *tmp)
{
uchar save_ctrl_a;
uchar sec, min, hour, mday, wday, mon, year;
{
uchar save_ctrl_a;
uchar sec, min, hour, mday, wday, mon, year;
@@
-183,9
+181,11
@@
void rtc_get (struct rtc_time *tmp)
tmp->tm_year, tmp->tm_mon, tmp->tm_mday, tmp->tm_wday,
tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
#endif
tmp->tm_year, tmp->tm_mon, tmp->tm_mday, tmp->tm_wday,
tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
#endif
+
+ return 0;
}
}
-
void
rtc_set (struct rtc_time *tmp)
+
int
rtc_set (struct rtc_time *tmp)
{
uchar save_ctrl_a;
{
uchar save_ctrl_a;
@@
-210,6
+210,8
@@
void rtc_set (struct rtc_time *tmp)
save_ctrl_a &= ~RTC_CA_WRITE;
rtc_write(RTC_CONTROLA, save_ctrl_a); /* enables the RTC to update the regs */
save_ctrl_a &= ~RTC_CA_WRITE;
rtc_write(RTC_CONTROLA, save_ctrl_a); /* enables the RTC to update the regs */
+
+ return 0;
}
void rtc_reset (void)
}
void rtc_reset (void)
@@
-234,4
+236,3
@@
void rtc_set_watchdog(short multi, short res)
}
#endif
}
#endif
-#endif /* CONFIG_RTC_MK48T59 */