kernels/linux-2.4.0/arch/ia64/sn/io/eeprom.c
/* create a part number of the form xxx-xxxx-xxx.
 * It may be important later to generate different
 * part numbers depending on the component we're
 * supposed to be "reading" from, so the component
 * paramter is provided.
 */
create a part number of the form xxx-xxxx-xxx.
It may be important later to generate different
part numbers depending on the component we're
supposed to be "reading" from, so the component
paramter is provided.
create a part number of the form xxx - xxxx - xxx . It may be important later to generate different part numbers depending on the component we ' re supposed to be " reading " from so the component paramter is provided .
void fake_a_part_number( char *buf, int component )
{
    int i;
    switch( component ) {
    case C_BRICK:
	strcpy( buf, "030-1266-001" );
	break;
    default:
        for( i = 0; i < 12; i++ ) {
	    if( i == 3 || i == 8 )
	        buf[i] = '-';
	    else
	        buf[i] = random_eeprom_ch(0);
        }
    }
}
void fake_a_part_number ( char * buf , int component ) { int i ; switch ( component ) { case C_BRICK : strcpy ( buf , " " ) ; break ; default : for ( i = 0 ; i < 12 ; i ++ ) { if ( i == 3 || i == 8 ) buf [ i ] = ' ' ; else buf [ i ] = random_eeprom_ch ( 0 ) ; } } }
create a part number of the form xxx-xxxx-xxx.
create a part number of the form xxx - xxxx - xxx .
/* insert component-specific routines here */