Driver denied access to PCI card
Posted
by Corin
on Stack Overflow
See other posts from Stack Overflow
or by Corin
Published on 2010-05-04T21:29:54Z
Indexed on
2010/05/04
21:38 UTC
Read the original article
Hit count: 233
c++
|device-driver
We wrote a Windows device driver to access our custom PCI card. The driver uses CreateFile to get a handle to the card.
We recently had trouble at one installation were the card appeared to stop working. We tried replacing the card (the replacement appeared not work either). The computer vendor replaced the motherboard and both cards still failed to work. We put the cards in a different computer and both worked fine.
We now have the computer at our office for examination. The Windows Device Manager lists our card in Other Devices as usual and says it's working fine. However, our driver initialization fails when it attempts to connect to the card.
We created a test version of our driver with some extra debugging and determined that CreateFile is failing. It returns INVALID_HANDLE_VALUE as it is supposed to on failure. GetLastError indicates the error is Access is Denied.
Since we're logged into the system as a local administrator, what can deny access to the device?
© Stack Overflow or respective owner