Lines Matching refs:buf
206 char buf[128]; in populate_vendor() local
225 while( pci_id_file_gets( buf, sizeof( buf ), f ) != NULL ) { in populate_vendor()
235 if ( buf[ num_tabs ] != '\t' ) { in populate_vendor()
240 if ( !isxdigit( buf[ num_tabs + 0 ] ) in populate_vendor()
241 || !isxdigit( buf[ num_tabs + 1 ] ) in populate_vendor()
242 || !isxdigit( buf[ num_tabs + 2 ] ) in populate_vendor()
243 || !isxdigit( buf[ num_tabs + 3 ] ) ) { in populate_vendor()
247 new_line = strchr( buf, '\n' ); in populate_vendor()
252 length = strlen( buf ); in populate_vendor()
253 (void) memset( buf + length, 0, sizeof( buf ) - length ); in populate_vendor()
257 vendor = (unsigned) strtoul( & buf[ num_tabs ], NULL, 16 ); in populate_vendor()
263 vend->vendor_name = strdup( & buf[ num_tabs + 6 ] ); in populate_vendor()
295 dev->id.device_id = (unsigned) strtoul( & buf[ num_tabs ], in populate_vendor()
304 dev->device_name = strdup( & buf[ num_tabs + 6 ] ); in populate_vendor()
309 dev->id.subvendor_id= (unsigned) strtoul( & buf[ num_tabs ], in populate_vendor()
311 dev->id.subdevice_id = (unsigned) strtoul( & buf[ num_tabs + 5 ], in populate_vendor()
313 dev->device_name = strdup( & buf[ num_tabs + 5 + 6 ] ); in populate_vendor()