Dear Jean-Christophe PLAGNIOL-VILLARD, 2009/6/24 Jean-Christophe PLAGNIOL-VILLARD <plagn...@jcrosoft.com>: >> + >> +static volatile struct ftrtc010 *rtc = (struct ftrtc010 >> *)CONFIG_SYS_RTC_BASE; >> + >> +static void ftrtc_enable (void) > you use it at one please only the reset Sorry, I don't understand what do you mean
>> +{ >> + rtc->cr = cpu_to_le32 (FTRTC010_CR_ENABLE); > so please move this code there >> +} >> + >> +/* >> + * return current time in seconds >> + */ >> +static unsigned long ftrtc_time (void) >> +{ >> + unsigned long day; >> + unsigned long hour; >> + unsigned long minute; >> + unsigned long second; >> + unsigned long second2; >> + >> + do { >> + second = le32_to_cpu (rtc->sec); > please use proper accessor > readl/writel Should I use second = readl(&rtc->sec); or just second = rtc->sec; Best regards, Po-Yu Chuang _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot