Is there a way to obtain PCI coordinates (bus/slot/function numbers) of devices by using Windows c/c++ API (e.g PnP Configuration Manager API)? I already know how to do it in kernel mode, I need an user-mode solution. My target system is Windows XP-32 bit.
相关问题
- the application was unable to start correctly 0xc0
- Handle button click in another application
- win32 Python - pythoncom error - ImportError: No m
- How to prevent windows from accessing and detectin
- Getting the output from a process created by Creat
相关文章
- Why windows 64 still makes use of user32.dll etc?
- How do I get to see DbgPrint output from my kernel
- Can WM_NEXTDLGCTL be used with non-dialog windows?
- Windows EventLog: How fast are operations with it?
- Are resource files compiled as UNICODE or ANSI cod
- How can one batch file get the exit code of anothe
- user32 and kernel method list for C# [closed]
- Writing to the middle of the file (without ove
I've eventually found a simple solution (it was just a matter of digging into MSDN).
This minimal code finds the device's PCI coordinates in terms of bus/slot/function:
Note: for real production the output buffer's size must be obtained by a previous call of the API function in order to allocate it dynamically, and error checks must be added, of course.