kernels/linux-2.4.0/arch/mips/cobalt/cobaltscc.c
/*
 * Function: SccInbTimeout
 *
 * Description: Read a byte from the SCC (Channel A) with timeout
 * In: Byte to send
 * Out: Timeout status
 */
SccInbTimeout
Description: Read a byte from the SCC (Channel A) with timeout
In: Byte to send
Out: Timeout status
SccInbTimeout Description : Read a byte from the SCC ( Channel A ) with timeout In : Byte to send Out : Timeout status
unsigned char SccInbTimeout(unsigned char *byte, unsigned long timeout)
{
	unsigned long ctr = 0;
	while ((Read8530(kSCC_ChanA) & Rx_CH_AV) == 0) {
		RegisterDelay();
		if ((ctr++) > timeout)
			return 0xFF;
	}
	*byte = Read8530(kSCC_ChanA | kSCC_Direct);
	RegisterDelay();
	return 0;
}
unsigned char SccInbTimeout ( unsigned char * byte , unsigned long timeout ) { unsigned long ctr = 0 ; while ( ( Read8530 ( kSCC_ChanA ) & Rx_CH_AV ) == 0 ) { RegisterDelay ( ) ; if ( ( ctr ++ ) > timeout ) return 0xFF ; } * byte = Read8530 ( kSCC_ChanA | kSCC_Direct ) ; RegisterDelay ( ) ; return 0 ; }
Function: SccInbTimeout
 Description: Read a byte from the SCC (Channel A) with timeout
 In: Byte to send
 Out: Timeout status
Function : SccInbTimeout Description : Read a byte from the SCC ( Channel A ) with timeout In : Byte to send Out : Timeout status