Re: How can I toggle CONFIG_REINSTALL on an orphaned Devnode
From: Dave Burns (dburns0000_at_aol.com)
Date: 01/28/05
- Next message: Del Fredricks: "Which Callback function is used when remote node is closing a socket."
- Previous message: bb: "Re: Failure to install Miniport driver"
- In reply to: Pavel A.: "RE: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Next in thread: Pavel A.: "Re: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Reply: Pavel A.: "Re: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 28 Jan 2005 08:24:38 -0600
The problem occurs on a XP system. I have not tested on Win 2K yet but I
need a solution that works on both XP and Win 2K.
"Pavel A." <pavel_a@NOwritemeNO.com> wrote in message
news:8E5C7FB6-0A83-49E7-ADFF-3428A31BDE21@microsoft.com...
> Is the machine XP or win2k?
> I remember this was a problem in win2k, but has been fixed in XP.
> (haven't seen it since long ago so may be wrong here)
> --PA
>
> "Dave Burns" wrote:
>> We have a USB Printer device and we use a setup application that follows
>> the
>> guidelines in the MSDN article "Writing a Device Installation
>> Application"
>> to install the device driver. The files are copied to a hard drive
>> location
>> and UpdateDriverForPlugAndPlayDevices is called. If necessary (as in a
>> first time install) then SetupCopyOEMIndf is called. If disconnected but
>> installed (phantom) devices are detected we do the procedure to toggle
>> the
>> devices CONFIG_REINSTALL flag. However when a user has connected the
>> device
>> prior to running the Setup application, and has to exit the Hardware
>> Installer because the INF file is not available, then at a later time
>> when
>> the Setup application is executed we observe a scenario where
>> SetupDiGetClassDevs fails to return a device information set. The reason
>> is
>> that when the device was connected (without previously running the setup
>> application) and the Hardware Manager makes a device instance under the
>> Enum\USBPRINT tree of the registry, but a corresponding entry is not
>> created under the Control\Class\<ClassGUID> tree because the related INF
>> file was not located. Experimentally I know that if the ConfigFlags
>> registry value of the device node under the Enum\USBPRINT tree is set to
>> 0x20 (CONFIG_REINSTALL) after the setup application has been run, then
>> the
>> hardware manager finds the INF and the driver is installed. But until
>> that
>> value is toggled there seems to be no way to get the device driver to
>> install. The question is, how do we toggle this value when the
>> SetupDiGetClassDevs dose not return a device information set for this
>> device? A setup application running under a typical administrator does
>> not
>> have the rights to change this registry key directly. It seems that both
>> the CM_ API and the SetupDi API requires a device information set to
>> access
>> this registry key, but I don't understand how to get one when the
>> registry
>> keys were never created under the Class tree. Any suggestions would be
>> appreciated? Thanks.
>>
>>
>>
- Next message: Del Fredricks: "Which Callback function is used when remote node is closing a socket."
- Previous message: bb: "Re: Failure to install Miniport driver"
- In reply to: Pavel A.: "RE: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Next in thread: Pavel A.: "Re: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Reply: Pavel A.: "Re: How can I toggle CONFIG_REINSTALL on an orphaned Devnode"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|