20,11 → 20,11 |
|
/** |
------------ |
CVS : $Id: rtc.c,v 1.1.1.1 2002-03-29 14:12:49 pj Exp $ |
CVS : $Id: rtc.c,v 1.2 2002-11-11 08:41:31 pj Exp $ |
|
File: $File$ |
Revision: $Revision: 1.1.1.1 $ |
Last update: $Date: 2002-03-29 14:12:49 $ |
Revision: $Revision: 1.2 $ |
Last update: $Date: 2002-11-11 08:41:31 $ |
------------ |
|
Author: Massimiliano Giorgi |
183,7 → 183,7 |
SYS_FLAGS flags; |
unsigned char ctrl; |
unsigned retries=0; |
unsigned delay; |
struct timespec delay; |
|
/* |
* read RTC once any update in progress is done. The update |
201,8 → 201,9 |
barrier(); |
*/ |
|
delay=1000; |
while (rtc_is_updating()&&++retries<=5) task_delay(delay); |
delay.tv_nsec = 1000000; |
delay.tv_sec = 0; |
while (rtc_is_updating()&&++retries<=5) nanosleep(&delay, NULL); |
if (retries>5) return -1; |
|
/* |