I’m learning KMDF and try to “port” Bo Brant?n’s FileDisk code to KMDF. My code works, kind of, for FAT image files but crashes once in a while somewhere in the EvtRead/Write callback. My question is, what is the proper way to do PsCreateSystemThread in KMDF? Can I use a Work Item and pass the Request object handle in the context structure? Thanks.
First, I think the history behind Bo’s driver is muddled. IIRC he lifted the code from someone else and that is looked at favorably by the folks on this list. Second, run !analyze -v when it crashes. That should help you narrow it down. The proper way to create a thread in KMDF is to call PsCreateSystemThread, KMDF does not abstract driver created threads. Yes, you can pass the Request object to the thread and process it there or create a WDFWORKITEM and process the request in the work item callback.
d
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@yahoo.com
Sent: Thursday, November 13, 2008 10:03 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Worker thread in KMDF
I’m learning KMDF and try to “port” Bo Brant?n’s FileDisk code to KMDF. My code works, kind of, for FAT image files but crashes once in a while somewhere in the EvtRead/Write callback. My question is, what is the proper way to do PsCreateSystemThread in KMDF? Can I use a Work Item and pass the Request object handle in the context structure? Thanks.
NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer
Doron Holan wrote:
First, I think the history behind Bo’s driver is muddled. IIRC he lifted the code from someone else and that is looked at favorably by the folks on this list.
…that is looked at UNFAVORABLY by the folks on this list.
–
Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.
Yes very unfavorably since the code is owned by someone else, so use of it
is pure theft. Dump the code if you expect the community to aid your
efforts.
–
Don Burn (MVP, Windows DDK)
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply
“Tim Roberts” wrote in message news:xxxxx@ntdev…
> Doron Holan wrote:
>> First, I think the history behind Bo’s driver is muddled. IIRC he lifted
>> the code from someone else and that is looked at favorably by the folks
>> on this list.
>
> …that is looked at UNFAVORABLY by the folks on this list.
>
> –
> Tim Roberts, xxxxx@probo.com
> Providenza & Boekelheide, Inc.
>
>
Tim, thanks for the correction ![]()
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Don Burn
Sent: Thursday, November 13, 2008 10:18 AM
To: Windows System Software Devs Interest List
Subject: Re:[ntdev] Worker thread in KMDF
Yes very unfavorably since the code is owned by someone else, so use of it
is pure theft. Dump the code if you expect the community to aid your
efforts.
–
Don Burn (MVP, Windows DDK)
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply
“Tim Roberts” wrote in message news:xxxxx@ntdev…
> Doron Holan wrote:
>> First, I think the history behind Bo’s driver is muddled. IIRC he lifted
>> the code from someone else and that is looked at favorably by the folks
>> on this list.
>
> …that is looked at UNFAVORABLY by the folks on this list.
>
> –
> Tim Roberts, xxxxx@probo.com
> Providenza & Boekelheide, Inc.
>
>
—
NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer
Sorry, I didn’t know anything about this “lifting” story behind the code. I’ll just find some other code to play with.