KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff

I strongly recommend you uild the driver using the Server 2003 SP1 DDK
and KMDF 1.1.

The error code indicates a version mismatch, indicating you most likely
built the driver for KMDF 1.5 (using the WDK) and are trying to install
it on KMDF 1.1.

If you must install as 1.5, then use the RC1 WDK- the earlier versions
have defects regarding 1.5 of one sort or another. if (NULL ==
pDataBuffer && Srb.DataTransferLength > 0 && Srb.DataTransferLength <=
PAGE_SIZE &&
NULL != Srb.OriginalRequest && NULL !=
Srb.SrbExtension)

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Did you create a pnp driver? if so, you can’t use sc or the service
apis to start the device, you must use setup api. What OS is this on?

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Yes it is a pnp driver. Ok I’ll look into using the setup api.
This is on Win2K3.

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Friday, September 08, 2006 12:49 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Did you create a pnp driver? if so, you can’t use sc or the service
apis to start the device, you must use setup api. What OS is this on?

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Hmmm… Well I am going to need ifs stuff, so it looks like I’ll have
to get the new RC1 WDK.
Am I correct in assuming that the RC1 WDK has everything I need to
create a KMDF driver?

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Bob Kjelgaard
Sent: Friday, September 08, 2006 12:53 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

I strongly recommend you uild the driver using the Server 2003 SP1 DDK
and KMDF 1.1.

The error code indicates a version mismatch, indicating you most likely
built the driver for KMDF 1.5 (using the WDK) and are trying to install
it on KMDF 1.1.

If you must install as 1.5, then use the RC1 WDK- the earlier versions
have defects regarding 1.5 of one sort or another. if (NULL ==
pDataBuffer && Srb.DataTransferLength > 0 && Srb.DataTransferLength <=
PAGE_SIZE &&
NULL != Srb.OriginalRequest && NULL !=
Srb.SrbExtension)

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Yes. As I understand it (I’m sure a correction will be forthcoming if
I’m wrong), you can use a driver built with the RC1 WDK to get a Vista
logo. Details ought to be in the kit itself.

The only caveat I have relates to Vista. It has been 1.5 internally
since Beta2, but these are not all consistent.

A Driver from the RC1 WDK won’t work on Beta2 (but 1.1 and 1.0 drivers
will). It will work on later builds, but I don’t know what builds are
out there, or exactly where the cutoff is. It will work on RC1 (and any
of its recent preview variants) and it will work on RTM, or much pain
will be felt in my neighborhood.

Man, how did I manage to paste code into my mail and not see it…

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 10:27 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Hmmm… Well I am going to need ifs stuff, so it looks like I’ll have
to get the new RC1 WDK.
Am I correct in assuming that the RC1 WDK has everything I need to
create a KMDF driver?

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Bob Kjelgaard
Sent: Friday, September 08, 2006 12:53 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

I strongly recommend you uild the driver using the Server 2003 SP1 DDK
and KMDF 1.1.

The error code indicates a version mismatch, indicating you most likely
built the driver for KMDF 1.5 (using the WDK) and are trying to install
it on KMDF 1.1.

If you must install as 1.5, then use the RC1 WDK- the earlier versions
have defects regarding 1.5 of one sort or another. if (NULL ==
pDataBuffer && Srb.DataTransferLength > 0 && Srb.DataTransferLength <=
PAGE_SIZE &&
NULL != Srb.OriginalRequest && NULL !=
Srb.SrbExtension)

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Well, I swapped over to version 1.5, using the wdk 5483 (I’ll be installing
RC1 as soon as it finishes downloading.)
I am now using the SetupDi interface to start the driver, or at least I’m
trying to. The SetupDiEnumDeviceInterfaces call is failing with 0x103 - “No
more data is available”.

So I figured I did something wrong. So I built and installed the kmdf\echo
sample. Tried it out, and got exactly
the same problem.

Any ideas?

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Friday, September 08, 2006 12:49 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Did you create a pnp driver? if so, you can’t use sc or the service
apis to start the device, you must use setup api. What OS is this on?

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

If it is a pnp driver, use devcon. SetupDiEnumDeviceInterfaces will
tell you about already installed instances of the interface.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 1:10 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Well, I swapped over to version 1.5, using the wdk 5483 (I’ll be
installing
RC1 as soon as it finishes downloading.)
I am now using the SetupDi interface to start the driver, or at least
I’m
trying to. The SetupDiEnumDeviceInterfaces call is failing with 0x103 -
“No
more data is available”.

So I figured I did something wrong. So I built and installed the
kmdf\echo
sample. Tried it out, and got exactly
the same problem.

Any ideas?

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Friday, September 08, 2006 12:49 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Did you create a pnp driver? if so, you can’t use sc or the service
apis to start the device, you must use setup api. What OS is this on?

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Figured this out, seems I was using an old or “bad” devcon. I used the
one in the WDK RC1 and everything is working fine. I got the other
devcon off microsoft.com, which is probably a bad thing.

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Friday, September 08, 2006 4:32 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

If it is a pnp driver, use devcon. SetupDiEnumDeviceInterfaces will
tell you about already installed instances of the interface.

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 1:10 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Well, I swapped over to version 1.5, using the wdk 5483 (I’ll be
installing
RC1 as soon as it finishes downloading.)
I am now using the SetupDi interface to start the driver, or at least
I’m
trying to. The SetupDiEnumDeviceInterfaces call is failing with 0x103 -
“No
more data is available”.

So I figured I did something wrong. So I built and installed the
kmdf\echo
sample. Tried it out, and got exactly
the same problem.

Any ideas?

Thanks!
-Jeff

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Doron Holan
Sent: Friday, September 08, 2006 12:49 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] KMDF driver load failed

Did you create a pnp driver? if so, you can’t use sc or the service
apis to start the device, you must use setup api. What OS is this on?

d

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@emc.com
Sent: Friday, September 08, 2006 8:39 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] KMDF driver load failed

Hi,
I’ve written a small test driver to poke around at kmdf, so far
it looks
pretty neat. I created an INF and installed my driver, no problems so
far.
The issue is when I try to start the driver, sc returns error code 0x6 -
invalid handle.
Looking deeper, I turned on the DbgPrintOn flag and looked at what that
output said:

WdfLdr: DllInitialize: enter
WdfLdr: DllInitialize: OsVersion(5.2)
WdfLdr: DllInitialize: exit
WdfLdr: WdfVersionBind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: value 0x00000001
WdfLdr: WdfLdrDiagnosticsValueByNameAsULONG: status 0x0
WdfLdr: Version Image Name “Wdf01000.sys”
WdfLdr: module(822A5350)
WdfLdr: WdfVersionUnbind: enter
WdfLdr: Component path
\Registry\Machine\System\CurrentControlSet\Control\Wdf\Kmdf\KmdfLibrary\
Versions
WdfLdr:
GetVersionServicePath(\Registry\Machine\System\CurrentControlSet\Service
s\Wdf01000)
WdfLdr: DereferenceVersion: Dereference module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: DereferenceVersion: Unload module
\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\Wdf01000
WdfLdr: WdfVersionUnbind: exit: 0
WdfLdr: WdfVersionBind: exit C0000024
WdfLdr: DllUnload: enter
WdfLdr: DllUnload: exit

It looks to me like the WdfLdr is looking to see if the version of kmdf
on the machine
is compatible with the version my driver wants. I am using kmdf 1.1,
and wdk 5483.
any ideas? I’m stumped since the debug output really doesn’t say much
about why my
driver isn’t being loaded.

Thanks!
-Jeff


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer