If he disables the device in device manager, there is no need for hooking or touching the IDT b/c there is no interrupt connected and no driver to hook. If you really want to go down this path, you could either
a) continue to do what you are doing and try to steal the resources. Install a ānullā driver which all it does is keep the port powered on. You can write such a driver in KMDF very very quickly. Even better, have this driver export the resources to yoru driver via an IOCTL and pound away on the resources directly.
b) have your driver be the FDO for the serial port FDO. you assume control of the hw resources directly and there is no middle man.
I have seen so many āit is only experimental codeā drivers that turned into production drivers w/out modification that I think you should do it right from the beginning and go with b.
d
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@hotmail.com
Sent: Sunday, January 27, 2008 11:52 PM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] use serial port at I/O level
I think that, as long as this is a research/study project, you can do some advanced hooking. You have to hook the target interrupt in IDT plus all dispatch routines in your target driver. In other words, you have to put the existing driver completely out of play - you are going to be the only one who is in charge of all its resources, and the rest of the system should be made believe that it is the target driver who handles everything.
However, what I must warn you from the very beginning is that it is not about ā20 lines of codeā as you may think - it is going to be a pretty large project, so that get ready to deal with interrupts, PnP and all other things that you hope to avoid. After all, NT is not like MS-DOSā¦
Anton Bassov
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