Hello all,
I am trying to install my driver using DriverPackageInstall() but it just preinstalls (and doesn’t install )but the return value is ERROR_SUCCESS only ! I am new to this , is this happening because my driver is not signed ?
-> i have attached my code here :
//start of code
ret= DriverPackageInstall(
L"c:\msvad\msvad.inf",
DRIVER_PACKAGE_LEGACY_MODE | DRIVER_PACKAGE_REPAIR | DRIVER_PACKAGE_FORCE | DRIVER_PACKAGE_SILENT,
NULL,
&check
);
if( ERROR_SUCCESS != ret ){
printf(“Error returned is %d\n”,GetLastError());
return ERR;
}else{
printf(“Succesful preinstall and install\n”);
}
//End of code
What could be the issue ? does DriverPackageInstall() install the device specified or not ?
TIA,
Venkatesh.D.N
hi which OS r u testing? even if the drivers r not signed if u specify "DRIVER_PACKAGE_LEGACY_MODE " flag it shd work. But from the documentation I can c that “Starting with Windows Vista, the DRIVER_PACKAGE_LEGACY_MODE flag is obsolete.” does this mean DriverPackageInstall will work only with signed drivers from Vista & above? Hope somebody who has tested this API can provide more input…
xxxxx@gmail.com wrote:
Hello all,
I am trying to install my driver using DriverPackageInstall() but it just preinstalls (and doesn’t install )but the return value is ERROR_SUCCESS only ! I am new to this , is this happening because my driver is not signed ?
No, it’s working exactly as designed. DriverPackageInstall pre-installs
the driver package. What you are looking for is a way to create a
device that the driver can drive. You can do this using “devcon
install”, or you can look in the devcon source to see how it does it
(SetupDiCreateDeviceInfo, SetupDiSetDeviceRegistryPropery,
SetupDiCallClassInstaller, UpdateDriverForPlugAndPlayDevices).
–
Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.