#include <byteswap.h>Go to the source code of this file.
Defines | |
| #define | ISA_VENDOR(a, b, c) |
| #define | ISAPNP_VENDOR(a, b, c) ISA_VENDOR ( a, b, c ) |
| #define | EISA_VENDOR(a, b, c) ISA_VENDOR ( a, b, c ) |
| #define | GENERIC_ISAPNP_VENDOR ISAPNP_VENDOR ( 'P','N','P' ) |
| #define | ISA_PROD_ID_MASK ( 0xf0ff ) |
| #define | ISA_PROD_ID(product) ( (product) & ISA_PROD_ID_MASK ) |
| #define | ISA_PROD_REV(product) ( ( (product) & ~ISA_PROD_ID_MASK ) >> 8 ) |
Functions | |
| FILE_LICENCE (GPL2_OR_LATER) | |
| char * | isa_id_string (unsigned int vendor, unsigned int product) |
| #define ISA_VENDOR | ( | a, | |||
| b, | |||||
| c | ) |
| #define GENERIC_ISAPNP_VENDOR ISAPNP_VENDOR ( 'P','N','P' ) |
| #define ISA_PROD_ID_MASK ( 0xf0ff ) |
| #define ISA_PROD_ID | ( | product | ) | ( (product) & ISA_PROD_ID_MASK ) |
Definition at line 45 of file isa_ids.h.
Referenced by eisa_probe(), el3_eisa_probe(), isapnp_probe(), and legacy_t509_probe().
| #define ISA_PROD_REV | ( | product | ) | ( ( (product) & ~ISA_PROD_ID_MASK ) >> 8 ) |
| FILE_LICENCE | ( | GPL2_OR_LATER | ) |
| char* isa_id_string | ( | unsigned int | vendor, | |
| unsigned int | product | |||
| ) |
Definition at line 11 of file isa_ids.c.
References bswap_16, and sprintf.
Referenced by eisa_probe(), and isapnp_probe().
00011 { 00012 static char buf[7]; 00013 int i; 00014 00015 /* Vendor ID is a compressed ASCII string */ 00016 vendor = bswap_16 ( vendor ); 00017 for ( i = 2 ; i >= 0 ; i-- ) { 00018 buf[i] = ( 'A' - 1 + ( vendor & 0x1f ) ); 00019 vendor >>= 5; 00020 } 00021 00022 /* Product ID is a 4-digit hex string */ 00023 sprintf ( &buf[3], "%04x", bswap_16 ( product ) ); 00024 00025 return buf; 00026 }
1.5.7.1