How Windows Ranks Drivers (Windows Server 2003, Windows XP, and Windows 2000)

Windows assigns a rank to a driver that matches a device. The rank indicates how well the driver matches the device. A driver rank is represented by an integer that is equal to or greater than zero. The lower the rank, the better a match the driver is for the device. A rank of zero represents the best match.

The rank of a driver is a composite value that depends on whether a driver is signed and the type of match between a device identification string that is reported by a device and a matching device identification string in an INF Models section entry of a driver INF file.

The value of the Rank member of the SP_DRVINSTALL_PARAMS structure for a driver is the rank of the driver. A rank is a sum of a signature score and an identifier score. A rank is formatted as 0x0000THHH, where T and H are four-bitfields and the T and HHH fields represent the ranking scores, as follows:

  • The signature score ranks a driver according to how a driver is signed. The signature score depends only on the value of the two most-significant bits of the T field. An unspecified signature score is represented as 0x000T000

  • The identifier score ranks a driver based on the type of match between a device identification string that is reported by a device and a device identification string that is listed in an entry of an INF Models section of a driver INF file. The identifier score depends only on the value of two least-significant bits of the T field and the value of the HHH field. An unspecified identifier score is represented as 0x0000THHH.

For a list of valid driver rank ranges, see Driver Rank Ranges (Windows Server 2003, Windows XP, and Windows 2000). For an example of driver ranks, see Driver Rank Example (Windows Server 2003, Windows XP, and Windows 2000).

For information about system-defined constants that can be used to extract and compare rank values, see System-Defined Driver Rank Constants (Windows Server 2003, Windows XP, and Windows 2000).

 

 

Send comments about this topic to Microsoft