Merge with git://www.denx.de/git/u-boot.git
[platform/kernel/u-boot.git] / rtc / rs5c372.c
index 87f38c4..3d1346e 100644 (file)
@@ -34,7 +34,7 @@
 #include <rtc.h>
 #include <i2c.h>
 
-#if defined(CONFIG_RTC_RS5C372A) && (CONFIG_COMMANDS & CFG_CMD_DATE)
+#if defined(CONFIG_RTC_RS5C372A) && defined(CONFIG_CMD_DATE)
 /*
  * Reads are always done starting with register 15, which requires some
  * jumping-through-hoops to access the data correctly.
@@ -73,7 +73,7 @@ static unsigned bcd2bin (uchar c);
 static int setup_done = 0;
 
 static int
-rs5c372_readram(char *buf, int len)
+rs5c372_readram(unsigned char *buf, int len)
 {
        int ret;
 
@@ -128,7 +128,7 @@ rs5c372_enable(void)
 }
 
 static void
-rs5c372_convert_to_time(struct rtc_time *dt, char *buf)
+rs5c372_convert_to_time(struct rtc_time *dt, unsigned char *buf)
 {
        /* buf[0] is register 15 */
        dt->tm_sec = bcd2bin(buf[1]);
@@ -299,4 +299,4 @@ bin2bcd (unsigned int n)
 {
        return (((n / 10) << 4) | (n % 10));
 }
-#endif /* defined(CONFIG_RTC_RS5C372A) && (CONFIG_COMMANDS & CFG_CMD_DATE) */
+#endif