Device installations should not force the user to reboot the system unless absolutely necessary. The following circumstances are the only ones for which a system reboot should be necessary:
For these legacy devices, a user typically must shut down the system before physically adding or removing the device. After the power is turned back on, the system reboots. Note that the device's setup files should not initiate a reboot, regardless of whether the user installs the drivers before or after plugging in the hardware.
If a device can potentially hold the system's paging, hibernation, or crash dump file, its drivers must service IRP_MN_DEVICE_USAGE_NOTIFICATION requests. The system sends this request before placing one of these files on the disk. If the drivers succeed the request, they must fail any subsequent IRP_MN_QUERY_REMOVE_DEVICE requests. When a driver for the device fails an IRP_MN_QUERY_REMOVE_DEVICE request, the system prompts the user to reboot. Note that the device's setup files should not initiate a reboot.
If a filter driver is added to a non-WDM driver stack, the system must be rebooted. In this case, the driver's installer or co-installer should request a reboot (see Initiating System Reboots During Device Installations). Note that adding a filter driver to a WDM driver stack does not require a reboot, unless an underlying device is a system boot device.
To avoid system reboots during device installations, use the following rules:
In the rare cases in which it is necessary for the system to be rebooted to complete a device installation, use the following rules: