PERFORCE change 95715 for review
Warner Losh
imp at FreeBSD.org
Thu Apr 20 21:03:52 UTC 2006
http://perforce.freebsd.org/chv.cgi?CH=95715
Change 95715 by imp at imp_hammer on 2006/04/20 21:03:37
Make getc(0) effect a poll. This also happens to save 4 bytes.
Affected files ...
.. //depot/projects/arm/src/sys/boot/arm/at91/libat91/getc.c#3 edit
Differences ...
==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/getc.c#3 (text) ====
@@ -53,10 +53,10 @@
thisSecond = GetSeconds();
seconds = thisSecond + seconds;
- while (thisSecond <= seconds) {
+ do {
if ((pUSART->US_CSR & AT91C_US_RXRDY))
return (pUSART->US_RHR & 0xFF);
thisSecond = GetSeconds();
- }
+ } while (thisSecond < seconds);
return (-1);
}
More information about the p4-projects
mailing list